Package org.eclipse.wst.xml.core.internal.parser

Examples of org.eclipse.wst.xml.core.internal.parser.XMLSourceParser


  /*
   * @see IModelLoader#getParser()
   */
  public RegionParser getParser() {
    XMLSourceParser parser = new XMLSourceParser();
    // for the "static HTML" case, we need to initialize
    // Blocktags here.
    addHTMLishTag(parser, "script"); //$NON-NLS-1$
    addHTMLishTag(parser, "style"); //$NON-NLS-1$
    return parser;
View Full Code Here


    /**
     * @param path -
     *            the fullpath for the resource to be parsed
     */
    void parse(IPath path) {
      XMLSourceParser p = (XMLSourceParser) getParser().newInstance();
      fLocalParser = p;
      String s = getContents(path);
      // Should we consider preludes on this segment?
      fLocalParser.addStructuredDocumentRegionHandler(IncludeHelper.this);
      fLocalParser.reset(s);
View Full Code Here

   * ** TEMP WORKAROUND FOR CMVC 241882 Takes a String and blocks out
   * jsp:scriptlet, jsp:expression, and jsp:declaration @param blockText
   * @return
   */
  private IStructuredDocumentRegion decodeScriptBlock(String blockText) {
    XMLSourceParser parser = new XMLSourceParser();
    // use JSP_CONTENT for region type
    parser.addBlockMarker(new BlockMarker("jsp:scriptlet", null, DOMJSPRegionContexts.JSP_CONTENT, false, false)); //$NON-NLS-1$
    parser.addBlockMarker(new BlockMarker("jsp:expression", null, DOMJSPRegionContexts.JSP_CONTENT, false, false)); //$NON-NLS-1$
    parser.addBlockMarker(new BlockMarker("jsp:declaration", null, DOMJSPRegionContexts.JSP_CONTENT, false, false)); //$NON-NLS-1$
    parser.reset(blockText);
    return parser.getDocumentRegions();
  }
View Full Code Here

   * ** TEMP WORKAROUND FOR CMVC 241882 Takes a String and blocks out
   * jsp:scriptlet, jsp:expression, and jsp:declaration @param blockText
   * @return
   */
  private IStructuredDocumentRegion decodeScriptBlock(String blockText) {
    XMLSourceParser parser = new XMLSourceParser();
    // use JSP_CONTENT for region type
    parser.addBlockMarker(new BlockMarker("jsp:scriptlet", null, DOMJSPRegionContexts.JSP_CONTENT, false, false)); //$NON-NLS-1$
    parser.addBlockMarker(new BlockMarker("jsp:expression", null, DOMJSPRegionContexts.JSP_CONTENT, false, false)); //$NON-NLS-1$
    parser.addBlockMarker(new BlockMarker("jsp:declaration", null, DOMJSPRegionContexts.JSP_CONTENT, false, false)); //$NON-NLS-1$
    parser.reset(blockText);
    return parser.getDocumentRegions();
  }
View Full Code Here

   * ** TEMP WORKAROUND FOR CMVC 241882 Takes a String and blocks out
   * jsp:scriptlet, jsp:expression, and jsp:declaration @param blockText
   * @return
   */
  private IStructuredDocumentRegion decodeScriptBlock(String blockText) {
    XMLSourceParser parser = new XMLSourceParser();
    // use JSP_CONTENT for region type
    parser.addBlockMarker(new BlockMarker("jsp:scriptlet", null, DOMJSPRegionContexts.JSP_CONTENT, false, false)); //$NON-NLS-1$
    parser.addBlockMarker(new BlockMarker("jsp:expression", null, DOMJSPRegionContexts.JSP_CONTENT, false, false)); //$NON-NLS-1$
    parser.addBlockMarker(new BlockMarker("jsp:declaration", null, DOMJSPRegionContexts.JSP_CONTENT, false, false)); //$NON-NLS-1$
    parser.reset(blockText);
    return parser.getDocumentRegions();
  }
View Full Code Here

    /**
     * @param path -
     *            the fullpath for the resource to be parsed
     */
    void parse(IPath path) {
      XMLSourceParser p = (XMLSourceParser) getParser().newInstance();
      fLocalParser = p;
      String s = getContents(path);
      // Should we consider preludes on this segment?
      fLocalParser.addStructuredDocumentRegionHandler(IncludeHelper.this);
      fLocalParser.reset(s);
View Full Code Here

    }
    return fDocumentEncodingDetector;
  }

  public RegionParser getParser() {
    return new XMLSourceParser();
  }
View Full Code Here

TOP

Related Classes of org.eclipse.wst.xml.core.internal.parser.XMLSourceParser

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.