eu.monnetproject.lemon.impl
Class NodeImpl

java.lang.Object
  extended by eu.monnetproject.lemon.URIValue
      extended by eu.monnetproject.lemon.URIElement
          extended by eu.monnetproject.lemon.impl.LemonElementImpl
              extended by eu.monnetproject.lemon.impl.NodeImpl
All Implemented Interfaces:
IntrospectableElement, ReaderAccepter, LemonElement, LemonElementOrPredicate, Node, Serializable

public class NodeImpl
extends LemonElementImpl
implements Node

Instantiated via LemonFactoryImpl

Author:
John McCrae
See Also:
Serialized Form

Field Summary
 
Fields inherited from class eu.monnetproject.lemon.impl.LemonElementImpl
checkRemote, model, RDF_TYPE, referencers
 
Method Summary
 ReaderAccepter accept(URI pred, String value, LinguisticOntology lingOnto, AccepterFactory factory)
           
 void accept(URI pred, String value, String lang, LinguisticOntology lingOnto, AccepterFactory factory)
           
 ReaderAccepter accept(URI pred, URI value, LinguisticOntology lingOnto, AccepterFactory factory)
           
 boolean addEdge(Edge edge, Node edgeVal)
          Add an edge to the tree
 Constituent getConstituent()
          Get the constituent of the node, that is the phrase trype
 Collection<Node> getEdge(Edge edge)
          Get the edges to other nodes of a given arc type
 Map<Edge,Collection<Node>> getEdges()
          Get the edges to other nodes
 PhraseTerminal getLeaf()
          Get the leaf of the node.
 Text getSeparator()
          Get the separator value between the subnodes.
 void merge(ReaderAccepter accepter, LinguisticOntology lingOnto, AccepterFactory factory)
           
 boolean removeEdge(Edge edge, Node edgeVal)
          Remove an edge from the tree
 void setConstituent(Constituent constituent)
          Set the constituent of the node
 void setLeaf(PhraseTerminal product)
          Set the leaf of the node
 void setSeparator(Text separator)
          Set the separator value between the subnodes
 
Methods inherited from class eu.monnetproject.lemon.impl.LemonElementImpl
accept, acceptProperties, addAnnotation, addPredElem, addPredElemDirect, addProperty, addReference, addStrElem, addStrElemDirect, addType, addTypeDirect, clearAll, defaultAccept, defaultAccept, defaultAccept, defaultMerge, doAccept, follow, follow, getAnnotations, getAnnotations, getElements, getModelName, getPredElem, getPredElems, getProperty, getPropertys, getStrElem, getStrElems, getStrText, getTypes, isMultiReferenced, merge, merge, mergeIn, printAsBlankNode, printAsBlankNode, printURI, refers, removeAnnotation, removePredElem, removeProperty, removeReference, removeStrElem, removeType, resolveRemote, setStrElem, setStrElemDirect, setStrText, setStrTextDirect, updateAddPredElem, updateReference, visit, write
 
Methods inherited from class eu.monnetproject.lemon.URIElement
equals, getID, hashCode, toString
 
Methods inherited from class eu.monnetproject.lemon.URIValue
getInfHash, getURI
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface eu.monnetproject.lemon.model.LemonElement
addAnnotation, addProperty, addType, getAnnotations, getAnnotations, getID, getProperty, getPropertys, getTypes, removeAnnotation, removeProperty, removeType
 
Methods inherited from interface eu.monnetproject.lemon.model.LemonElementOrPredicate
getURI
 

Method Detail

getConstituent

public Constituent getConstituent()
Description copied from interface: Node
Get the constituent of the node, that is the phrase trype

Specified by:
getConstituent in interface Node

setConstituent

public void setConstituent(Constituent constituent)
Description copied from interface: Node
Set the constituent of the node

Specified by:
setConstituent in interface Node

getEdges

public Map<Edge,Collection<Node>> getEdges()
Description copied from interface: Node
Get the edges to other nodes

Specified by:
getEdges in interface Node

getEdge

public Collection<Node> getEdge(Edge edge)
Description copied from interface: Node
Get the edges to other nodes of a given arc type

Specified by:
getEdge in interface Node

addEdge

public boolean addEdge(Edge edge,
                       Node edgeVal)
Description copied from interface: Node
Add an edge to the tree

Specified by:
addEdge in interface Node

removeEdge

public boolean removeEdge(Edge edge,
                          Node edgeVal)
Description copied from interface: Node
Remove an edge from the tree

Specified by:
removeEdge in interface Node

getLeaf

public PhraseTerminal getLeaf()
Description copied from interface: Node
Get the leaf of the node. A node must have either a leaf xor zero or more edges

Specified by:
getLeaf in interface Node

setLeaf

public void setLeaf(PhraseTerminal product)
Description copied from interface: Node
Set the leaf of the node

Specified by:
setLeaf in interface Node

getSeparator

public Text getSeparator()
Description copied from interface: Node
Get the separator value between the subnodes. This will most likely be a single space

Specified by:
getSeparator in interface Node

setSeparator

public void setSeparator(Text separator)
Description copied from interface: Node
Set the separator value between the subnodes

Specified by:
setSeparator in interface Node

accept

public ReaderAccepter accept(URI pred,
                             URI value,
                             LinguisticOntology lingOnto,
                             AccepterFactory factory)
Specified by:
accept in interface ReaderAccepter

accept

public ReaderAccepter accept(URI pred,
                             String value,
                             LinguisticOntology lingOnto,
                             AccepterFactory factory)
Specified by:
accept in interface ReaderAccepter

accept

public void accept(URI pred,
                   String value,
                   String lang,
                   LinguisticOntology lingOnto,
                   AccepterFactory factory)
Specified by:
accept in interface ReaderAccepter

merge

public void merge(ReaderAccepter accepter,
                  LinguisticOntology lingOnto,
                  AccepterFactory factory)
Specified by:
merge in interface ReaderAccepter


Copyright © 2012. All Rights Reserved.