org.gephi.layout.plugin.force
Class ForceVector
java.lang.Object
org.gephi.layout.plugin.force.ForceVector
- All Implemented Interfaces:
- Spatial, LayoutData
- Direct Known Subclasses:
- ForceLayoutData
public class ForceVector
- extends java.lang.Object
- implements Spatial, LayoutData
- Author:
- Helder Suzuki
Field Summary |
protected float |
x
|
protected float |
y
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
x
protected float x
y
protected float y
ForceVector
public ForceVector(ForceVector vector)
ForceVector
public ForceVector(float x,
float y)
ForceVector
public ForceVector()
x
public float x()
- Specified by:
x
in interface Spatial
y
public float y()
- Specified by:
y
in interface Spatial
z
public float z()
- Specified by:
z
in interface Spatial
setX
public void setX(float x)
setY
public void setY(float y)
add
public void add(ForceVector f)
multiply
public void multiply(float s)
subtract
public void subtract(ForceVector f)
getEnergy
public float getEnergy()
getNorm
public float getNorm()
normalize
public ForceVector normalize()
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object