V
- the vertex typepublic class RandomLocationTransformer<V> extends Object implements com.google.common.base.Function<V,Point2D>
Note: the generated values are not cached, so apply() will generate a new random
location for the passed vertex every time it is called. If you want a consistent value,
wrap this layout's generated values in a StaticLayout
instance.
Constructor and Description |
---|
RandomLocationTransformer(Dimension d)
Creates an instance with the specified size which uses the current time
as the random seed.
|
RandomLocationTransformer(Dimension d,
long seed)
Creates an instance with the specified dimension and random seed.
|
public RandomLocationTransformer(Dimension d)
d
- the size of the layout areapublic RandomLocationTransformer(Dimension d, long seed)
d
- the size of the layout areaseed
- the seed for the internal random number generatorCopyright © 2015. All rights reserved.