[MOBY-dev] Prefixes for generated moby objects
Paul Gordon
gordonp at ucalgary.ca
Fri Apr 7 15:22:20 UTC 2006
Hi all,
Not directly related to the question below, I would like to *strongly*
encourage people using formatted output such as GFF, BLAST, etc. to
explicitly add a xml:space="preserve" attribute to their string
objects. Otherwise an XML parser (or XSLT stylesheet as I use) can
irreversibly collapse all those nice formatting whitespace characters
into a single space to produce very ugly results. I've added this to
org.biomoby.shared.MobyDataString, but haven't commited yet since I'm
waiting for Ediie's RDF stuff to go live...
Cheers,
Paul
> Hello,
>
> I implemented a JMOBY webservice, which returns a BioMoby BLAST-Text object.
> Content, namespace and ID are added by JMOBY API like this:
>
> BLAST_Text text = new BLAST_Text();
> text.setId("output");
> text.setNamespace("BLAST");
> text.set_content(result);
>
> By executing my BioMoby service I found, that some tags (XML namespaces) in
> the output XML file were prefixed with "moby:" and all JMoby primitives were
> not.
> For example:
>
> <?xml version='1.0' encoding='UTF-8'?>
> <moby:MOBY xmlns:moby='http://www.biomoby.org/moby'
> xmlns='http://www.biomoby.org/moby'>
> <moby:mobyContent moby:authority='inb.bsc.es'>
> <moby:mobyData moby:queryID='a0'>
> <moby:Simple moby:articleName='wublast_report'>
> <moby:BLAST-Text namespace='' id=''>
> <String articleName='content'> <-- here
>
>
> Because of that I've got some problems by parsing the XML output with Java
> JDOM.
> So my questions are:
>
> Why have the primitives no "moby" XML namespace?
> Is it possible to change the JMoby api so that all primitives get a "moby" XML
> namespace too?
>
> Thanks,
> Anika
>
> _______________________________________________
> MOBY-dev mailing list
> MOBY-dev at lists.open-bio.org
> http://lists.open-bio.org/mailman/listinfo/moby-dev
>
More information about the MOBY-dev
mailing list