package Compound; sub new { my $pkg = shift; my $self = shift; # fill with {'list'=> [array] of Patches, Compounds and Schedulers and '$' => {hash} of Mixers, Amplifiers, Lags, etc bless $self,$pkg; return $self; } sub pulse { my $self = shift; foreach my $elt (@{$self->{'list'}}) { $elt->pulse(); } foreach my $elt (values %{$self->{'$'}}) { $elt->pulse(); } } 'end Compound';