You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@uima.apache.org by "Marshall Schor (JIRA)" <ui...@incubator.apache.org> on 2007/01/27 14:27:49 UTC
[jira] Created: (UIMA-239) Tools like the CDE which use XML parsing
need should preserve XML comments.; parsers should provide access to XML
comments.
Tools like the CDE which use XML parsing need should preserve XML comments.; parsers should provide access to XML comments.
---------------------------------------------------------------------------------------------------------------------------
Key: UIMA-239
URL: https://issues.apache.org/jira/browse/UIMA-239
Project: UIMA
Issue Type: Improvement
Components: Core Java Framework, Tools
Reporter: Marshall Schor
As an example, the descriptors that come with the UIMA toolkit have a comment that specifies the license information for that file. If you edit a descriptor containing such a comment with the CDE, it strips out all comments.
An alternative for license info: add a new, optional element to the descriptor for specifying the license (but this might be ambigious as to what is being licensed - the descriptor file or what it refers to or ??? )
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
Re: [jira] Commented: (UIMA-239) Tools like the CDE which use XML parsing should preserve XML comments; parsers should provide access to XML comments.
Posted by Adam Lally <al...@alum.rpi.edu>.
On 2/14/07, Marshall Schor <ms...@schor.com> wrote:
> Thilo Goetz (JIRA) wrote:
> > [ https://issues.apache.org/jira/browse/UIMA-239?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12472242 ]
> >
> > Thilo Goetz commented on UIMA-239:
> > ----------------------------------
> >
> > This should really be fixed properly if at all possible. It's super annoying when tooling removes your carefully placed XML comments. One would imagine that the Eclipse classes we use for reading and writing the XML support this.
> >
>
> Would using the SAX LexicalHandler make this work? I guess we'd need a
> way to store the comments in the data model
> the parser constructs from the XML, and write it back out. Adam - I
> think you looked into this once - is this the right approach,
> or is there something better to consider?
>
Descriptors are parsed using DOM, not SAX. (If someone wants to
volunteer to convert it to SAX, I have no objection, but that's
another story. :) A brief look at the DOM javadocs shows there is a
Comment interface (a type of Node in a DOM tree). Assuming the parser
actually populates that, we should have access to the comments in that
way.
Then as you suggest there needs to be a property on all of our
MetaDataObjects (the supertype of all objects that make up our
descriptors) that holds the comments, and the MetaDataObject.toXML()
method must be updated to write these out.
-Adam
Re: [jira] Commented: (UIMA-239) Tools like the CDE which use XML
parsing should preserve XML comments; parsers should provide access to XML
comments.
Posted by Marshall Schor <ms...@schor.com>.
Thilo Goetz (JIRA) wrote:
> [ https://issues.apache.org/jira/browse/UIMA-239?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12472242 ]
>
> Thilo Goetz commented on UIMA-239:
> ----------------------------------
>
> This should really be fixed properly if at all possible. It's super annoying when tooling removes your carefully placed XML comments. One would imagine that the Eclipse classes we use for reading and writing the XML support this.
>
Would using the SAX LexicalHandler make this work? I guess we'd need a
way to store the comments in the data model
the parser constructs from the XML, and write it back out. Adam - I
think you looked into this once - is this the right approach,
or is there something better to consider?
-Marshall
[jira] Commented: (UIMA-239) Tools like the CDE which use XML
parsing should preserve XML comments; parsers should provide access to XML
comments.
Posted by "Thilo Goetz (JIRA)" <ui...@incubator.apache.org>.
[ https://issues.apache.org/jira/browse/UIMA-239?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12472242 ]
Thilo Goetz commented on UIMA-239:
----------------------------------
This should really be fixed properly if at all possible. It's super annoying when tooling removes your carefully placed XML comments. One would imagine that the Eclipse classes we use for reading and writing the XML support this.
> Tools like the CDE which use XML parsing should preserve XML comments; parsers should provide access to XML comments.
> ---------------------------------------------------------------------------------------------------------------------
>
> Key: UIMA-239
> URL: https://issues.apache.org/jira/browse/UIMA-239
> Project: UIMA
> Issue Type: Improvement
> Components: Core Java Framework, Tools
> Reporter: Marshall Schor
>
> An example of a problem which happens if this is not done: the descriptors that come with the UIMA toolkit have a comment that specifies the license information for that file. If you edit a descriptor containing such a comment with the CDE, it strips out all comments.
> An alternative for license info: add a new, optional element to the descriptor for specifying the license (but this might be ambigious as to what is being licensed - the descriptor file or what it refers to or ??? )
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (UIMA-239) Tools like the CDE which use XML parsing
should preserve XML comments; parsers should provide access to XML
comments.
Posted by "Marshall Schor (JIRA)" <ui...@incubator.apache.org>.
[ https://issues.apache.org/jira/browse/UIMA-239?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Marshall Schor updated UIMA-239:
--------------------------------
Description:
An example of a problem which happens if this is not done: the descriptors that come with the UIMA toolkit have a comment that specifies the license information for that file. If you edit a descriptor containing such a comment with the CDE, it strips out all comments.
An alternative for license info: add a new, optional element to the descriptor for specifying the license (but this might be ambigious as to what is being licensed - the descriptor file or what it refers to or ??? )
was:
As an example, the descriptors that come with the UIMA toolkit have a comment that specifies the license information for that file. If you edit a descriptor containing such a comment with the CDE, it strips out all comments.
An alternative for license info: add a new, optional element to the descriptor for specifying the license (but this might be ambigious as to what is being licensed - the descriptor file or what it refers to or ??? )
Summary: Tools like the CDE which use XML parsing should preserve XML comments; parsers should provide access to XML comments. (was: Tools like the CDE which use XML parsing need should preserve XML comments.; parsers should provide access to XML comments.)
typos
> Tools like the CDE which use XML parsing should preserve XML comments; parsers should provide access to XML comments.
> ---------------------------------------------------------------------------------------------------------------------
>
> Key: UIMA-239
> URL: https://issues.apache.org/jira/browse/UIMA-239
> Project: UIMA
> Issue Type: Improvement
> Components: Core Java Framework, Tools
> Reporter: Marshall Schor
>
> An example of a problem which happens if this is not done: the descriptors that come with the UIMA toolkit have a comment that specifies the license information for that file. If you edit a descriptor containing such a comment with the CDE, it strips out all comments.
> An alternative for license info: add a new, optional element to the descriptor for specifying the license (but this might be ambigious as to what is being licensed - the descriptor file or what it refers to or ??? )
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (UIMA-239) Tools like the CDE which use XML
parsing should preserve XML comments; parsers should provide access to XML
comments.
Posted by "J William Murdock (JIRA)" <ui...@incubator.apache.org>.
[ https://issues.apache.org/jira/browse/UIMA-239?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12472020 ]
J William Murdock commented on UIMA-239:
----------------------------------------
Here is variant of Adam's alternative: add a new, optional element to the descriptor called "comments"; this could be used for licensing information or whatever else a developer wants. The existing description field can be used for this purpose, but there are plenty of kinds of information that don't really belong in a description of the component but should be expressed in free text that anyone viewing the descriptor would see, e.g., licensing, availability, contact information, links to additional documentation, etc.
> Tools like the CDE which use XML parsing should preserve XML comments; parsers should provide access to XML comments.
> ---------------------------------------------------------------------------------------------------------------------
>
> Key: UIMA-239
> URL: https://issues.apache.org/jira/browse/UIMA-239
> Project: UIMA
> Issue Type: Improvement
> Components: Core Java Framework, Tools
> Reporter: Marshall Schor
>
> An example of a problem which happens if this is not done: the descriptors that come with the UIMA toolkit have a comment that specifies the license information for that file. If you edit a descriptor containing such a comment with the CDE, it strips out all comments.
> An alternative for license info: add a new, optional element to the descriptor for specifying the license (but this might be ambigious as to what is being licensed - the descriptor file or what it refers to or ??? )
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.