org.olap4j.metadata
Enum Level.Type

java.lang.Object
  extended by java.lang.Enum<Level.Type>
      extended by org.olap4j.metadata.Level.Type
All Implemented Interfaces:
Serializable, Comparable<Level.Type>
Enclosing interface:
Level

public static enum Level.Type
extends Enum<Level.Type>

Enumeration of the types of a Level.

Several of the values are defined by XMLA, sans the "MDLEVEL_TYPE_" prefix to their name. For example, GEO_CONTINENT corresponds to the value MDLEVEL_TYPE_GEO_CONTINENT for the LEVEL_TYPE property in the MDSCHEMA_LEVELS schema rowset.

Some of the values are specified by XMLA:

  • MDLEVEL_TYPE_GEO_CONTINENT (0x2001)
  • MDLEVEL_TYPE_GEO_REGION (0x2002)
  • MDLEVEL_TYPE_GEO_COUNTRY (0x2003)
  • MDLEVEL_TYPE_GEO_STATE_OR_PROVINCE (0x2004)
  • MDLEVEL_TYPE_GEO_COUNTY (0x2005)
  • MDLEVEL_TYPE_GEO_CITY (0x2006)
  • MDLEVEL_TYPE_GEO_POSTALCODE (0x2007)
  • MDLEVEL_TYPE_GEO_POINT (0x2008)
  • MDLEVEL_TYPE_ORG_UNIT (0x1011)
  • MDLEVEL_TYPE_BOM_RESOURCE (0x1012)
  • MDLEVEL_TYPE_QUANTITATIVE (0x1013)
  • MDLEVEL_TYPE_ACCOUNT (0x1014)
  • MDLEVEL_TYPE_CUSTOMER (0x1021)
  • MDLEVEL_TYPE_CUSTOMER_GROUP (0x1022)
  • MDLEVEL_TYPE_CUSTOMER_HOUSEHOLD (0x1023)
  • MDLEVEL_TYPE_PRODUCT (0x1031)
  • MDLEVEL_TYPE_PRODUCT_GROUP (0x1032)
  • MDLEVEL_TYPE_SCENARIO (0x1015)
  • MDLEVEL_TYPE_UTILITY (0x1016)
  • MDLEVEL_TYPE_PERSON (0x1041)
  • MDLEVEL_TYPE_COMPANY (0x1042)
  • MDLEVEL_TYPE_CURRENCY_SOURCE (0x1051)
  • MDLEVEL_TYPE_CURRENCY_DESTINATION (0x1052)
  • MDLEVEL_TYPE_CHANNEL (0x1061)
  • MDLEVEL_TYPE_REPRESENTATIVE (0x1062)
  • MDLEVEL_TYPE_PROMOTION (0x1071)

    See Also:
    Level.getLevelType(), OlapDatabaseMetaData.getLevels(java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.lang.String)
     

    Enum Constant Summary
    ACCOUNT
               
    BOM_RESOURCE
               
    CHANNEL
               
    COMPANY
               
    CURRENCY_DESTINATION
               
    CURRENCY_SOURCE
               
    CUSTOMER
               
    CUSTOMER_GROUP
               
    CUSTOMER_HOUSEHOLD
               
    GEO_CITY
               
    GEO_CONTINENT
               
    GEO_COUNTRY
               
    GEO_COUNTY
               
    GEO_POINT
               
    GEO_POSTALCODE
               
    GEO_REGION
               
    GEO_STATE_OR_PROVINCE
               
    Null
              Indicates that a level holds the null member.
    ORG_UNIT
               
    PERSON
               
    PRODUCT
               
    PRODUCT_GROUP
               
    PROMOTION
               
    QUANTITATIVE
               
    Regular
              Indicates that the level is not related to time.
    REPRESENTATIVE
               
    SCENARIO
               
    TimeDays
              Indicates that a level refers to days.
    TimeMonths
              Indicates that a level refers to months.
    TimeQuarters
              Indicates that a level refers to quarters.
    TimeWeeks
              Indicates that a level refers to weeks.
    TimeYears
              Indicates that a level refers to years.
    UTILITY
               
     
    Method Summary
    static Level.Type forXmlaOrdinal(int xmlaOrdinal)
              Looks up a Type by its XMLA ordinal.
     boolean isTime()
              Returns whether this is a time-related level (TimeYears, TimeQuarters, TimeMonths, TimeWeeks, TimeDays).
    static Level.Type valueOf(String name)
              Returns the enum constant of this type with the specified name.
    static Level.Type[] values()
              Returns an array containing the constants of this enum type, in the order they are declared.
     int xmlaOrdinal()
              Returns the ordinal code as specified by XMLA.
     
    Methods inherited from class java.lang.Enum
    compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
     
    Methods inherited from class java.lang.Object
    getClass, notify, notifyAll, wait, wait, wait
     

    Enum Constant Detail

    Regular

    public static final Level.Type Regular
    Indicates that the level is not related to time.


    TimeYears

    public static final Level.Type TimeYears
    Indicates that a level refers to years. It must be used in a dimension whose type is Dimension.Type.TIME.


    TimeQuarters

    public static final Level.Type TimeQuarters
    Indicates that a level refers to quarters. It must be used in a dimension whose type is Dimension.Type.TIME.


    TimeMonths

    public static final Level.Type TimeMonths
    Indicates that a level refers to months. It must be used in a dimension whose type is Dimension.Type.TIME.


    TimeWeeks

    public static final Level.Type TimeWeeks
    Indicates that a level refers to weeks. It must be used in a dimension whose type is Dimension.Type.TIME.


    TimeDays

    public static final Level.Type TimeDays
    Indicates that a level refers to days. It must be used in a dimension whose type is Dimension.Type.TIME.


    Null

    public static final Level.Type Null
    Indicates that a level holds the null member.


    GEO_CONTINENT

    public static final Level.Type GEO_CONTINENT

    GEO_REGION

    public static final Level.Type GEO_REGION

    GEO_COUNTRY

    public static final Level.Type GEO_COUNTRY

    GEO_STATE_OR_PROVINCE

    public static final Level.Type GEO_STATE_OR_PROVINCE

    GEO_COUNTY

    public static final Level.Type GEO_COUNTY

    GEO_CITY

    public static final Level.Type GEO_CITY

    GEO_POSTALCODE

    public static final Level.Type GEO_POSTALCODE

    GEO_POINT

    public static final Level.Type GEO_POINT

    ORG_UNIT

    public static final Level.Type ORG_UNIT

    BOM_RESOURCE

    public static final Level.Type BOM_RESOURCE

    QUANTITATIVE

    public static final Level.Type QUANTITATIVE

    ACCOUNT

    public static final Level.Type ACCOUNT

    CUSTOMER

    public static final Level.Type CUSTOMER

    CUSTOMER_GROUP

    public static final Level.Type CUSTOMER_GROUP

    CUSTOMER_HOUSEHOLD

    public static final Level.Type CUSTOMER_HOUSEHOLD

    PRODUCT

    public static final Level.Type PRODUCT

    PRODUCT_GROUP

    public static final Level.Type PRODUCT_GROUP

    SCENARIO

    public static final Level.Type SCENARIO

    UTILITY

    public static final Level.Type UTILITY

    PERSON

    public static final Level.Type PERSON

    COMPANY

    public static final Level.Type COMPANY

    CURRENCY_SOURCE

    public static final Level.Type CURRENCY_SOURCE

    CURRENCY_DESTINATION

    public static final Level.Type CURRENCY_DESTINATION

    CHANNEL

    public static final Level.Type CHANNEL

    REPRESENTATIVE

    public static final Level.Type REPRESENTATIVE

    PROMOTION

    public static final Level.Type PROMOTION
    Method Detail

    values

    public static Level.Type[] values()
    Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
    for (Level.Type c : Level.Type.values())
        System.out.println(c);
    

    Returns:
    an array containing the constants of this enum type, in the order they are declared

    valueOf

    public static Level.Type 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.)

    Throws:
    IllegalArgumentException - if this enum type has no constant with the specified name
    NullPointerException - if the argument is null
    Parameters:
    name - the name of the enum constant to be returned.
    Returns:
    the enum constant with the specified name

    xmlaOrdinal

    public int xmlaOrdinal()
    Returns the ordinal code as specified by XMLA.

    For example, the XMLA specification says that the ordinal of CUSTOMER_HOUSEHOLD is 0x1023.

    Returns:
    ordinal code as specified by XMLA.

    forXmlaOrdinal

    public static Level.Type forXmlaOrdinal(int xmlaOrdinal)
    Looks up a Type by its XMLA ordinal.

    Parameters:
    xmlaOrdinal - Ordinal of a level Type according to XMLA specification.
    Returns:
    Type with the given ordinal, or null if there is no such Type

    isTime

    public boolean isTime()
    Returns whether this is a time-related level (TimeYears, TimeQuarters, TimeMonths, TimeWeeks, TimeDays).

    Returns:
    whether this is a time-related level

    SourceForge.net_Logo