Reputation: 7234
I have an eclipse org.eclipse.xsd.XSDSchema instance. I need to print the schema as a string.
Despite a day long effort, I am not able to get a solution except for loading it to a eclipse resource and saving it to disk. But this is not solving my purpose. Any pointers would be helpful.
Upvotes: 1
Views: 55
Reputation: 7234
Got it! After scanning through the Eclipse EMF codebase, found a way. The code snippet below prints the XSDSchema instance to console.
public static void printXSDSchema(XSDSchema xsdSchema){
XSDResourceImpl.serialize(System.out, xsdSchema.getDocument());
}
Upvotes: 1