public class DependencyAnalyzer
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.util.regex.Pattern |
bothDepLine |
static java.util.regex.Pattern |
classLine |
static java.util.regex.Pattern |
inDepLine |
static java.util.regex.Pattern |
memberLine |
static java.util.regex.Pattern |
outDepLine |
static java.util.regex.Pattern |
pkgLine |
Constructor and Description |
---|
DependencyAnalyzer(java.lang.String filename)
Constructs a DependencyAnalyzer from the output of DependencyExtractor.
|
Modifier and Type | Method and Description |
---|---|
static void |
main(java.lang.String[] args)
Takes a dependency closure generated by DependencyExtractor, and prints out the class names of exactly
those classes in the closure that are in an
edu.stanford.nlp -prepended package. |
static java.lang.String |
prependPackage(java.lang.String pkgname,
java.lang.String classname) |
java.util.Collection<edu.stanford.nlp.misc.DependencyAnalyzer.Identifier> |
transitiveClosure(java.util.List<java.lang.String> startingClassNames)
Constructs the transitive closure of outgoing dependencies starting
from the given classes.
|
public static final java.util.regex.Pattern pkgLine
public static final java.util.regex.Pattern classLine
public static final java.util.regex.Pattern memberLine
public static final java.util.regex.Pattern inDepLine
public static final java.util.regex.Pattern outDepLine
public static final java.util.regex.Pattern bothDepLine
public DependencyAnalyzer(java.lang.String filename) throws java.io.IOException
filename
- The path of a file containing the output of a run
of DependencyExtractor.java.io.IOException
public java.util.Collection<edu.stanford.nlp.misc.DependencyAnalyzer.Identifier> transitiveClosure(java.util.List<java.lang.String> startingClassNames)
startingClassNames
- A Collection of Strings, each the
fully-qualified name of a class. These are the starting elements of
the transitive closure.public static void main(java.lang.String[] args) throws java.lang.Exception
edu.stanford.nlp
-prepended package.args
- takes one argument: the name of a file that contains the output of a run of
DependencyExtractorjava.lang.Exception
public static java.lang.String prependPackage(java.lang.String pkgname, java.lang.String classname)