org.makumba.providers.query.mql
Class MQLFunctionDefinition
java.lang.Object
org.makumba.providers.query.mql.MQLFunctionDefinition
- Direct Known Subclasses:
- NowFunction, SQLDialectFunction
public class MQLFunctionDefinition
- extends Object
This class represents an MQL function, with it's name, return type and required arguments. This definition is then
used to check for correct use of the MQL functions, and set the return type, types of parameters.
- Version:
- $Id: MQLFunction.java,v 1.1 Dec 20, 2008 1:19:31 AM rudi Exp $
- Author:
- Rudolf Mayer
argumentCount
protected int argumentCount
MQLFunctionDefinition
public MQLFunctionDefinition(String name,
String returnType,
MQLFunctionArgument... arguments)
MQLFunctionDefinition
public MQLFunctionDefinition(String name,
String returnType,
String... arguments)
getArguments
public MQLFunctionArgument[] getArguments()
getName
public String getName()
getSQLCommand
public String getSQLCommand()
getReturnType
public String getReturnType()
toString
public String toString()
- Overrides:
toString
in class Object
throwUnexpectedArguments
public OQLParseError throwUnexpectedArguments(int argumentCount)
render
public NameResolver.TextList render(List<NameResolver.TextList> args)
- This default implementation just renders the function by concatenating the function name and all arguments; for
functions that need to modify the name, the argument order, number of arguments, etc., this method provides an
entry point to rewrite it (possibly in a specific SQL dialect).