com.mindfusion.diagramming
Class NodeConstraints

java.lang.Object
  extended by com.mindfusion.diagramming.NodeConstraints
All Implemented Interfaces:
java.io.Externalizable, java.io.Serializable

public class NodeConstraints
extends java.lang.Object
implements java.io.Externalizable

Represents the movement and size constraints that can be applied to a node.

See Also:
Serialized Form

Constructor Summary
NodeConstraints()
          Initializes a new NodeConstraints instance.
 
Method Summary
 java.lang.Object clone()
          Creates a copy of this NodeConstraints instance.
 float getMaxHeight()
          Gets the largest allowed height for the node.
 float getMaxWidth()
          Gets the largest allowed width for the node.
 float getMinHeight()
          Gets the smallest allowed height for the node.
 float getMinWidth()
          Gets the smallest allowed width for the node.
 int getMoveDirection()
          Gets a value indicating the movement direction constraint.
 void readExternal(java.io.ObjectInput in)
          Implements Externalizable.
 void setMaxHeight(float value)
          Sets the largest allowed height for the node.
 void setMaxWidth(float value)
          Sets the largest allowed width for the node.
 void setMinHeight(float value)
          Sets the smallest allowed height for the node.
 void setMinWidth(float value)
          Sets the smallest allowed width for the node.
 void setMoveDirection(int value)
          Sets a value indicating the movement direction constraint.
 void writeExternal(java.io.ObjectOutput out)
          Implements Externalizable.
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NodeConstraints

public NodeConstraints()
Initializes a new NodeConstraints instance.

Method Detail

clone

public java.lang.Object clone()
Creates a copy of this NodeConstraints instance.

Overrides:
clone in class java.lang.Object
Returns:
the new NodeConstraints object.

getMoveDirection

public int getMoveDirection()
Gets a value indicating the movement direction constraint.

Returns:
One of the DirectionConstraint constants.

setMoveDirection

public void setMoveDirection(int value)
Sets a value indicating the movement direction constraint.

Parameters:
value - One of the DirectionConstraint constants.

getMinWidth

public float getMinWidth()
Gets the smallest allowed width for the node.

Returns:
A float value specifying the minimal node width.

setMinWidth

public void setMinWidth(float value)
Sets the smallest allowed width for the node.

Parameters:
value - A float value specifying the minimal node width.

getMinHeight

public float getMinHeight()
Gets the smallest allowed height for the node.

Returns:
A float value specifying the minimal node height.

setMinHeight

public void setMinHeight(float value)
Sets the smallest allowed height for the node.

Parameters:
value - A float value specifying the minimal node height.

getMaxWidth

public float getMaxWidth()
Gets the largest allowed width for the node.

Returns:
A float value specifying the maximal node width.

setMaxWidth

public void setMaxWidth(float value)
Sets the largest allowed width for the node.

Parameters:
value - A float value specifying the maximal node width.

getMaxHeight

public float getMaxHeight()
Gets the largest allowed height for the node.

Returns:
A float value specifying the maximal node height.

setMaxHeight

public void setMaxHeight(float value)
Sets the largest allowed height for the node.

Parameters:
value - A float value specifying the maximal node height.

writeExternal

public void writeExternal(java.io.ObjectOutput out)
                   throws java.io.IOException
Implements Externalizable.

Specified by:
writeExternal in interface java.io.Externalizable
Throws:
java.io.IOException

readExternal

public void readExternal(java.io.ObjectInput in)
                  throws java.io.IOException,
                         java.lang.ClassNotFoundException
Implements Externalizable.

Specified by:
readExternal in interface java.io.Externalizable
Throws:
java.io.IOException
java.lang.ClassNotFoundException