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>, XmlaConstant
Enclosing interface:
Level

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

Enumeration of the types of a Level.

Several of the values are defined by OLE DB for OLAP and/or XML/A, 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 OLE DB for OLAP:

Some of the OLE DB for OLAP values are as flags, and do not become values of the enumeration:

Some of the values are specified by XMLA:

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

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.olap4j.metadata.XmlaConstant
XmlaConstant.Dictionary<E extends Enum<E> & XmlaConstant>
 
Enum Constant Summary
ACCOUNT
           
ALL
          Indicates that the level contains the 'all' member of its hierarchy.
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
           
TIME_DAYS
          Indicates that a level refers to days.
TIME_HALF_YEAR
          Indicates that a level refers to half years.
TIME_HOURS
          Indicates that a level refers to hours.
TIME_MINUTES
          Indicates that a level refers to minutes.
TIME_MONTHS
          Indicates that a level refers to months.
TIME_QUARTERS
          Indicates that a level refers to quarters.
TIME_SECONDS
          Indicates that a level refers to seconds.
TIME_UNDEFINED
          Indicates that a level refers to days.
TIME_WEEKS
          Indicates that a level refers to weeks.
TIME_YEARS
          Indicates that a level refers to years.
UTILITY
           
 
Method Summary
 String getDescription()
          Returns the description of this constant.
static XmlaConstant.Dictionary<Level.Type> getDictionary()
          Per XmlaConstant, returns a dictionary of all values of this enumeration.
 boolean isTime()
          Returns whether this is a time-related level (TIME_YEARS, TIME_HALF_YEAR, TIME_QUARTERS, TIME_MONTHS, TIME_WEEKS, TIME_DAYS, TIME_HOURS, TIME_MINUTES, TIME_SECONDS, TIME_UNDEFINED).
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.
 String xmlaName()
          Returns the name of this constant as specified by XMLA.
 int xmlaOrdinal()
          Returns the code of this constant 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.


ALL

public static final Level.Type ALL
Indicates that the level contains the 'all' member of its hierarchy.


NULL

public static final Level.Type NULL
Indicates that a level holds the null member. Does not correspond to an XMLA or OLE DB value.


TIME_YEARS

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


TIME_HALF_YEAR

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


TIME_QUARTERS

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


TIME_MONTHS

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


TIME_WEEKS

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


TIME_DAYS

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


TIME_HOURS

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


TIME_MINUTES

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


TIME_SECONDS

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


TIME_UNDEFINED

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


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.)

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

getDictionary

public static XmlaConstant.Dictionary<Level.Type> getDictionary()
Per XmlaConstant, returns a dictionary of all values of this enumeration.

Returns:
Dictionary of all values

xmlaName

public String xmlaName()
Description copied from interface: XmlaConstant
Returns the name of this constant as specified by XMLA.

Often the name is an enumeration-specific prefix plus the name of the Java enum constant. For example, Dimension.Type has prefix "MD_DIMTYPE_", and therefore this method returns "MD_DIMTYPE_PRODUCTS" for the enum constant Dimension.Type.PRODUCTS.

Specified by:
xmlaName in interface XmlaConstant
Returns:
ordinal code as specified by XMLA.

getDescription

public String getDescription()
Description copied from interface: XmlaConstant
Returns the description of this constant.

Specified by:
getDescription in interface XmlaConstant
Returns:
Description of this constant.

xmlaOrdinal

public int xmlaOrdinal()
Description copied from interface: XmlaConstant
Returns the code of this constant as specified by XMLA.

For example, the XMLA specification says that the ordinal of MD_DIMTYPE_PRODUCTS is 8, and therefore this method returns 8 for Dimension.Type.PRODUCTS.

Specified by:
xmlaOrdinal in interface XmlaConstant
Returns:
ordinal code as specified by XMLA.

isTime

public boolean isTime()
Returns whether this is a time-related level (TIME_YEARS, TIME_HALF_YEAR, TIME_QUARTERS, TIME_MONTHS, TIME_WEEKS, TIME_DAYS, TIME_HOURS, TIME_MINUTES, TIME_SECONDS, TIME_UNDEFINED).

Returns:
whether this is a time-related level

SourceForge.net_Logo