org.apache.fop.fo.expr

Class AbsFunction

Implemented Interfaces:
Function

public class AbsFunction
extends FunctionBase

Class modelling the abs Number Function. See Sec. 5.10.1 of the XSL-FO spec.

Method Summary

Property
eval(Property[] args, PropertyInfo propInfo)
int
nbArgs()

Methods inherited from class org.apache.fop.fo.expr.FunctionBase

getPercentBase, padArgsWithPropertyName

Method Details

eval

public Property eval(Property[] args,
                     PropertyInfo propInfo)
            throws PropertyException
Specified by:
eval in interface Function
Parameters:
args - array of arguments to be evaluated, the first of which should be a numeric value
propInfo - the PropertyInfo object to be evaluated
Returns:
the absolute value of the input
Throws:
PropertyException - for non-numeric input

nbArgs

public int nbArgs()
Specified by:
nbArgs in interface Function
Returns:
1 (the number of arguments required for the abs function)

Copyright 1999-2008 The Apache Software Foundation. All Rights Reserved.