Impala
Impalaistheopensource,nativeanalyticdatabaseforApacheHadoop.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
com.cloudera.impala.analysis.CreateUdfStmt Class Reference
Inheritance diagram for com.cloudera.impala.analysis.CreateUdfStmt:
Collaboration diagram for com.cloudera.impala.analysis.CreateUdfStmt:

Public Member Functions

 CreateUdfStmt (FunctionName fnName, FunctionArgs args, TypeDef retTypeDef, HdfsUri location, boolean ifNotExists, HashMap< CreateFunctionStmtBase.OptArg, String > optArgs)
 
void analyze (Analyzer analyzer) throws AnalysisException
 
String getComment ()
 
boolean getIfNotExists ()
 
TCreateFunctionParams toThrift ()
 
String toSql ()
 
void setIsExplain ()
 
boolean isExplain ()
 

Protected Member Functions

Function createFunction (FunctionName fnName, ArrayList< Type > argTypes, Type retType, boolean hasVarArgs)
 
String checkAndGetOptArg (OptArg key) throws AnalysisException
 
void checkOptArgNotSet (OptArg key) throws AnalysisException
 

Protected Attributes

final FunctionName fnName_
 
final FunctionArgs args_
 
final TypeDef retTypeDef_
 
final HdfsUri location_
 
final HashMap
< CreateFunctionStmtBase.OptArg,
String > 
optArgs_
 
final boolean ifNotExists_
 
Function fn_
 
String sqlString_
 
boolean isExplain_ = false
 

Detailed Description

Represents a CREATE FUNCTION statement.

Definition at line 33 of file CreateUdfStmt.java.

Constructor & Destructor Documentation

com.cloudera.impala.analysis.CreateUdfStmt.CreateUdfStmt ( FunctionName  fnName,
FunctionArgs  args,
TypeDef  retTypeDef,
HdfsUri  location,
boolean  ifNotExists,
HashMap< CreateFunctionStmtBase.OptArg, String >  optArgs 
)
inline

Builds a CREATE FUNCTION statement

Parameters
fnName- Name of the function
fnArgs- List of types for the arguments to this function
retType- The type this function returns.
location- Path in HDFS containing the UDA.
ifNotExists- If true, no errors are thrown if the function already exists
additionalArgs- Key/Value pairs for additional arguments. The keys are validated in analyze()

Definition at line 44 of file CreateUdfStmt.java.

Member Function Documentation

String com.cloudera.impala.analysis.CreateFunctionStmtBase.checkAndGetOptArg ( OptArg  key) throws AnalysisException
inlineprotectedinherited
void com.cloudera.impala.analysis.CreateFunctionStmtBase.checkOptArgNotSet ( OptArg  key) throws AnalysisException
inlineprotectedinherited
Function com.cloudera.impala.analysis.CreateUdfStmt.createFunction ( FunctionName  fnName,
ArrayList< Type argTypes,
Type  retType,
boolean  hasVarArgs 
)
inlineprotected

Definition at line 135 of file CreateUdfStmt.java.

String com.cloudera.impala.analysis.CreateFunctionStmtBase.getComment ( )
inlineinherited
boolean com.cloudera.impala.analysis.CreateFunctionStmtBase.getIfNotExists ( )
inlineinherited
boolean com.cloudera.impala.analysis.StatementBase.isExplain ( )
inlineinherited
void com.cloudera.impala.analysis.StatementBase.setIsExplain ( )
inlineinherited
String com.cloudera.impala.analysis.StatementBase.toSql ( )
inlineinherited

Print SQL syntax corresponding to this node.

See Also
com.cloudera.impala.parser.ParseNode::toSql()

Implements com.cloudera.impala.analysis.ParseNode.

Definition at line 41 of file StatementBase.java.

Referenced by com.cloudera.impala.analysis.CreateUdaStmt.analyze(), and com.cloudera.impala.analysis.QueryStmt.createSortInfo().

TCreateFunctionParams com.cloudera.impala.analysis.CreateFunctionStmtBase.toThrift ( )
inlineinherited

Member Data Documentation

final HdfsUri com.cloudera.impala.analysis.CreateFunctionStmtBase.location_
protectedinherited
final TypeDef com.cloudera.impala.analysis.CreateFunctionStmtBase.retTypeDef_
protectedinherited
String com.cloudera.impala.analysis.CreateFunctionStmtBase.sqlString_
protectedinherited

The documentation for this class was generated from the following file: