treebolic.core
Class HyperLocation

java.lang.Object
  extended by treebolic.core.HyperLocation

public class HyperLocation
extends java.lang.Object

Hypercircle node location in hyperspace

Author:
Bernard Bou

Field Summary
private static double BORDER
          Where border starts (distance to origin)
 Complex center
          Center as mapped by current transform
 Complex center0
          Center as computed by initial layout
 double dist
          Distance to (0,0)
 boolean isBorder
          Whether this hypercircle nears border
 boolean isDirty
          Computation state (set whenever either center or radius or both change)
 double radius
          Radius
 
Constructor Summary
HyperLocation()
          Construct hypercircle
 
Method Summary
 void clone(HyperLocation thisHyperLocation)
          Clone
static double getHyperDistance(Complex z1, Complex z2)
          Distance between 2 points
 void reset()
          Reset to untransformed initial position
 void set(Complex o, double r)
          Set hypercircle data
 java.lang.String toString()
           
 void transform(IHyperTransform t)
          Apply transform to this hypercircle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

BORDER

private static final double BORDER
Where border starts (distance to origin)

See Also:
Constant Field Values

center0

public final Complex center0
Center as computed by initial layout


center

public final Complex center
Center as mapped by current transform


radius

public double radius
Radius


dist

public double dist
Distance to (0,0)


isDirty

public boolean isDirty
Computation state (set whenever either center or radius or both change)


isBorder

public boolean isBorder
Whether this hypercircle nears border

Constructor Detail

HyperLocation

public HyperLocation()
Construct hypercircle

Method Detail

set

public void set(Complex o,
                double r)
Set hypercircle data

Parameters:
o - center
r - radius

reset

public void reset()
Reset to untransformed initial position


clone

public void clone(HyperLocation thisHyperLocation)
Clone

Parameters:
thisHyperLocation - hyper location

transform

public void transform(IHyperTransform t)
Apply transform to this hypercircle

Parameters:
t - transform

getHyperDistance

public static double getHyperDistance(Complex z1,
                                      Complex z2)
Distance between 2 points

Parameters:
z1 - point1
z2 - point2
Returns:
distance between two points

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object