devel > Re: [gifti-devel forum] updated caret gifti files
Showing 1-5 of 5 posts
Dec 2, 2009 04:12 PM | John Harwell
Re: [gifti-devel forum] updated caret gifti files
Hi Rick,
Those attributes identify a schema =
(http://www.learn-xml-schema-tutorial.com...) for validating the GIFTI =
element and its children. The DOCTYPE that I had previously used for =
was for a DTD. The schema provides greater error checking than the DTD.
I have used the website "http://tools.decisionsoft.com/schemaValidate/" =
to validate the GIFTI files.
John
> By: Richard Reynolds
>=20
> Hi John,
>=20
> The updated datasets for Caret have new GIFTI attributes: xmlns:xsi =
and
> xsi:noNamespaceSchemaLocation. Do you really want these as attributes =
of the
> GIFTI image, or should they be above that, maybe as attributes of xml?
>=20
> You had previously listed similar info in a separate DOCTYPE element, =
outside
> of GIFTI.
>=20
> - rick
Those attributes identify a schema =
(http://www.learn-xml-schema-tutorial.com...) for validating the GIFTI =
element and its children. The DOCTYPE that I had previously used for =
was for a DTD. The schema provides greater error checking than the DTD.
I have used the website "http://tools.decisionsoft.com/schemaValidate/" =
to validate the GIFTI files.
John
> By: Richard Reynolds
>=20
> Hi John,
>=20
> The updated datasets for Caret have new GIFTI attributes: xmlns:xsi =
and
> xsi:noNamespaceSchemaLocation. Do you really want these as attributes =
of the
> GIFTI image, or should they be above that, maybe as attributes of xml?
>=20
> You had previously listed similar info in a separate DOCTYPE element, =
outside
> of GIFTI.
>=20
> - rick
Dec 2, 2009 09:12 PM | Richard Reynolds
Re: [gifti-devel forum] updated caret gifti files
It just threw me a bit because these are new attributes of the
GIFTI element, which seems to amount to a small change in the GIFTI
format.
So do we need to add such attributes to the DTD, or perhaps mention them in the Format doc? From a programming point of view, they should be considered valid attributes. As of now, they are considered invalid, and gifticlib whines.
Keeping a list of valid non-gifti attributes is okay with me, which seems appropriate for these. I would just prefer a fixed list of what is acceptable.
- rick
So do we need to add such attributes to the DTD, or perhaps mention them in the Format doc? From a programming point of view, they should be considered valid attributes. As of now, they are considered invalid, and gifticlib whines.
Keeping a list of valid non-gifti attributes is okay with me, which seems appropriate for these. I would just prefer a fixed list of what is acceptable.
- rick
Dec 15, 2009 04:12 PM | Richard Reynolds
Re: updated caret gifti files
Hi John,
Your "reply" method seems to be starting a new thread each time...
Of course I can ignore unknown attributes, but my confusion probably comes from the wording on page 21 of GIFTI_Surface_Format.pdf, which is pretty strong in stating that those are the only attributes allowed. Consider these pieces:
"A DTD (Document Type Definition) describes the allowable elements and attributes in an XML file..."
"Each ELEMENT entry in the DTD lists a valid element name and the children allowed for the element."
"Each ATTLIST element in the DTD specifies the allowable attributes for an element."
It isn't a big deal of course. And if no one cares about this, maybe it would be enough just to add a statement that unknown attributes will be ignored. If that one validation method forces 4 more attributes, it may not be reasonable to expect to know them all.
- rick
Your "reply" method seems to be starting a new thread each time...
Of course I can ignore unknown attributes, but my confusion probably comes from the wording on page 21 of GIFTI_Surface_Format.pdf, which is pretty strong in stating that those are the only attributes allowed. Consider these pieces:
"A DTD (Document Type Definition) describes the allowable elements and attributes in an XML file..."
"Each ELEMENT entry in the DTD lists a valid element name and the children allowed for the element."
"Each ATTLIST element in the DTD specifies the allowable attributes for an element."
It isn't a big deal of course. And if no one cares about this, maybe it would be enough just to add a statement that unknown attributes will be ignored. If that one validation method forces 4 more attributes, it may not be reasonable to expect to know them all.
- rick
Dec 16, 2009 04:12 PM | John Harwell
Re: updated caret gifti files
Rick,
I have updated the GIFTI Surface Format Document so that it now lists two optional attributes for the GIFTI element, xmlns:xsi and xmlns. The document indicates that these are optional elements only present if an XML Schema is available for validation. The GIFTI DTD has also been updated to includes these two attributes and the color component attributes for the Label element.
The new GIFTI DTD is located at: http://www.nitrc.org/frs/download.php/15... Note that it is a different URL (the number preceding gifti.dtd) than the previous DTD (which is still available).
An XML schema is located at: http://www.nitrc.org/frs/download.php/13...
John
I have updated the GIFTI Surface Format Document so that it now lists two optional attributes for the GIFTI element, xmlns:xsi and xmlns. The document indicates that these are optional elements only present if an XML Schema is available for validation. The GIFTI DTD has also been updated to includes these two attributes and the color component attributes for the Label element.
The new GIFTI DTD is located at: http://www.nitrc.org/frs/download.php/15... Note that it is a different URL (the number preceding gifti.dtd) than the previous DTD (which is still available).
An XML schema is located at: http://www.nitrc.org/frs/download.php/13...
John
Dec 16, 2009 05:12 PM | Richard Reynolds
Re: updated caret gifti files
That looks good. Thanks, John!
- rick
- rick