public class BasicEdgeAdapter extends Object implements EdgeAdapter
Constructor and Description |
---|
BasicEdgeAdapter(BasicNode root)
Create a new adapter.
|
Modifier and Type | Method and Description |
---|---|
boolean |
acceptHead(Object edge,
Object node)
Return true if the head of the given edge can be attached to the
given node.
|
boolean |
acceptTail(Object edge,
Object node)
Return true if the tail of the given edge can be attached to the
given node.
|
Object |
getHead(Object edge)
Return the head node of the given edge.
|
NodeAdapter |
getHyperContent(Object edge)
Return null.
|
Object |
getParent(Object edge)
Return the graph root.
|
Object |
getTail(Object edge)
Return the tail node of this edge.
|
boolean |
isDirected(Object edge)
Return true.
|
boolean |
isHyper(Object edge)
Return false.
|
void |
setHead(Object edge,
Object head)
Connect an edge to the given head node.
|
void |
setParent(Object edge,
Object parent)
Do nothing.
|
void |
setTail(Object edge,
Object tail)
Connect an edge to the given tail node.
|
public BasicEdgeAdapter(BasicNode root)
public boolean acceptHead(Object edge, Object node)
acceptHead
in interface EdgeAdapter
public boolean acceptTail(Object edge, Object node)
acceptTail
in interface EdgeAdapter
public Object getHead(Object edge)
getHead
in interface EdgeAdapter
public NodeAdapter getHyperContent(Object edge)
getHyperContent
in interface EdgeAdapter
public Object getParent(Object edge)
getParent
in interface EdgeAdapter
public Object getTail(Object edge)
getTail
in interface EdgeAdapter
public boolean isDirected(Object edge)
isDirected
in interface EdgeAdapter
public boolean isHyper(Object edge)
isHyper
in interface EdgeAdapter
public void setHead(Object edge, Object head)
setHead
in interface EdgeAdapter
public void setParent(Object edge, Object parent)
setParent
in interface EdgeAdapter
public void setTail(Object edge, Object tail)
setTail
in interface EdgeAdapter
Copyright © 2024 Central Laboratory of the Research Councils. All Rights Reserved.