Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » XML Schema Definition (XSD) » Creating XSDAnnotations
Creating XSDAnnotations [message #582997] Mon, 19 January 2004 17:05
Eclipse User
Originally posted by: floodg.uk.ibm.com

Hi,

trying to create an XSDAnnotation for an XSDFacet. Can't understand why the
following code doesn't do the job!

XSDAnnotation annotation = XSDFactory.eINSTANCE.createXSDAnnotation();

facet.setAnnotation(annotation);

Element element =
annotation.createUserInformation(facet.getSchema().getSchema Location());

Node node = element.getOwnerDocument().createTextNode("some text");

element.appendChild(node);

annotation.getUserInformation().add(element);

I've also tried element.setNodeValue("some text") but that doesn't work
either. My output contains no annotation node at all.

And ideas or sample code would be greatly appreciated!

Gary.
Previous Topic:Possible errors in the XSD facet item providers
Next Topic:finding elements or attributes based on Types
Goto Forum:
  


Current Time: Thu Oct 23 08:41:34 GMT 2014

Powered by FUDForum. Page generated in 0.08251 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software