|
fop 0.95 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.fop.traits.MinOptMax
public class MinOptMax
This class holds the resolved (as mpoints) form of a LengthRange or Space type Property value. MinOptMax values are used during layout calculations. The instance variables are package visible.
Field Summary | |
---|---|
int |
max
|
int |
min
Publicly visible min(imum), opt(imum) and max(imum) values. |
int |
opt
|
Constructor Summary | |
---|---|
MinOptMax()
New min/opt/max with zero values. |
|
MinOptMax(int val)
New min/opt/max with one fixed value. |
|
MinOptMax(int min,
int opt,
int max)
New min/opt/max with the three values. |
|
MinOptMax(MinOptMax op)
Copy constructor. |
Method Summary | |
---|---|
void |
add(int len)
Adds a length to all components. |
void |
add(int min,
int opt,
int max)
Adds min, opt and max to their counterpart components. |
void |
add(MinOptMax op)
Adds another MinOptMax instance to this one. |
static MinOptMax |
add(MinOptMax op1,
MinOptMax op2)
Adds one MinOptMax instance to another returning a new one. |
java.lang.Object |
clone()
|
boolean |
isElastic()
|
boolean |
isNonZero()
|
static MinOptMax |
multiply(MinOptMax op1,
double mult)
Multiplies a MinOptMax instance with a factor returning a new instance. |
void |
subtract(MinOptMax op)
Subtracts another MinOptMax instance from this one. |
static MinOptMax |
subtract(MinOptMax op1,
MinOptMax op2)
Subtracts one MinOptMax instance from another returning a new one. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public int min
public int opt
public int max
Constructor Detail |
---|
public MinOptMax()
public MinOptMax(int val)
val
- the value for min, opt and maxpublic MinOptMax(int min, int opt, int max)
min
- the minimum valueopt
- the optimum valuemax
- the maximum valuepublic MinOptMax(MinOptMax op)
op
- the MinOptMax object to copyMethod Detail |
---|
public java.lang.Object clone()
clone
in class java.lang.Object
public static MinOptMax subtract(MinOptMax op1, MinOptMax op2)
op1
- first instance to subtract fromop2
- second instance
public static MinOptMax add(MinOptMax op1, MinOptMax op2)
op1
- first instanceop2
- second instance
public static MinOptMax multiply(MinOptMax op1, double mult)
op1
- MinOptMax instancemult
- multiplier
public void add(MinOptMax op)
op
- the other instancepublic void add(int min, int opt, int max)
min
- the value to add to the minimum valueopt
- the value to add to the optimum valuemax
- the value to add to the maximum valuepublic void add(int len)
len
- the length to addpublic void subtract(MinOptMax op)
op
- the other instancepublic boolean isNonZero()
public boolean isElastic()
public java.lang.String toString()
toString
in class java.lang.Object
|
fop 0.95 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |