Class PHPParserBuilder

java.lang.Object
org.sonar.php.parser.PHPParserBuilder

public class PHPParserBuilder extends Object
  • Method Summary

    Modifier and Type
    Method
    Description
    static com.sonar.sslr.api.typed.ActionParser<Tree>
     
    static com.sonar.sslr.api.typed.ActionParser<Tree>
    createParser(org.sonar.sslr.grammar.GrammarRuleKey rootRule)
    This method should be used by tests only.
    static com.sonar.sslr.api.typed.ActionParser<Tree>
    createParser(org.sonar.sslr.grammar.GrammarRuleKey rootRule, int lineOffset)
    This method should be used if required to shift line of tokens

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • createParser

      public static com.sonar.sslr.api.typed.ActionParser<Tree> createParser()
    • createParser

      public static com.sonar.sslr.api.typed.ActionParser<Tree> createParser(org.sonar.sslr.grammar.GrammarRuleKey rootRule)
      This method should be used by tests only. Provides ability to start parsing from some rule other than PHPLexicalGrammar.COMPILATION_UNIT.
      Parameters:
      rootRule - rule from which parsing starts
    • createParser

      public static com.sonar.sslr.api.typed.ActionParser<Tree> createParser(org.sonar.sslr.grammar.GrammarRuleKey rootRule, int lineOffset)
      This method should be used if required to shift line of tokens