bioperl-live Outer
Included librariesPackage variablesGeneral documentationMethods
Toolbar
WebCvsRaw content
Package variables
Privates (from "my" definitions)
$ID = 'Outer'
Included modules
Bio::Root::Global qw ( :devel )
Bio::Root::Object ( )
Foo ( )
Inherit
Bio::Root::Object
Synopsis
No synopsis!
Description
No description!
Methods
_display_stats
No description
Code
_initialize
No description
Code
destroy
No description
Code
set_foo
No description
Code
Methods description
None available.
Methods code
_display_statsdescriptionprevnextTop
sub _display_stats {
    my ($self, $OUT ) = @_;

    $self->SUPER::_display_stats($OUT);

    (defined $self->{'Foo'})
	? $self->{'Foo'}->display(-WHERE=>$OUT, -HEADER=>1) 
	: ( printf( $OUT "%-15s: %s\n", 'Foo','undefined'));

    print $OUT "\n";
}

######################################
1;
}
_initializedescriptionprevnextTop
sub _initialize {
	
    my($self, %param) = @_;
    
    $DEBUG && do{ printf ">>>> Initializing %s (%s) %s\n",$ID,ref($self),$param{-NAME}||'anon';
		  <STDIN>; };
    
    #----------------------
# DATA MEMBERS:
# Outerdat
# color
# bar
#----------------------
$self->SUPER::_initialize( %param ); my ($foodat) = $self->_rearrange([qw(FOODAT)], %param); $self->set_foo( @$foodat ); $self->index(); $DEBUG and printf "---> Initialized %s (%s) %s\n",$ID, ref($self), $self->name; } ###################################
}
destroydescriptionprevnextTop
sub destroy {
    my $self = shift;
    if(ref($self->{'Foo'})) {
	$self->{'Foo'}->destroy;
	undef $self->{'Foo'};
    } 
    $self->SUPER::destroy();
}

###################################
}
set_foodescriptionprevnextTop
sub set_foo {
    my ($self, %param) = @_;
    my $foo = undef;

    $DEBUG and print "$ID: set_foo()\n"; 

    $param{-PARENT} = $self;
    
    eval { $foo = new Foo( %param ); };
    if($@) {
	## If Foo throws an exception, assimilate the exception as a warning 
## and add a note to it.
$self->warn(-MSG =>$@, -NOTE =>"${\$self->name()} can't build Foo object: Invalid object." ); } else { $self->{'Foo'} = $foo; } } ###################################
}
General documentation
No general documentation available.