Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

order of authors is not correct #219

Open
piotr-gawron opened this issue Jun 24, 2020 · 1 comment
Open

order of authors is not correct #219

piotr-gawron opened this issue Jun 24, 2020 · 1 comment
Labels

Comments

@piotr-gawron
Copy link
Contributor

I'm parsing a file where there are three authors (authors.xml.zip). The annotation tag looks as follow:

<annotation>
      <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:vCard="http://www.w3.org/2001/vcard-rdf/3.0#" xmlns:dcterms="http://purl.org/dc/terms/" xmlns:bqbiol="http://biomodels.net/biology-qualifiers/">
        <rdf:Description rdf:about="#metaid_0">
          <dc:creator>
            <rdf:Bag>
              <rdf:li rdf:parseType="Resource">
                <vCard:N rdf:parseType="Resource">
                  <vCard:Family>Author 1</vCard:Family>
                </vCard:N>
              </rdf:li>
              <rdf:li rdf:parseType="Resource">
                <vCard:N rdf:parseType="Resource">
                  <vCard:Family>Author 2</vCard:Family>
                </vCard:N>
              </rdf:li>
              <rdf:li rdf:parseType="Resource">
                <vCard:N rdf:parseType="Resource">
                  <vCard:Family>Author 3</vCard:Family>
                </vCard:N>
              </rdf:li>
            </rdf:Bag>
          </dc:creator>
        </rdf:Description>
      </rdf:RDF>
    </annotation>

However, when I try to access annotation from jsbml the order of authors is wrong:

SBMLDocument sbmlDocument = SBMLReader.read(new FileInputStream("authors.xml"));
Model sbmlModel = sbmlDocument.getModel();
Annotation annotation = sbmlModel.getAnnotation();
System.out.println(annotation.getFullAnnotationString());
<annotation>
      <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:vCard="http://www.w3.org/2001/vcard-rdf/3.0#" xmlns:dcterms="http://purl.org/dc/terms/" xmlns:bqbiol="http://biomodels.net/biology-qualifiers/">
    <rdf:Description rdf:about="#metaid_0">
	<dc:creator>
	<rdf:Bag>
	<rdf:li rdf:parseType="Resource">
	<vCard:N rdf:parseType="Resource">
	<vCard:Family>Author 1</vCard:Family>
	</vCard:N>
	</rdf:li>
	
	<rdf:li rdf:parseType="Resource">
	<vCard:N rdf:parseType="Resource">
	<vCard:Family>Author 3</vCard:Family>
	</vCard:N>
	</rdf:li>
	<rdf:li rdf:parseType="Resource">
	<vCard:N rdf:parseType="Resource">
	<vCard:Family>Author 2</vCard:Family>
	</vCard:N>
	</rdf:li>
	</rdf:Bag>
	</dc:creator>
	</rdf:Description>
	
      </rdf:RDF>
    </annotation>

In most places I agree that order of xml tags is not important. However, in scientific community the order of authors sometimes is a very delicate thing. Could you please fix the order of authors?

I tested it on jsbml version 1.4 and 1.5

@draeger draeger added the bug label Jun 24, 2020
@niko-rodrigue
Copy link
Member

Thanks for the report, I will have a look at it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants