|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.graphstream.algorithm.measure.AbstractCentrality
public abstract class AbstractCentrality
Base class for centrality measures. Subclasses should implements a
computeCentrality()
method where centrality values will be stored in
data
.
Nested Class Summary | |
---|---|
static class |
AbstractCentrality.NormalizationMode
|
Method Summary | |
---|---|
void |
compute()
Run the algorithm. |
void |
copyValuesTo(String attribute)
Copy values previously computed to a specific attribute. |
void |
copyValuesTo(String attribute,
AbstractCentrality.NormalizationMode normalize)
Copy values previously computed to a specific attribute. |
String |
getCentralityAttribute()
Getter for centralityAttribute . |
AbstractCentrality.NormalizationMode |
getNormalizationMode()
Getter for normalize . |
void |
init(org.graphstream.graph.Graph graph)
Initialization of the algorithm. |
void |
setCentralityAttribute(String centralityAttribute)
Setter for centralityAttribute . |
void |
setNormalizationMode(AbstractCentrality.NormalizationMode normalize)
Setter for normalize . |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public void init(org.graphstream.graph.Graph graph)
Algorithm
Algorithm.compute()
method to initialize or reset the algorithm according
to the new given graph.
init
in interface Algorithm
graph
- The graph this algorithm is using.public void compute()
Algorithm
Algorithm.init(Graph)
method has to be called
before computing.
compute
in interface Algorithm
Algorithm.init(Graph)
public void copyValuesTo(String attribute)
compute()
method needs to have been call before calling this
one.
attribute
- destination attribute where values of centrality will be
storedpublic void copyValuesTo(String attribute, AbstractCentrality.NormalizationMode normalize)
compute()
method needs to have been call before calling this
one.
attribute
- destination attribute where values of centrality will be
storednormalize
- defines the way that values have to be normalizedpublic String getCentralityAttribute()
centralityAttribute
.
centralityAttribute
public void setCentralityAttribute(String centralityAttribute)
centralityAttribute
.
centralityAttribute
- new value of centralityAttribute
public AbstractCentrality.NormalizationMode getNormalizationMode()
normalize
.
normalize
public void setNormalizationMode(AbstractCentrality.NormalizationMode normalize)
normalize
.
normalize
- new value of normalize
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |