Package org.antlr.runtime3_3_0.tree

Examples of org.antlr.runtime3_3_0.tree.TreeRewriter$fptr


        AtomicItem page = new AtomicItem();

        HashMap<String, String> map = new HashMap<String, String>();
        Fptr[] fptrs = pageDiv.getFptr();
        for (int i = 0; i < fptrs.length; i++) {
            Fptr fptr = fptrs[i];
            File file = (File) fptr.getFILEID();
            if (file != null) {
                FLocat locat = file.getFLocat(0);
                String group = file.getUSE();
                map.put(group, locat.getHref());
            }
View Full Code Here


        // Sort the divs
        List<AtomicItem> list = new ArrayList<AtomicItem>(divs.length);
        for (int index = 0; index < divs.length; index++) {
            Div d = divs[index];
            if ("page".equals(d.getTYPE())) {
                Fptr fptr = d.getFptr(0);
                File file = (File) fptr.getFILEID();
                String groupId = file.getGROUPID();
                int size = list.size();
                if (size == 0 || (size > 0 && !(groupId.equals(list.get(size - 1).getId())))) {
                    AtomicItem item = parsePage(d);
                    item.setId(groupId);
View Full Code Here

      e.printStackTrace();
    }
  }
*/
  public void process() throws IOException {
    CharStream input = new ANTLRFileStream(dispelFile);
    DISPEL lexer = new DISPEL(input);
    Token token;
    while ((token = lexer.nextToken()) != Token.EOF_TOKEN) {
      tp.process(token);
    }
View Full Code Here

  public Generator(InputStream is)  {
    tp = new TokenProcessor(docType, tabSize, latexSpaceSize, numberLines);
   
    CharStream input;
    try {
      input = new ANTLRInputStream(is);
     
      DISPEL lexer = new DISPEL(input);
      Token token;
       
        while ((token = lexer.nextToken()).getType() !=
View Full Code Here

      e.printStackTrace();
    }
  }
*/
  public void process() throws IOException {
    CharStream input = new ANTLRFileStream(dispelFile);
    DISPEL lexer = new DISPEL(input);
    Token token;
    while ((token = lexer.nextToken()) != Token.EOF_TOKEN) {
      tp.process(token);
    }
View Full Code Here

*/

  public Generator(InputStream is)  {
    tp = new TokenProcessor(docType, tabSize, latexSpaceSize, numberLines);
   
    CharStream input;
    try {
      input = new ANTLRInputStream(is);
     
      DISPEL lexer = new DISPEL(input);
      Token token;
View Full Code Here

    }

    // Wildcard?
    if ( ttype == TreePatternLexer.DOT ) {
      ttype = tokenizer.nextToken();
      Token wildcardPayload = new CommonToken(0, ".");
      TreeWizard.TreePattern node =
        new TreeWizard.WildcardTreePattern(wildcardPayload);
      if ( label!=null ) {
        node.label = label;
      }
View Full Code Here

   *
   *  If you care what the token payload objects' type is, you should
   *  override this method and any other createToken variant.
   */
  public Token createToken(int tokenType, String text) {
    return new CommonToken(tokenType, text);
  }
View Full Code Here

   *
   *  If you care what the token payload objects' type is, you should
   *  override this method and any other createToken variant.
   */
  public Token createToken(Token fromToken) {
    return new CommonToken(fromToken);
  }
View Full Code Here

                    BitSet follow)
  {
    String tokenText =
      "<missing "+getTokenNames()[expectedTokenType]+">";
        TreeAdaptor adaptor = ((TreeNodeStream)e.input).getTreeAdaptor();
        return adaptor.create(new CommonToken(expectedTokenType, tokenText));
  }
View Full Code Here

TOP

Related Classes of org.antlr.runtime3_3_0.tree.TreeRewriter$fptr

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.