com.sas.storage.olap.sasmdx
Class Measure

com.sas.storage.olap.sasmdx.Measure
All Implemented Interfaces:
MeasureInterface, MetadataEntityInterface

public class Measure
implements MeasureInterface

Contains the client side implementation for com.sas.storage.olap.MeasureInterface. This implementation uses the IOM/OLAP interfaces provided by the SAS OLAP server. There actually aren't any remote calls in this particular class. All remote metadata calls are made from within the MetadataInterface implementation.


Field Summary
protected  java.lang.Class dataTypeClass
           
protected  java.lang.String format
           
protected  int precision
           
protected  int scale
           
 
Fields inherited from interface com.sas.storage.olap.MeasureInterface
AGGREGATOR_AVG, AGGREGATOR_CALCULATED, AGGREGATOR_COUNT, AGGREGATOR_MAX, AGGREGATOR_MIN, AGGREGATOR_STD, AGGREGATOR_SUM, AGGREGATOR_UNKNOWN, AGGREGATOR_VAR
 
Constructor Summary
Measure(MetadataInterface metadata, com.sas.iom.SASMDX.ISession _session, java.lang.String catalogName, java.lang.String schemaName, java.lang.String cubeName, java.lang.String name, java.lang.String uniqueName, java.lang.String label, int dataType, int aggregator, java.lang.String unit, java.lang.String description)
           
 
Method Summary
 int getAggregator()
          Returns the aggregator of the measure.
 java.util.Date getCreationDateTime()
          Get the creation date of this object
 CubeInterface getCube()
          Returns the name of the cube to which the measure belongs.
 java.lang.Class getDataType()
          Returns the data type of the measure.
 java.lang.String getDescription()
          Return the description of measure
 Filter getFilter()
          Returns a copy of the Filter object that was used to obtain this MeasureInterface.
 java.lang.String getLabel()
          Get the label/caption for this metadata object
 MetadataInterface getMetadata()
          Returns an instance of the MetadataInterface that is associated with this cube.
 java.lang.String getName()
          Get the Name of this object
 java.lang.String getUniqueName()
          Get the Unique name of this object
 java.lang.String getUnit()
          Returns the format name for this measure.
 java.util.Date getUpdateDateTime()
          Get the last update/modified date time for this object
 

Field Detail

precision

protected int precision

scale

protected int scale

format

protected java.lang.String format

dataTypeClass

protected java.lang.Class dataTypeClass
Constructor Detail

Measure

public Measure(MetadataInterface metadata,
               com.sas.iom.SASMDX.ISession _session,
               java.lang.String catalogName,
               java.lang.String schemaName,
               java.lang.String cubeName,
               java.lang.String name,
               java.lang.String uniqueName,
               java.lang.String label,
               int dataType,
               int aggregator,
               java.lang.String unit,
               java.lang.String description)
        throws OLAPException
Throws:
OLAPException
Method Detail

getName

public java.lang.String getName()
                         throws OLAPException
Description copied from interface: MetadataEntityInterface
Get the Name of this object

Specified by:
getName in interface MetadataEntityInterface
Returns:
Name of the metadata object
Throws:
OLAPException

getLabel

public java.lang.String getLabel()
                          throws OLAPException
Description copied from interface: MetadataEntityInterface
Get the label/caption for this metadata object

Specified by:
getLabel in interface MetadataEntityInterface
Returns:
label
Throws:
OLAPException

getUniqueName

public java.lang.String getUniqueName()
                               throws OLAPException
Description copied from interface: MetadataEntityInterface
Get the Unique name of this object

Specified by:
getUniqueName in interface MetadataEntityInterface
Returns:
unique name of the object
Throws:
OLAPException

getDescription

public java.lang.String getDescription()
                                throws OLAPException
Return the description of measure

Specified by:
getDescription in interface MetadataEntityInterface
Returns:
description of measure
Throws:
OLAPException

getCube

public CubeInterface getCube()
                      throws OLAPException
Description copied from interface: MeasureInterface
Returns the name of the cube to which the measure belongs.

Specified by:
getCube in interface MeasureInterface
Returns:
The name of the cube to which the measure belongs.
Throws:
OLAPException - if a database error occurs

getDataType

public java.lang.Class getDataType()
                            throws OLAPException
Description copied from interface: MeasureInterface
Returns the data type of the measure.

Specified by:
getDataType in interface MeasureInterface
Returns:
The name of the data type of the measure.
Throws:
OLAPException - if a database error occurs

getAggregator

public int getAggregator()
                  throws OLAPException
Description copied from interface: MeasureInterface
Returns the aggregator of the measure. Determines how the measure was derived.

Specified by:
getAggregator in interface MeasureInterface
Returns:
How the measure was derived.
Throws:
OLAPException - if a database error occurs

getUnit

public java.lang.String getUnit()
                         throws OLAPException
Description copied from interface: MeasureInterface
Returns the format name for this measure.

Specified by:
getUnit in interface MeasureInterface
Returns:
The format name for this measure.e.g. DOLLAR
Throws:
OLAPException - if a database error occurs

getFilter

public Filter getFilter()
                 throws OLAPException
Description copied from interface: MeasureInterface
Returns a copy of the Filter object that was used to obtain this MeasureInterface. The filter object may be applied explicitly via the MetadataInterface, or it may be created implicitly via a getMeasures() method.

Specified by:
getFilter in interface MeasureInterface
Returns:
A copy of the Filter object that was used to obtain this MeasureInterface
Throws:
OLAPException - if a database error occurs

getMetadata

public MetadataInterface getMetadata()
                              throws OLAPException
Description copied from interface: MetadataEntityInterface
Returns an instance of the MetadataInterface that is associated with this cube. Null if the cube is not bound to a metadata object.

Specified by:
getMetadata in interface MetadataEntityInterface
Returns:
The metadata object associated with this cube.
Throws:
OLAPException - if a database error occurs

getCreationDateTime

public java.util.Date getCreationDateTime()
                                   throws OLAPException
Description copied from interface: MetadataEntityInterface
Get the creation date of this object

Specified by:
getCreationDateTime in interface MetadataEntityInterface
Returns:
Date time when the object was created
Throws:
OLAPException

getUpdateDateTime

public java.util.Date getUpdateDateTime()
                                 throws OLAPException
Description copied from interface: MetadataEntityInterface
Get the last update/modified date time for this object

Specified by:
getUpdateDateTime in interface MetadataEntityInterface
Returns:
last update/modified date time of this object
Throws:
OLAPException



Copyright © 2009 SAS Institute Inc. All Rights Reserved.