Package mondrian.olap
Enum Class Syntax
- All Implemented Interfaces:
Serializable
,Comparable<Syntax>
,Constable
Enumerated values describing the syntax of an expression.
- Since:
- 21 July, 2003
- Author:
- jhyde
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionDefines syntax for expression invokedobject.[&PROPERTY]
(a variant ofProperty
).Defines syntax for expression invoked as{ARG, ...}
; that is, the set construction operator.Defines syntax for expression invoked asCASE ...
Defines syntax for a CAST expressionCAST(expression AS type)
.Defines the syntax for an empty expression.Defines syntax for expression invokedFUNCTION()
orFUNCTION(args)
.Defines syntax for expression invoked asarg OPERATOR arg
(like '+' or 'AND').Defines syntax for expression generated by the Mondrian system which cannot be specified syntactically.Defines syntax for expression invoked invoked asobject.METHOD()
orobject.METHOD(args)
.Defines syntax for expression invoked as(ARG)
or(ARG, ...)
; that is, parentheses for grouping expressions, and the tuple construction operator.Defines syntax for expression invoked asarg OPERATOR
(likeIS EMPTY
).Defines syntax for expression invoked asOPERATOR arg
(like unary '-').Defines syntax for expression invoked asobject.PROPERTY
.Defines syntax for expression invokedobject.&PROPERTY
(a variant ofProperty
). -
Method Summary
Modifier and TypeMethodDescriptiongetSignature
(String name, int returnType, int[] argTypes) Returns a description of the signature of a function call, for example, "CoalesceEmpty(, )". void
unparse
(String fun, Exp[] args, PrintWriter pw) Converts a call to a function of this syntax into source code.static Syntax
Returns the enum constant of this class with the specified name.static Syntax[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
Function
Defines syntax for expression invokedFUNCTION()
orFUNCTION(args)
. -
Property
Defines syntax for expression invoked asobject.PROPERTY
. -
Method
Defines syntax for expression invoked invoked asobject.METHOD()
orobject.METHOD(args)
. -
Infix
Defines syntax for expression invoked asarg OPERATOR arg
(like '+' or 'AND'). -
Prefix
Defines syntax for expression invoked asOPERATOR arg
(like unary '-'). -
Postfix
Defines syntax for expression invoked asarg OPERATOR
(likeIS EMPTY
). -
Braces
Defines syntax for expression invoked as{ARG, ...}
; that is, the set construction operator. -
Parentheses
Defines syntax for expression invoked as(ARG)
or(ARG, ...)
; that is, parentheses for grouping expressions, and the tuple construction operator. -
Case
Defines syntax for expression invoked asCASE ... END
. -
Internal
Defines syntax for expression generated by the Mondrian system which cannot be specified syntactically. -
Cast
Defines syntax for a CAST expressionCAST(expression AS type)
. -
QuotedProperty
Defines syntax for expression invokedobject.&PROPERTY
(a variant ofProperty
). -
AmpersandQuotedProperty
Defines syntax for expression invokedobject.[&PROPERTY]
(a variant ofProperty
). -
Empty
Defines the syntax for an empty expression. Empty expressions can occur within function calls, and are denoted by a pair of commas with only whitespace between them, for exampleDrillDownLevelTop({[Product].[All Products]}, 3, , [Measures].[Unit Sales])
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
unparse
Converts a call to a function of this syntax into source code.- Parameters:
fun
- Function nameargs
- Arguments to the functionpw
- Writer
-
getSignature
Returns a description of the signature of a function call, for example, "CoalesceEmpty(, )". - Parameters:
name
- Function namereturnType
- Function's return categoryargTypes
- Categories of the function's arguments- Returns:
- Function signature
-