![]() |
GrammarScope
4.0.0
|


Public Member Functions | |
| boolean | init () |
Public Attributes | |
| boolean | stanfordMode = true |
Protected Member Functions | |
| XMLDocument (final URL url) | |
Private Member Functions | |
| void | makeDocument (final Document document) |
| void | processSentences (final Element sentencesElement, final StringBuffer textBuilder, final List< List< WordSegment >> segments, final Map< Integer, AParseTree > parseTrees, final Map< Integer, AGrammaticalStructure > grammaticalStructures, final Map< Integer, Map< TypedDependencyProvider, Map< TypedDependencyMode, ATypedDependencies >>> typedDependencies, final Map< Integer, Map< TypedDependencyProvider, Map< TypedDependencyMode, ASemanticGraph >>> semanticGraphs, final Map< Integer, Sentiment > sentiments, final Map< Integer, List< Entailment >> entailments, final Map< Integer, List< Triple >> triples) |
| Map< Integer, Token > | makeTokens (final Element sentenceElement, final int sentenceIdx, final List< WordSegment > wordSegments, final StringBuffer sb) |
| Token | makeToken (final Element tokenElement, final int sentenceIdx, final List< WordSegment > wordSegments, final StringBuffer sb) |
| AParseTree | makeParse (final Element sentenceElement) |
| MutableAParseTree | makeXMLParse (final Element nodeElement) |
| AGrammaticalStructure | makeGrammaticalStructure (final Element sentenceElement) |
| MutableAGrammaticalStructure | makeXMLGrammaticalStructure (final Element nodeElement) |
| MutableAGrammaticalStructure | makeXMLGrammaticalStructure1 (final Element nodeElement, final Map< String, MutableAGrammaticalStructure > idMap) |
| MutableAGrammaticalStructure | makeXMLGrammaticalStructure2 (final Element nodeElement, final Map< String, MutableAGrammaticalStructure > idMap) |
| String | grammaticalStructureNodeToId (final Element nodeElement) |
| Map< TypedDependencyProvider, Map< TypedDependencyMode, ATypedDependencies > > | makeTypedDependencies (final Element sentenceElement, final Map< Integer, Token > tokens) |
| Map< TypedDependencyProvider, Map< TypedDependencyMode, ATypedDependencies > > | makeCompatTypedDependencies (final Element sentenceElement, final Map< Integer, Token > tokens) |
| ATypedDependencies | makeATypedDependencies (final Element dependenciesElement, final Map< Integer, Token > tokens) |
| TypedDependency | makeTypedDependency (final Element typedDependencyElement, final Map< Integer, Token > tokens) |
| Map< TypedDependencyProvider, Map< TypedDependencyMode, ASemanticGraph > > | makeSemanticGraphs (final Element sentenceElement, final Map< Integer, Token > tokens) |
| List< Integer > | makeGraphRootIndices (final Element graphRootsElement) |
| Sentiment | makeSentiment (final Element sentenceElement) |
| List< Entailment > | makeEntailments (final Element sentenceElement) |
| List< Triple > | makeTriples (final Element sentenceElement) |
| ACoreferences | makeCoreferences (final Element documentElement) |
Static Private Member Functions | |
| static Document | makeDomDocument (final URL url) throws IOException, SAXException, ParserConfigurationException |
| static Token | getToken (final String id, final int index, final Map< Integer, Token > tokens) |
| static String | grammaticalStructureNodeToId (final String value, final int index) |
| static String | makeId (final String value) |
| static Map< Integer, APartsOfSpeech > | makePoses (final Map< Integer, Map< Integer, Token >> tokens) |
| static Map< Integer, ANamedEntities > | makeNamedEntities (final Map< Integer, Map< Integer, Token >> tokens) |
| static Element | getFirstLevel1ElementByTagName (final Element parentElement, final String tagName) |
| static String | getFirstLevel1ElementTextByTagName (final Element parentElement, final String tagName) |
| static List< Element > | getLevel1ChildElementsByTagName (final Element element, final String tagName) |
| static TypedDependencyProvider | parseProvider (final String providerString) |
| static TypedDependencyMode | parseMode (final String modeString) |
Document (as read from XML formatted data - the format is extended from the pipeline format)
|
protected |
Constructor
| url | XML document URL |
|
staticprivate |
Find DOM element with given tag among first level children
| parentElement | starting DOM element |
| tagName | tag |
|
staticprivate |
Get text of DOM element with given tag among first level children
| parentElement | parent element |
| tagName | tag name |
|
staticprivate |
Find DOM elements with given tag among first level children
| element | starting DOM element |
| tagName | tag |
|
staticprivate |
Get token
| id | id |
| index | index |
| tokens | token map |
|
private |
Grammatical structure node id
| nodeElement | grammatical structure node element |
|
staticprivate |
Grammatical structure node id
| value | grammatical structure node value |
| index | grammatical structure node index |
| boolean grammarscope.io.xml.XMLDocument.init | ( | ) |
Init DOM parsing
|
private |
Make typed dependencies from element
| dependenciesElement | element |
| tokens | indexed tokens |
|
private |
Make compat typed dependencies from element
| sentenceElement | element |
| tokens | sentence-indexed tokens |
|
private |
Make coreferences
| documentElement | document element |
|
private |
Build factory from DOM document
| document | DOM document |
|
staticprivate |
Build DOM document from URL
| url | url |
| IOException | exception |
| SAXException | exception |
| ParserConfigurationException | exception |
|
private |
Make entailments
| sentenceElement | sentence element |
|
private |
Make grammatical structure from element
| sentenceElement | element |
|
private |
Make graph roots
| graphRootsElement | element |
|
staticprivate |
Grammatical structure node id
| value | grammatical structure node value |
|
staticprivate |
Gather Named Entities
| tokens | sentence-indexed tokens |
|
private |
Make parse tree from element
| sentenceElement | element |
|
staticprivate |
Gather Part-Of-Speech data
| tokens | sentence-indexed tokens |
|
private |
Make typed dependencies from element
| sentenceElement | element |
| tokens | sentence-indexed tokens |
|
private |
Make sentiment
| sentenceElement | sentence element |
|
private |
Make token from element
| tokenElement | element |
| sentenceIdx | sentence index |
| wordSegments | word segments |
| sb | text string sb |
|
private |
Make tokens from element
| sentenceElement | sentence element |
| sentenceIdx | sentence index |
| wordSegments | word segments |
| sb | text string sb |
|
private |
Make triples
| sentenceElement | sentence element |
|
private |
Make typed dependencies from element
| sentenceElement | element |
| tokens | sentence-indexed tokens |
|
private |
Make typed dependencies from element
| typedDependencyElement | element |
| tokens | word-indexed tokens |
|
private |
Make grammatical structure from node element
| nodeElement | node element |
|
private |
Make grammatical structure from node element
| nodeElement | node element |
| idMap | node id to grammatical structure node map |
|
private |
Make grammatical structure from node element
| nodeElement | node element |
| idMap | node id to grammatical structure node map |
|
private |
Parse XML parse tree
| nodeElement | root node element |
|
staticprivate |
DOM element name to typed dependency mode
| modeString | typed dependency mode string |
|
staticprivate |
DOM element name to typed dependency provider
| providerString | typed dependency provider string |
|
private |
Process sentence
| sentencesElement | sentence element |
| textBuilder | text string sb |
| segments | sentence-split word segments |
| parseTrees | sentence-indexed parse trees |
| grammaticalStructures | sentence-indexed grammatical structures |
| typedDependencies | sentence-indexed typed dependencies |
| semanticGraphs | sentence-indexed semantic graphs |
| sentiments | sentence-indexed sentiments |
| entailments | sentence-indexed entailments |
| triples | sentence-indexed triples |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Coreference chains
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
The DOM document
|
protected |
|
protected |
|
protected |
|
protected |
Entailments
|
protected |
|
protected |
|
protected |
Grammatical structures
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Named entities
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Parse trees
|
protected |
Parts-of-speech
|
protected |
|
protected |
|
protected |
|
protected |
Sentence-indexed word segments
|
protected |
Semantic graphs
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Sentiments
| boolean grammarscope.io.xml.XMLDocument.stanfordMode = true |
Stanford-compatible mode
|
protected |
|
protected |
Text (rebuilt)
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Tokens
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Triples
|
protected |
|
protected |
Typed dependencies
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
The XML document URL
1.8.17