public static class GraphDecomposition.Bag extends Object implements Iterable<Node>
PathDecomposition
,
TreeDecomposition
Constructor and Description |
---|
GraphDecomposition.Bag(int identifier)
Creates a new empty bag.
|
Modifier and Type | Method and Description |
---|---|
void |
addNeighbor(GraphDecomposition.Bag neighbor)
Adds a neighbor to this bag
|
void |
addNode(Node node)
Adds a node to this bag.
|
void |
addNodeSet(Set<Node> nodes)
Adds a set of nodes to this bag.
|
boolean |
equals(Object o) |
int |
getIdentifier()
Returns the identifier of this bag.
|
Set<GraphDecomposition.Bag> |
getNeighbors()
Returns the set of neighbors of this bag
|
Set<Node> |
getNodes()
Returns the set of nodes contained in this bag.
|
int |
getNumberOfNeighbors()
Returns the number of neighbors of this bag.
|
int |
getSize()
Returns the size of this bag.
|
int |
hashCode() |
Iterator<Node> |
iterator() |
String |
toString() |
public GraphDecomposition.Bag(int identifier)
identifier
- the identifier of the nodepublic int getIdentifier()
public int getSize()
public void addNode(Node node)
node
- the node to be addedpublic void addNodeSet(Set<Node> nodes)
nodes
- the node set to be addedpublic Set<Node> getNodes()
public void addNeighbor(GraphDecomposition.Bag neighbor)
neighbor
- the bag's neighborpublic Set<GraphDecomposition.Bag> getNeighbors()
public int getNumberOfNeighbors()