org.apache.pivot.wtk
Class CornerRadii

java.lang.Object
  extended by org.apache.pivot.wtk.CornerRadii
All Implemented Interfaces:
Serializable

public final class CornerRadii
extends Object
implements Serializable

Class representing the corner radii of a rectangular object.

See Also:
Serialized Form

Field Summary
static String BOTTOM_LEFT_KEY
           
static String BOTTOM_RIGHT_KEY
           
 int bottomLeft
           
 int bottomRight
           
static CornerRadii NONE
          Corner radii whose top, left, bottom, and right values are all zero.
static String TOP_LEFT_KEY
           
static String TOP_RIGHT_KEY
           
 int topLeft
           
 int topRight
           
 
Constructor Summary
CornerRadii(CornerRadii cornerRadii)
           
CornerRadii(Dictionary<String,?> cornerRadii)
          Construct a CornerRadii object from a dictionary specifying values for each of the four corners
CornerRadii(int radius)
           
CornerRadii(int topLeft, int topRight, int bottomLeft, int bottomRight)
           
 
Method Summary
static CornerRadii decode(String value)
           
 boolean equals(Object object)
           
 int hashCode()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

topLeft

public final int topLeft

topRight

public final int topRight

bottomLeft

public final int bottomLeft

bottomRight

public final int bottomRight

TOP_LEFT_KEY

public static final String TOP_LEFT_KEY
See Also:
Constant Field Values

TOP_RIGHT_KEY

public static final String TOP_RIGHT_KEY
See Also:
Constant Field Values

BOTTOM_LEFT_KEY

public static final String BOTTOM_LEFT_KEY
See Also:
Constant Field Values

BOTTOM_RIGHT_KEY

public static final String BOTTOM_RIGHT_KEY
See Also:
Constant Field Values

NONE

public static final CornerRadii NONE
Corner radii whose top, left, bottom, and right values are all zero.

Constructor Detail

CornerRadii

public CornerRadii(int radius)

CornerRadii

public CornerRadii(CornerRadii cornerRadii)

CornerRadii

public CornerRadii(int topLeft,
                   int topRight,
                   int bottomLeft,
                   int bottomRight)

CornerRadii

public CornerRadii(Dictionary<String,?> cornerRadii)
Construct a CornerRadii object from a dictionary specifying values for each of the four corners

Parameters:
cornerRadii - A dictionary with keys "topLeft", "topRight", "bottomLeft", "bottomRight", all with numeric values. Omitted values are treated as zero.
Method Detail

equals

public boolean equals(Object object)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object

decode

public static CornerRadii decode(String value)