|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.extex.core.dimen.DimenConstant
public class DimenConstant
This class provides objects of type Dimen
where all assignment methods are nit present. Thus the object is in fact
immutable.
| Field Summary | |
|---|---|
static long |
ONE
The constant ONE contains the internal representation for 1pt. |
protected static long |
serialVersionUID
The constant serialVersionUID contains the id for serialization. |
protected long |
value
The field value contains the integer representation of the dimen register in sp if the order is 0. |
| Constructor Summary | |
|---|---|
DimenConstant(FixedDimen value)
Creates a new object. |
|
DimenConstant(long value)
Creates a new object. |
|
| Method Summary | |
|---|---|
FixedDimen |
copy()
Create a copy of this instance with the same order and value. |
boolean |
eq(FixedDimen d)
Compares the current instance with another GlueComponent for equality. |
boolean |
ge(FixedDimen d)
Compares the current instance with another GlueComponent. |
long |
getValue()
Getter for the value in scaled points (sp). |
boolean |
gt(FixedDimen d)
Compares the current instance with another GlueComponent. |
boolean |
le(FixedDimen d)
Compares the current instance with another GlueComponent. |
boolean |
lt(FixedDimen d)
Compares the current instance with another GlueComponent. |
boolean |
ne(FixedDimen d)
Compares the current instance with another GlueComponent for equality. |
java.lang.String |
toString()
Determine the printable representation of the object. |
void |
toString(java.lang.StringBuffer sb)
Determine the printable representation of the object and append it to the given StringBuffer. |
void |
toString(java.lang.StringBuffer sb,
char c1,
char c2)
Determine the printable representation of the object and append it to the given StringBuffer. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected static final long serialVersionUID
public static final long ONE
protected long value
| Constructor Detail |
|---|
public DimenConstant(FixedDimen value)
value - the value to be storedpublic DimenConstant(long value)
value - the value to be stored| Method Detail |
|---|
public FixedDimen copy()
copy in interface FixedDimenpublic boolean eq(FixedDimen d)
eq in interface FixedDimend - the other GlueComponent to compare to. If this parameter is
null then the comparison fails.
true iff |this| == |d| and ord(this) == ord(d)public boolean ge(FixedDimen d)
ge in interface FixedDimend - the other GlueComponent to compare to
true iff this is greater or equal to dpublic long getValue()
getValue in interface FixedDimenpublic boolean gt(FixedDimen d)
gt in interface FixedDimend - the other GlueComponent to compare to
true iff |this| > |d|public boolean le(FixedDimen d)
le in interface FixedDimend - the other GlueComponent to compare to
true iff this is less or equal to dpublic boolean lt(FixedDimen d)
lt in interface FixedDimend - the other GlueComponent to compare to
true iff ord(this) == ord(d) && |this| < |d|
or ord(this) < ord(d)public boolean ne(FixedDimen d)
ne in interface FixedDimend - the other GlueComponent to compare to. If this parameter is
null then the comparison fails.
false iff |this| == |d| public java.lang.String toString()
toString in interface FixedDimentoString in class java.lang.ObjecttoString(StringBuffer)public void toString(java.lang.StringBuffer sb)
toString in interface FixedDimensb - the output string buffertoString()
public void toString(java.lang.StringBuffer sb,
char c1,
char c2)
sb - the output string bufferc1 - the first character for the length of order 0c2 - the second character for the length of order 0toString(StringBuffer)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||