in reply to Re: OO - problem with inheritance
in thread OO - problem with inheritance
which is taken from my String class, I need to override your sub parameter_config in this way?&CCS::Data::Datatype::base_class::config_parameter( max_length => {max => 255, default => 255}, min_length => {max => 255});
But I also need the other parameters from base class (like min => 0 and valid => 0 in this case).sub parameter_config { return {max_length => {max => 255, default =>255)); }
My classes not only inherit from base_class.pm. There are also datatypes that inherit from other datatypes. Such as Text inherits from String (but no direct base_class) and PrimaryKey inherits from Integer. Is such inheritance with one of this configuration methods combineable?my $parameter_config = SUPER->parameter_config; $parameter_config->{max_length}{max} = 255; $parameter_config->{max_length}{default} = 255; sub parameter_config { $parameter_config }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: OO - problem with inheritance
by IlyaM (Parson) on Jan 14, 2002 at 20:58 UTC | |
by uwevoelker (Pilgrim) on Jan 16, 2002 at 23:27 UTC | |
by IlyaM (Parson) on Jan 17, 2002 at 16:50 UTC | |
by uwevoelker (Pilgrim) on Jan 14, 2002 at 21:14 UTC |