Palm::Zetetic::Strip::System - An immutable system object


Palm-Zetetic-Strip documentation Contained in the Palm-Zetetic-Strip distribution.

Index


Code Index:

NAME

Top

Palm::Zetetic::Strip::System - An immutable system object

SYNOPSIS

Top

  use Palm::Zetetic::Strip;

  # Create and load a new Palm::Zetetic::Strip object

  @systems = $strip->get_systems()
  $id = $systems[0]->get_id();
  $name = $systems[0]->get_name();

DESCRIPTION

Top

This is an immutable data object that represents a system. A Palm::Zetetic::Strip(3) object is a factory for system objects.

METHODS

Top

get_id

  $id = $system->get_id();

Returns the ID of this system.

get_name

  $name = $system->get_name();

Returns the string name of this system;

SEE ALSO

Top

Palm::Zetetic::Strip(3)

AUTHOR

Top

Dave Dribin


Palm-Zetetic-Strip documentation Contained in the Palm-Zetetic-Strip distribution.
package Palm::Zetetic::Strip::System;

use strict;

use vars qw(@ISA $VERSION);

require Exporter;

@ISA = qw(Palm::Raw);
$VERSION = "1.02";

sub new
{
    my $class = shift;
    my (%args) = @_;
    my $self = {};

    bless $self, $class;
    $self->{id}     = "";
    $self->{name}   = "";

    $self->{id}     = $args{id} if defined($args{id});
    $self->{name}   = $args{name} if defined($args{name});
    return $self;
}

sub get_id
{
    my ($self) = @_;
    return $self->{id};
}

sub get_name
{
    my ($self) = @_;
    return $self->{name};
}

1;

__END__