|
Gephi Toolkit Javadoc | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface Transformer<Target>
Transformers role is to transform nodes/edges numerical attributes to visual signs (e.g. color or sizes). It uses a normalized real number between zero and one to output a meaningful value.
Transformers can be applied to a subset of values using lower/bound filter values.
Default transformers implemented in the RankingPlugin:
Ranking| Field Summary | |
|---|---|
static java.lang.String |
LABEL_COLOR
|
static java.lang.String |
LABEL_SIZE
|
static java.lang.String |
RENDERABLE_COLOR
|
static java.lang.String |
RENDERABLE_SIZE
|
| Method Summary | |
|---|---|
float |
getLowerBound()
Returns the lower bound filter value. |
float |
getUpperBound()
Returns the upper bound filter value. |
boolean |
isInBounds(float value)
Returns true if value is within the lower and
the upper bound. |
void |
setLowerBound(float lowerBound)
Sets the lower filter bound. |
void |
setUpperBound(float upperBound)
Sets the upper filter bound. |
java.lang.Object |
transform(Target target,
float normalizedValue)
Transforms target with normalizedValue between
zero and one. |
| Field Detail |
|---|
static final java.lang.String RENDERABLE_COLOR
static final java.lang.String RENDERABLE_SIZE
static final java.lang.String LABEL_COLOR
static final java.lang.String LABEL_SIZE
| Method Detail |
|---|
void setLowerBound(float lowerBound)
lowerBound - the lower bound filter valuevoid setUpperBound(float upperBound)
upperBound - the upper bound filter valuefloat getLowerBound()
float getUpperBound()
boolean isInBounds(float value)
true if value is within the lower and
the upper bound. Typically, this is called before transform()
to know if a value can be processed. By default, this always returns
true, as lower bound is set ot zero and upper bound to one.
value - the value to test if in bounds
true if value superior or equal to lowerBound and
value inferior or equal to upperBound, false otherwise
java.lang.Object transform(Target target,
float normalizedValue)
target with normalizedValue between
zero and one. The method also returns the transformed value, like the color
for instance for a color transformer.
target - the object to transformnormalizedValue - the ranking normalized value
null
|
Gephi Toolkit Javadoc | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||