org.eclipse.ocl.examples.library.numeric
Class NumericAbsOperation

java.lang.Object
  extended by org.eclipse.ocl.examples.domain.library.AbstractFeature
      extended by org.eclipse.ocl.examples.domain.library.AbstractOperation
          extended by org.eclipse.ocl.examples.domain.library.AbstractUnaryOperation
              extended by org.eclipse.ocl.examples.library.numeric.AbstractNumericUnaryOperation
                  extended by org.eclipse.ocl.examples.library.numeric.NumericAbsOperation
All Implemented Interfaces:
LibraryFeature, LibraryOperation, LibraryUnaryOperation

public class NumericAbsOperation
extends AbstractNumericUnaryOperation

AbsOperation realises the abs() library operation.


Field Summary
static NumericAbsOperation INSTANCE
           
 
Constructor Summary
NumericAbsOperation()
           
 
Method Summary
protected  Value evaluateNumeric(NumericValue left)
          Return the result of evaluating the operation on left.
 
Methods inherited from class org.eclipse.ocl.examples.library.numeric.AbstractNumericUnaryOperation
evaluate, evaluateInteger, evaluateReal, evaluateUnlimited
 
Methods inherited from class org.eclipse.ocl.examples.domain.library.AbstractUnaryOperation
evaluate
 
Methods inherited from class org.eclipse.ocl.examples.domain.library.AbstractOperation
argumentsMayBeInvalid
 
Methods inherited from class org.eclipse.ocl.examples.domain.library.AbstractFeature
getLibraryValidator, getValidator
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.ocl.examples.domain.library.LibraryOperation
argumentsMayBeInvalid
 
Methods inherited from interface org.eclipse.ocl.examples.domain.library.LibraryFeature
getValidator
 

Field Detail

INSTANCE

public static final NumericAbsOperation INSTANCE
Constructor Detail

NumericAbsOperation

public NumericAbsOperation()
Method Detail

evaluateNumeric

protected Value evaluateNumeric(NumericValue left)
                         throws InvalidValueException
Description copied from class: AbstractNumericUnaryOperation
Return the result of evaluating the operation on left. A null return or an exception may be used for invalid.

Overrides:
evaluateNumeric in class AbstractNumericUnaryOperation
Throws:
InvalidValueException