org.askalon.graph.chart
Class HierarchyLayout

java.lang.Object
  extended by org.askalon.graph.chart.HierarchyLayout

public class HierarchyLayout
extends Object

Allows to specify a layout for a level of the hierarchy chart using the ratio of number of elements to be placed on X-axis : number of elements Z-axis.

Author:
Georg Schild and Franz Endstrasser

Field Summary
static HierarchyLayout FOUR_TO_ONE
          Layouting of components in 4:1 (X axis : Z axis) ratio
static HierarchyLayout HORIZONTAL
          Horizontal layouting of components
static HierarchyLayout ONE_TO_FOUR
          Layouting of components in 1:4 (X axis : Z axis) ratio
static HierarchyLayout ONE_TO_TWO
          Layouting of components in 1:2 (X axis : Z axis) ratio
static HierarchyLayout SQUARE
          Square layouting of components
static HierarchyLayout TWO_TO_ONE
          Layouting of components in 2:1 (X axis : Z axis) ratio
static HierarchyLayout VERTICAL
          Vertical layouting of components
 
Constructor Summary
HierarchyLayout(int layoutRatioX, int layoutRatioZ)
          Creates a new HierarchyLayout.
 
Method Summary
 boolean equals(HierarchyLayout hl)
          Tests the equality of the ratios of two layouts.
 int getLayoutRatioX()
          Gets the X-ratio
 int getLayoutRatioZ()
          Gets the Z-ratio
 String toString()
          Gets the name of this layout.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

HORIZONTAL

public static final HierarchyLayout HORIZONTAL
Horizontal layouting of components


SQUARE

public static final HierarchyLayout SQUARE
Square layouting of components


VERTICAL

public static final HierarchyLayout VERTICAL
Vertical layouting of components


FOUR_TO_ONE

public static final HierarchyLayout FOUR_TO_ONE
Layouting of components in 4:1 (X axis : Z axis) ratio


TWO_TO_ONE

public static final HierarchyLayout TWO_TO_ONE
Layouting of components in 2:1 (X axis : Z axis) ratio


ONE_TO_TWO

public static final HierarchyLayout ONE_TO_TWO
Layouting of components in 1:2 (X axis : Z axis) ratio


ONE_TO_FOUR

public static final HierarchyLayout ONE_TO_FOUR
Layouting of components in 1:4 (X axis : Z axis) ratio

Constructor Detail

HierarchyLayout

public HierarchyLayout(int layoutRatioX,
                       int layoutRatioZ)
Creates a new HierarchyLayout.

See Also:
for a description of parameters
Method Detail

getLayoutRatioX

public int getLayoutRatioX()
Gets the X-ratio

Returns:
X-ratio
See Also:
getLayoutRatioZ()

getLayoutRatioZ

public int getLayoutRatioZ()
Gets the Z-ratio

Returns:
Z-ratio
See Also:
getLayoutRatioX()

equals

public boolean equals(HierarchyLayout hl)
Tests the equality of the ratios of two layouts.

Parameters:
hl - the HierarchyLayout to compare this one with
Returns:
true if the ratios are equal

toString

public String toString()
Gets the name of this layout.

Overrides:
toString in class Object
Returns:
the name of this layout


Part of:
Askalon_Logo
ASKALON Visualisation Diagrams