public class MathFunction extends ADQLFunction
MathFunctionTypeADQLFunction.ParameterIterator| Constructor and Description |
|---|
MathFunction(MathFunction toCopy)
Builds a mathematical function by copying the given one.
|
MathFunction(MathFunctionType t)
Creates a mathematical function without parameter.
|
MathFunction(MathFunctionType t,
ADQLOperand parameter)
Creates a mathematical function with only one parameter.
|
MathFunction(MathFunctionType t,
ADQLOperand parameter1,
ADQLOperand parameter2)
Creates a mathematical function with two parameters.
|
| Modifier and Type | Method and Description |
|---|---|
ADQLObject |
getCopy()
Gets a (deep) copy of this ADQL object.
|
java.lang.String |
getName()
Gets the name of this object in ADQL.
|
int |
getNbParameters()
Gets the number of parameters this function has.
|
ADQLOperand |
getParameter(int index)
Gets the index-th parameter.
|
ADQLOperand[] |
getParameters()
Gets the list of all parameters of this function.
|
MathFunctionType |
getType()
Gets the type of the function (ABS, COS, SIN, ...).
|
boolean |
isGeometry()
Tell whether this operand is a geometrical region or not.
|
boolean |
isNumeric()
Tell whether this operand is numeric or not.
|
boolean |
isString()
Tell whether this operand is a string or not.
|
ADQLOperand |
setParameter(int index,
ADQLOperand replacer)
Replaces the index-th parameter by the given one.
|
adqlIterator, getPosition, paramIterator, setPosition, toADQLpublic MathFunction(MathFunctionType t) throws java.lang.Exception
t - The type of the function.java.lang.Exception - If the given function parameters are incorrect.MathFunction(MathFunctionType, ADQLOperand, ADQLOperand)public MathFunction(MathFunctionType t, ADQLOperand parameter) throws java.lang.Exception
t - The type of the function.parameter - Its only parameter.java.lang.Exception - If the given function parameters are incorrect.MathFunction(MathFunctionType, ADQLOperand, ADQLOperand)public MathFunction(MathFunctionType t, ADQLOperand parameter1, ADQLOperand parameter2) throws java.lang.Exception
t - The type of the function.parameter1 - Its first parameter.parameter2 - Its second parameter.java.lang.Exception - If the given function parameters are incorrect.public MathFunction(MathFunction toCopy) throws java.lang.Exception
toCopy - The mathematical function to copy.java.lang.Exception - If there is an error during the copy.public final MathFunctionType getType()
MathFunctionTypepublic ADQLObject getCopy() throws java.lang.Exception
ADQLObjectjava.lang.Exception - If there is any error during the copy.public java.lang.String getName()
ADQLObjectpublic final boolean isNumeric()
ADQLOperandpublic final boolean isString()
ADQLOperandpublic final boolean isGeometry()
ADQLOperandpublic ADQLOperand[] getParameters()
ADQLFunctiongetParameters in class ADQLFunctionpublic int getNbParameters()
ADQLFunctiongetNbParameters in class ADQLFunctionpublic ADQLOperand getParameter(int index) throws java.lang.ArrayIndexOutOfBoundsException
ADQLFunctiongetParameter in class ADQLFunctionindex - Parameter number.java.lang.ArrayIndexOutOfBoundsException - If the index is incorrect (index < 0 || index >= getNbParameters()).public ADQLOperand setParameter(int index, ADQLOperand replacer) throws java.lang.ArrayIndexOutOfBoundsException, java.lang.NullPointerException, java.lang.Exception
ADQLFunctionsetParameter in class ADQLFunctionindex - Index of the parameter to replace.replacer - The replacer.java.lang.ArrayIndexOutOfBoundsException - If the index is incorrect (index < 0 || index >= getNbParameters()).java.lang.NullPointerException - If a required parameter must be replaced by a NULL object.java.lang.Exception - If another error occurs.