Changeset 16821
- Timestamp:
- 2008-08-15T15:30:17+12:00 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
gsdl/trunk/perllib/plugins/BasePlugin.pm
r16767 r16821 214 214 } 215 215 216 sub merge_inheritance 217 { 218 my $self = {}; 219 my @child_selfs = @_; 220 221 foreach my $child_self (@child_selfs) { 222 foreach my $key (keys %$child_self) { 223 if (defined $self->{$key}) { 224 if ($self->{$key} ne $child_self->{$key}) { 225 # print STDERR "Warning: Conflicting value in multiple inheritance for '$key'\n"; 226 # print STDERR "Existing stored value = $self->{$key}\n"; 227 # print STDERR "New (child) value = $child_self->{$key}\n"; 228 # print STDERR "Keeping existing value\n"; 229 # Existing value seems to be option specified in collect.cfg 230 231 ### $self->{$key} = $child_self->{$key}; 232 233 } 234 else { 235 ## print STDERR "****Info: Value $self->{$key} for $key already defined through multiple inheritance as the same value\n"; 236 } 237 238 } 239 else { 240 $self->{$key} = $child_self->{$key}; 241 } 242 } 243 } 244 245 return $self; 246 } 247 216 248 # initialize BasePlugin options 217 249 # if init() is overridden in a sub-class, remember to call BasePlugin::init() … … 249 281 my $self = shift (@_); 250 282 my ($pluginfo, $base_dir, $processor, $maxdocs) = @_; 283 284 # Save base_dir for use in file cache 285 # Would be more logical to do this in MediaConverter, but 286 # it's begin method doesn't appear to be called (29/6/08) 287 $self->{'base_dir'} = $base_dir; 251 288 } 252 289 … … 848 885 849 886 my ($process_status,$doc_obj) = $self->read_into_doc_obj(@_); 850 887 851 888 if ((defined $process_status) && ($process_status == 1)) { 852 889
Note:
See TracChangeset
for help on using the changeset viewer.