Package com.puppetlabs.xtext.serializer

Examples of com.puppetlabs.xtext.serializer.DomBasedSerializer


   */
  private IStatus formattedDomDump(XtextResource resource) {
    if(serializer instanceof DomBasedSerializer == false)
      return new Status(
        IStatus.ERROR, "com.puppetlabs.geppetto.pp.dsl.ui", "Not configured to use DomBasedSerializer");
    DomBasedSerializer domSerializer = ((DomBasedSerializer) serializer);
    IDomNode dom = domSerializer.serializeToDom(resource.getContents().get(0), false);
    ISerializationDiagnostic.Acceptor errors = ISerializationDiagnostic.EXCEPTION_THROWING_ACCEPTOR;

    // ReplaceRegion r = domFormatter.format(dom, null /* all text */, formattingContextProvider.get(false), errors);
    getDomFormatter().format(
      dom, null /* all text */, formattingContextFactory.create(resource, FormattingOption.Format), errors);
View Full Code Here

TOP

Related Classes of com.puppetlabs.xtext.serializer.DomBasedSerializer

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.