Update of /cvsroot/openinteract/OpenInteract2/lib/OpenInteract2
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32664/lib/OpenInteract2
Modified Files:
Manage.pm
Log Message:
add OpenInteract2::ParamContainer to ISA, remove old methods and modify docs to reflect
Index: Manage.pm
===================================================================
RCS file: /cvsroot/openinteract/OpenInteract2/lib/OpenInteract2/Manage.pm,v
retrieving revision 1.45
retrieving revision 1.46
diff -C2 -d -r1.45 -r1.46
*** Manage.pm 8 Feb 2005 01:09:13 -0000 1.45
--- Manage.pm 13 Feb 2005 20:16:36 -0000 1.46
***************
*** 4,8 ****
use strict;
! use base qw( Exporter Class::Factory Class::Observable );
use Cwd qw( cwd );
use File::Spec::Functions qw( :ALL );
--- 4,8 ----
use strict;
! use base qw( Exporter OpenInteract2::ParamContainer Class::Factory Class::Observable );
use Cwd qw( cwd );
use File::Spec::Functions qw( :ALL );
***************
*** 393,411 ****
# PARAMETERS
- sub param {
- my ( $self, $key, $value ) = @_;
- return $self->{params} unless ( $key );
- if ( $value ) {
- $self->{params}{ $key } = $value;
- }
- return $self->{params}{ $key };
- }
-
sub param_copy_from {
my ( $self, $other_task ) = @_;
! my $other_params = $other_task->param;
! while ( my ( $name, $value ) = each %{ $other_params } ) {
! $self->param( $name, $value );
! }
return $self->param;
}
--- 393,399 ----
# PARAMETERS
sub param_copy_from {
my ( $self, $other_task ) = @_;
! $self->param_assign( $other_task->param );
return $self->param;
}
***************
*** 820,830 ****
B<param( $key, $value )>
! If C<$key> is unspecified, returns all parameters as a hashref.
!
! If C<$value> is unspecified, returns the current value set for
! parameter C<$key>.
!
! If both C<$key> and C<$value> are specified, sets the parameter
! C<$key> to C<$value> and returns it.
Example:
--- 808,812 ----
B<param( $key, $value )>
! See L<OpenInteract2::ParamContainer> for details.
Example:
***************
*** 847,851 ****
Copy all parameters from C<$other_task> into this object.
! Returns: results of C<param()> on this object.
B<get_status()>
--- 829,833 ----
Copy all parameters from C<$other_task> into this object.
! Returns: results of C<param()> on this object after the copy
B<get_status()>
|