Enum Syntax

java.lang.Object
java.lang.Enum<Syntax>
org.olap4j.mdx.Syntax
All Implemented Interfaces:
Serializable, Comparable<Syntax>, Constable

public enum Syntax extends Enum<Syntax>
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 Constants
    Enum Constant
    Description
    Defines syntax for expression invoked object.[invalid input: '&PROPERTY'] (a variant of Property).
    Defines syntax for expression invoked as {ARG, ...}; that is, the set construction operator.
    Defines syntax for expression invoked as CASE ...
    Defines syntax for a CAST expression CAST(expression AS type).
    Defines the syntax for an empty expression.
    Defines syntax for expression invoked FUNCTION() or FUNCTION(args).
    Defines syntax for expression invoked as arg OPERATOR arg (like '+' or 'AND').
    Defines syntax for expression generated by the system which cannot be specified syntactically.
    Defines syntax for expression invoked invoked as object.METHOD() or object.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 as arg OPERATOR (like IS EMPTY).
    Defines syntax for expression invoked as OPERATOR arg (like unary '-').
    Defines syntax for expression invoked as object.PROPERTY.
    Defines syntax for expression invoked object.invalid input: '&PROPERTY' (a variant of Property).
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    unparse(String operatorName, List<ParseTreeNode> argList, ParseTreeWriter writer)
    Converts a call to a function of this syntax into source code.
    static Syntax
    Returns the enum constant of this type with the specified name.
    static Syntax[]
    Returns an array containing the constants of this enum type, in the order they are declared.

    Methods inherited from class java.lang.Enum

    compareTo, describeConstable, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • Function

      public static final Syntax Function
      Defines syntax for expression invoked FUNCTION() or FUNCTION(args).
    • Property

      public static final Syntax Property
      Defines syntax for expression invoked as object.PROPERTY.
    • Method

      public static final Syntax Method
      Defines syntax for expression invoked invoked as object.METHOD() or object.METHOD(args).
    • Infix

      public static final Syntax Infix
      Defines syntax for expression invoked as arg OPERATOR arg (like '+' or 'AND').
    • Prefix

      public static final Syntax Prefix
      Defines syntax for expression invoked as OPERATOR arg (like unary '-').
    • Postfix

      public static final Syntax Postfix
      Defines syntax for expression invoked as arg OPERATOR (like IS EMPTY).
    • Braces

      public static final Syntax Braces
      Defines syntax for expression invoked as {ARG, ...}; that is, the set construction operator.
    • Parentheses

      public static final Syntax Parentheses
      Defines syntax for expression invoked as (ARG) or (ARG, ...); that is, parentheses for grouping expressions, and the tuple construction operator.
    • Case

      public static final Syntax Case
      Defines syntax for expression invoked as CASE ... END.
    • Internal

      public static final Syntax Internal
      Defines syntax for expression generated by the system which cannot be specified syntactically.
    • Cast

      public static final Syntax Cast
      Defines syntax for a CAST expression CAST(expression AS type).
    • QuotedProperty

      public static final Syntax QuotedProperty
      Defines syntax for expression invoked object.invalid input: '&PROPERTY' (a variant of Property).
    • AmpersandQuotedProperty

      public static final Syntax AmpersandQuotedProperty
      Defines syntax for expression invoked object.[invalid input: '&PROPERTY'] (a variant of Property).
    • Empty

      public static final Syntax 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 example
      DrillDownLevelTop({[Product].[All Products]}, 3, , [Measures].[Unit Sales])
  • Method Details

    • values

      public static Syntax[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static Syntax valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified name
      NullPointerException - if the argument is null
    • unparse

      public void unparse(String operatorName, List<ParseTreeNode> argList, ParseTreeWriter writer)
      Converts a call to a function of this syntax into source code.
      Parameters:
      operatorName - Operator name
      argList - List of arguments
      writer - Writer