Package ndg :: Package xacml :: Package core :: Package functions :: Package v1 :: Module round :: Class Round
[hide private]

Class Round

source code

      object --+    
               |    
AbstractFunction --+
                   |
                  Round

Base class for XACML <type>-round functions

Nested Classes [hide private]

Inherited from AbstractFunction: __metaclass__

Instance Methods [hide private]
float
evaluate(self, num)
Execute mathematical round up of the input number
source code

Inherited from AbstractFunction: __init__

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
NoneType (must be string in derived type) FUNCTION_NS = 'urn:oasis:names:tc:xacml:1.0:function:round'
namespace for the given function
  __abstractmethods__ = frozenset([])

Inherited from AbstractFunction: V1_0_FUNCTION_NS, V2_0_FUNCTION_NS

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

evaluate(self, num)

source code 

Execute mathematical round up of the input number

Parameters:
  • num (int / long / float) - number to round up
Returns: float
derived type should return True for match, False otherwise
Raises:
  • TypeError - incorrect type for input
Overrides: AbstractFunction.evaluate