protected static final class GraphCanvas.DirectionDisplayPredicate
extends java.lang.Object
implements org.apache.commons.collections15.Predicate
Modifier and Type | Field and Description |
---|---|
protected boolean |
show_d
Show arrows for directed edges
|
protected boolean |
show_u
Show arrows for undirected edges (on both sides)
|
Constructor and Description |
---|
DirectionDisplayPredicate(boolean show_d,
boolean show_u)
Creates the predicate.
|
Modifier and Type | Method and Description |
---|---|
boolean |
evaluate(java.lang.Object context)
Use the specified parameter to perform a test that returns true or
false.
|
void |
showDirected(boolean b)
Set the predicate for directed edges.
|
void |
showUndirected(boolean b)
Set the predicate for undirected edges.
|
protected boolean show_d
protected boolean show_u
public DirectionDisplayPredicate(boolean show_d, boolean show_u)
show_d
- true
if arrows are shown for directed edges.show_u
- true
if arrows are shown for undirected edges.public void showDirected(boolean b)
b
- true
if arrows are shown for directed edges.public void showUndirected(boolean b)
b
- true
if arrows are shown for undirected edges.public boolean evaluate(java.lang.Object context)
true
if the arrow ought to be shown,
else false
.evaluate
in interface org.apache.commons.collections15.Predicate