Changeset 20102 for gsdl/trunk/perllib/buildConfigxml.pm
- Timestamp:
- 2009-07-29T13:32:12+12:00 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
gsdl/trunk/perllib/buildConfigxml.pm
r20096 r20102 128 128 # for subcollections 129 129 my $filter = $_{'filter'}; 130 131 # for flax activities132 my $desid = $_{'desid'};133 my $assigned = $_{'assigned'};134 my $lang = $_{'lang'};135 130 136 131 #@ Marking repeated block … … 263 258 264 259 } 265 #@ Handling each flaxActivity element (arrayarrayexp)266 elsif ($element eq "flaxActivity") {267 if (!defined $data->{'flaxActivity'}) {268 $data->{'flaxActivity'} = [];269 }270 if(defined $assigned and $assigned =~ /\w/ and $assigned eq "true") {271 if (defined $name and $name =~ /\w/) {272 push (@{$data->{'flaxActivity'}->[$currentIndex]}, 'name');273 push (@{$data->{'flaxActivity'}->[$currentIndex]}, $name);274 }275 276 if (defined $desid and $desid =~ /\w/) {277 push (@{$data->{'flaxActivity'}->[$currentIndex]}, 'desid');278 push (@{$data->{'flaxActivity'}->[$currentIndex]}, $desid);279 }280 281 if (defined $lang and $lang =~ /\w/) {282 push (@{$data->{'flaxActivity'}->[$currentIndex]}, 'lang');283 push (@{$data->{'flaxActivity'}->[$currentIndex]}, $lang);284 }285 }286 }287 260 } 288 261 … … 295 268 } 296 269 # $arrayarrayexp contains classifier|plugin 297 elsif($element =~ /$arrayarrayexp/ || $element eq "flaxActivity"){270 elsif($element =~ /$arrayarrayexp/ ){ 298 271 $currentIndex = $currentIndex + 1; 299 272 } … … 782 755 } 783 756 784 my $flaxActivities = $collectcfg->{"flaxActivity"};785 foreach my $fa (@$flaxActivities) {786 # Six elements of the array for three attribute name/value pairs: name, desid, and lang.787 if(defined $fa and @$fa[0] =~ /\w/ and @$fa[1] =~ /\w/ and @$fa[2] =~ /\w/ and @$fa[3] =~ /\w/ and @$fa[4] =~ /\w/ and @$fa[5] =~ /\w/) {788 &write_line('COLCFG', ["<serviceRack type=\"flaxActivity\" ", @$fa[0], "=\"", @$fa[1], "\" ", @$fa[2], "=\"", @$fa[3], "\" ", @$fa[4], "=\"", @$fa[5], "\" />"]);789 }790 }791 757 792 758 &write_line('COLCFG', ["</serviceRackList>"]);
Note:
See TracChangeset
for help on using the changeset viewer.