### a piece in the bag, somewhat deprecated use BagElement1.pm

sub new {
    my $class = shift;

    $self = { nextelement => undef, data => undef };
    
    bless $self, $class;
}

sub setNext {
    my ($self, $bagel) = @_;

    $self->{nextelement} = $bagel;
}

sub setData {
    my ($self, $data) = @_;

    $self->{data} = $data;
}

1;
