ElegantJ Data Tables Java API Specification v1.1

com.elegantj.data.parser.postfixmathcommand
Class PostfixMathCommand

java.lang.Object
  extended bycom.elegantj.data.parser.postfixmathcommand.PostfixMathCommand
All Implemented Interfaces:
PostfixMathCommandI
Direct Known Subclasses:
Abs, Add, And, Asc, Avg, BooleanValue, ByteValue, Ceil, Char, Cos, Count, CumulativePercent, CumulativeSum, DateDate, DateTime, Day, DayName, DayNumber, DaysAfter, Divide, DoubleValue, Equal, Exp, Fact, Fill, First, FloatValue, Floor, Greater, GreaterEqual, Hour, If, IndexOfChar, IndexOfString, IntValue, IsDate, IsNull, IsNumber, IsTime, Large, Last, Left, LeftTrim, Length, Less, LessEqual, Log, LogTen, LongValue, LowerCase, Match, Max, Maximum, Median, Min, Minimum, Minute, Mod, Mode, Month, Multiply, NotEqual, Now, Or, Page, PageAcross, PageCount, PageCountAcross, Percent, Pi, Power, RandomNumber, RelativeDate, RelativeTime, Replace, Reverse, Rgb, Right, RightTrim, Round, Second, ShortValue, Sign, Sin, Small, Space, Sqrt, Substring, Subtract, Sum, Tan, TimeTime, Today, ToString, Trim, Truncate, UMinus, UpperCase, WhenThen, Year

public abstract class PostfixMathCommand
extends java.lang.Object
implements PostfixMathCommandI

The PostfixMathCommand abstract class provides the utitlity methods to execute and process the command method by node.
The subclass of this class should override the run method. Determines the number of the arguments, types of the arguments and return parameter type.


Constructor Summary
PostfixMathCommand(int numberOfParameters, java.lang.Class returnType, java.lang.Class[] parameterTypes)
          Creates a PostfixMathCommand with specified number of arguments, types of the arguments and return type.
 
Method Summary
 void checkStack(java.util.Stack inStack)
          Checks the stack of the arguments.
 int getNumberOfParameters()
          Returns the number of the arguments
 java.lang.Class[] getParameterTypes()
          Returns the types of the arguments
 java.lang.Class getReturnType()
          Returns the return parameter type
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.elegantj.data.parser.postfixmathcommand.PostfixMathCommandI
run
 

Constructor Detail

PostfixMathCommand

public PostfixMathCommand(int numberOfParameters,
                          java.lang.Class returnType,
                          java.lang.Class[] parameterTypes)
Creates a PostfixMathCommand with specified number of arguments, types of the arguments and return type.

Parameters:
numberOfParameters - the number of the arguments
returnType - the return parameter type
parameterTypes - the types of the arguments
Method Detail

checkStack

public void checkStack(java.util.Stack inStack)
                throws CommandFailedException,
                       ArgumentRequiredException,
                       InvalidArgumentException
Checks the stack of the arguments. It Checks the number of arguments, type of arguments and the return type.

Parameters:
inStack - the stack of the arguments
Throws:
CommandFailedException
ArgumentRequiredException
InvalidArgumentException

getNumberOfParameters

public int getNumberOfParameters()
Returns the number of the arguments

Returns:
an integer representing the number of the arguments

getReturnType

public java.lang.Class getReturnType()
Returns the return parameter type

Returns:
a class representing the return parameter type

getParameterTypes

public java.lang.Class[] getParameterTypes()
Returns the types of the arguments

Returns:
a class array representing the types of the arguments

ElegantJ Data Tables Java API Specification v1.1

Submit a bug or feature

Copyright(c)
Elegant Microweb Technologies Pvt. Ltd.
www.elegantmicroweb.com
www.elegantjbeans.com
All Rights Reserved.