Package org.openxava.util
Class Align
- java.lang.Object
-
- org.openxava.util.Align
-
- All Implemented Interfaces:
java.io.Serializable
public class Align extends java.lang.Object implements java.io.Serializable
Represents a text (or another element) align.The number of objects of this class is finete and accesible only by final variables or the method
get(int)
.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
Align(int code, java.lang.String description)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object object)
static Align
get(int code)
Obtain align associated to indicated code.static Align[]
getAll()
All available aligns.int
getCode()
java.lang.String
getDescription()
int
hashCode()
boolean
isCenter()
Facilitates ask about what type of align is this.boolean
isDefault()
Facilitates ask about what type of align is this.boolean
isLeft()
Facilitates ask about what type of align is this.boolean
isRight()
Facilitates ask about what type of align is this.java.lang.String
toString()
-
-
-
Method Detail
-
equals
public boolean equals(java.lang.Object object)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
get
public static Align get(int code)
Obtain align associated to indicated code.- Throws:
java.lang.IllegalStateException
- If code does not match with a existing align.
-
getCode
public int getCode()
-
getDescription
public java.lang.String getDescription()
-
getAll
public static Align[] getAll()
All available aligns.- Returns:
- Not null
-
isCenter
public boolean isCenter()
Facilitates ask about what type of align is this.- Returns:
- true if this.equals(Align.CENTER)
-
isDefault
public boolean isDefault()
Facilitates ask about what type of align is this.- Returns:
- true if this.equals(Align.DEFAULT)
-
isRight
public boolean isRight()
Facilitates ask about what type of align is this.- Returns:
- true if this.equals(Align.RIGHT)
-
isLeft
public boolean isLeft()
Facilitates ask about what type of align is this.- Returns:
- true if this.equals(Align.LEFT)
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-