|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--y.layout.DefaultNodeLayout
This class is a default implementation of the NodeLayout interface.
Field Summary | |
protected double |
h
|
protected double |
w
|
protected double |
x
|
protected double |
y
|
Constructor Summary | |
DefaultNodeLayout()
Creates a new instance of DefaultNodeLayout. |
|
DefaultNodeLayout(double x,
double y,
double width,
double height)
Creates a new instance of DefaultNodeLayout. |
|
DefaultNodeLayout(NodeLayout layout)
Creates a new instance of DefaultNodeLayout as copy of another instance of NodeLayout. |
|
DefaultNodeLayout(YPoint location,
YDimension size)
Creates a new instance of DefaultNodeLayout. |
Method Summary | |
double |
getHeight()
Returns the width of the node. |
double |
getWidth()
Returns the height of the node. |
double |
getX()
Returns X-Coordinate of the upper left corner of the node. |
double |
getY()
Returns Y-Coordinate of the upper left corner of the node. |
void |
setCenter(double x,
double y)
Sets the center coordinates of the node. |
void |
setLocation(double x,
double y)
Sets the coordinates of the upper left corner of the node. |
void |
setSize(double width,
double height)
Sets the size of the node. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected double x
protected double y
protected double w
protected double h
Constructor Detail |
public DefaultNodeLayout()
public DefaultNodeLayout(NodeLayout layout)
layout
- another instance of NodeLayout.public DefaultNodeLayout(double x, double y, double width, double height)
x
- the x-coordinate of the upper left corner of the node.y
- the y-coordinate of the upper left corner of the node.width
- the width of the node.height
- the height of the node.public DefaultNodeLayout(YPoint location, YDimension size)
location
- the upper-left cornder coordinate of the node layout.size
- the size of the node layout.Method Detail |
public void setLocation(double x, double y)
NodeLayout
setLocation
in interface NodeLayout
x
- the x-coordinates of the upper left corner.y
- the y-coordinates of the upper left corner.public void setCenter(double x, double y)
x
- the x-coordinates of the center.y
- the y-coordinates of the centerpublic void setSize(double width, double height)
NodeLayout
setSize
in interface NodeLayout
width
- the width of the node.height
- the heigth of the node.public double getHeight()
NodeLayout
getHeight
in interface NodeLayout
public double getWidth()
NodeLayout
getWidth
in interface NodeLayout
public double getX()
NodeLayout
getX
in interface NodeLayout
public double getY()
NodeLayout
getY
in interface NodeLayout
|
© Copyright 2000-2003, yWorks GmbH. All rights reserved. 2003 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |