|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jaxen.function.CeilingFunction
4.4 number ceiling(number)
The ceiling function returns the smallest (closest to negative infinity) number that is not less 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 less than zero, but greater than -1, then negative zero is returned.
- Author:
- bob mcwhirter (bob @ werken.com)
- See Also:
- Section 4.4 of the XPath Specification, XPath Specification Errata
Constructor Summary CeilingFunction()
Create a newCeilingFunction
object.
Method Summary Object
call(Context context, List args)
Returns the smallest integer greater than or equal to a number.static Double
evaluate(Object obj, Navigator nav)
Returns the smallest integer greater 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 CeilingFunction
public CeilingFunction()
- Create a new
CeilingFunction
object.
Method Detail call
public Object call(Context context, List args) throws FunctionCallException
- Returns the smallest integer greater than or equal to a number.
- Specified by:
call
in interfaceFunction
- Parameters:
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 aDouble
as if by the XPathnumber()
function- Returns:
- a
Double
containing the smallest integer greater than or equalargs.get(0)
- Throws:
FunctionCallException
- ifargs
has more or less than one item
evaluate
public static Double evaluate(Object obj, Navigator nav)
- Returns the smallest integer greater than or equal to the argument. If necessary, the argument is first converted to a
Double
as if by the XPathnumber()
function.
- Parameters:
obj
- the object whose ceiling is returnednav
- ignored- Returns:
- a
Double
containing the smallest integer greater than or equal toobj
Overview Package Class Use Tree Deprecated Index Help PREV CLASS NEXT CLASS FRAMES NO FRAMES SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD
Copyright © 2001-2007 Codehaus. All Rights Reserved.