[MOBY-dev] [moby] Problems using serviceInputParser method when the mobyservice receives multiple Simple inputs

Mark Wilkinson markw at illuminae.com
Thu Mar 22 15:53:10 UTC 2007


Hi Jose, 

please go ahead and fix this in the CVS.

It's interesting that there is no attribute-equivalent to
getElementsByLocalName, where "local" means whatever namespace you are
currently in...

M





On Thu, 2007-03-22 at 10:32 +0100, Jose Manuel Rodriguez wrote:
> Hi everyone,
> 
> I am executing a MOBY services in Perl which needs multiple Simple inputs.
> To extract the MOBY messages, when the service are called, I am using 
> the "serviceInputParser" but I have seen that the returned hashref which 
> contains the Simple inputs is wrong. I mean, the hashref
> 
> ,whose structure is "$inputs->{$queryID}->{articleName}",
> 
> has always empty articleName value. That means the articleName of Simple 
> Object is not obtained correctly. (if we have multiple simple inputs in 
> one mobyData, the hashref returned by "serviceInputParser" will contain 
> the last MOBY Object).
> 
> 
> 
> I have been checking the code and I have seen in the method 
> "createFromDOM" from "MOBY::Client::SimpleArticle" file that the 
> 'articleNames' attribute is not extracted when this belongs to the 
> namespace of "moby".
> 
> 
> my $attr = $dom->getAttributeNode( 'articleName' );
> my $articleName = $attr ? $attr->getValue : "";
> 
> 
> Here you are one solution in this particular problem:
> 
> my $attr = $dom->getAttributeNodeNS( 'http://www.biomoby.org/moby', 
> 'articleName' );
> $attr = $dom->getAttributeNode( 'articleName' ) unless defined $attr;
> my $articleName = $attr ? $attr->getValue : "";
> 
> 
> 
> (but I think this is one of more problems regarding MOBY namespaces)
> 
> Best Regards,
> José.
> 





More information about the MOBY-dev mailing list