|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jaxen.function.FloorFunction
public class FloorFunction
4.4 number floor(number)
The floor function returns the largest (closest to positive infinity) number that is not greater than the argument and that is an integer.... If the argument is NaN, then NaN is returned. If the argument is positive infinity, then positive infinity is returned. If the argument is negative infinity, then negative infinity is returned. If the argument is positive zero, then positive zero is returned. If the argument is negative zero, then negative zero is returned. If the argument is greater than zero, but less than 1, then positive zero is returned.
Constructor Summary | |
---|---|
FloorFunction()
Create a new FloorFunction object. |
Method Summary | |
---|---|
Object |
call(Context context,
List args)
Returns the largest integer less than or equal to a number. |
static Double |
evaluate(Object obj,
Navigator nav)
Returns the largest integer less than or equal to the argument. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FloorFunction()
FloorFunction
object.
Method Detail |
---|
public Object call(Context context, List args) throws FunctionCallException
call
in interface Function
context
- the context at the point in the
expression when the function is calledargs
- a list with exactly one item which will be converted to a
Double
as if by the XPath number()
function
Double
containing the largest integer less than or equal
to args.get(0)
FunctionCallException
- if args
has more or less than one itempublic static Double evaluate(Object obj, Navigator nav)
Double
as if by the XPath number()
function.
obj
- the object whose floor is returnednav
- ignored
Double
containing the largest integer less
than or equal to obj
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |