|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.stanford.nlp.trees.tregex.TregexPatternCompiler
public class TregexPatternCompiler
A class for compiling TregexPatterns with specific HeadFinders and or basicCategoryFunctions.
Field Summary | |
---|---|
static TregexPatternCompiler |
defaultCompiler
|
Constructor Summary | |
---|---|
TregexPatternCompiler()
|
|
TregexPatternCompiler(Function<java.lang.String,java.lang.String> basicCatFunction)
A compiler that uses this basicCatFunction and the default HeadFinder. |
|
TregexPatternCompiler(HeadFinder headFinder)
A compiler that uses this HeadFinder and the default basicCategoryFunction |
|
TregexPatternCompiler(HeadFinder headFinder,
Function<java.lang.String,java.lang.String> basicCatFunction)
A compiler that uses this HeadFinder and this basicCategoryFunction |
Method Summary | |
---|---|
TregexPattern |
compile(java.lang.String tregex)
Create a TregexPattern from this tregex string using the headFinder and basicCat function this TregexPatternCompiler was created with. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static TregexPatternCompiler defaultCompiler
Constructor Detail |
---|
public TregexPatternCompiler()
public TregexPatternCompiler(Function<java.lang.String,java.lang.String> basicCatFunction)
basicCatFunction
- the function mapping Strings to Stringspublic TregexPatternCompiler(HeadFinder headFinder)
headFinder
- the HeadFinderpublic TregexPatternCompiler(HeadFinder headFinder, Function<java.lang.String,java.lang.String> basicCatFunction)
headFinder
- the HeadFinderbasicCatFunction
- The function mapping Strings to StringsMethod Detail |
---|
public TregexPattern compile(java.lang.String tregex) throws ParseException
tregex
- The pattern to parse
ParseException
- If the Tregex expression is syntactically invalid
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |