Oracle® OLAP Analytic Workspace Java API Reference
10g Release 2 (10.2)

B14351-01

oracle.AWXML
Class Model

java.lang.Object
  |
  +--oracle.AWXML.BaseObject
        |
        +--oracle.AWXML.Model

public class Model
extends BaseObject

Represents an OLAP model, which is a set of interrelated OLAP DML equations that result in a set of dimension members. For a diagram of the class associations of Model, see Model Class Associations.

Model is owned by a Dimension. A Model can be referenced in an AggregationDefinition to specify aggregation over a dimension (usually a non-hierarchical dimension, such as a line item).

A Model has an ordered set of references to CalculatedMember objects, each one specifying a calculation that results in a new dimension member. Position within the list of references determines the order in which each calculation is performed.

A Model is implemented as a model object in the OLAP DML. If you prefer to write your own OLAP DML for the Model, then you can use the setContents method.

For more information, see the OLAP DML Reference.


Fields inherited from class oracle.AWXML.BaseObject
DATABASENULL

Constructor Summary
Model(BaseObject input)
Creates a Model for the specified Dimension.

Method Summary
void addCalculatedMemberRef(CalculatedMemberRef input)
Adds the specified CalculatedMemberRef to the end of the calculation list in the model.
void addCalculatedMemberRefAfter(CalculatedMemberRef input, BaseObject reference)
Adds the specified CalculatedMemberRef after the referenced CalculatedMemberRef in the calculation list in the model.
void addCalculatedMemberRefBefore(CalculatedMemberRef input, BaseObject reference)
Adds the specified CalculatedMemberRef before the referenced CalculatedMemberRef in the calculation list in the model.
void addCalculatedMemberRefFirst(CalculatedMemberRef input)
Adds the specified CalculatedMemberRef to the beginning of the calculation list in the model.
java.lang.String Create(AWConnection connection)
Creates the Model in the current analytic workspace of the specified database connection.
CalculatedMemberRef createCalculatedMemberRef()
Creates a new CalculatedMemberRef at the end of the calculation list in the model.
CalculatedMemberRef createCalculatedMemberRefAfter(CalculatedMemberRef input)
Creates a new CalculatedMemberRef after the referenced CalculatedMemberRef in the calculation list.
CalculatedMemberRef createCalculatedMemberRefBefore(CalculatedMemberRef input)
Creates a new CalculatedMemberRef before the referenced CalculatedMemberRef in the calculation list.
CalculatedMemberRef createCalculatedMemberRefFirst()
Creates a new CalculatedMemberRef at the beginning of the calculation list in the model.
java.lang.String Delete(AWConnection connection)
Deletes the Model in the current analytic workspace of the specified database connection.
java.lang.String getAggregationText()
Returns the text of the MODEL statement that references the Model in an AggregationDefinition.
java.util.Vector getCalculatedMemberRefs()
Returns the list of CalculatedMemberRef objects in the model.
java.lang.String getContents()
Returns the OLAP DML DIMENSION statements that make up the model specification.
Dimension getDimension()
Returns the Dimension that owns the Model.
void removeCalculatedMemberRef(CalculatedMemberRef input)
Removes the specified CalculatedMemberRef from the model.
void setContents(java.lang.String input)
Assigns the specified OLAP DML commands to the model.
java.lang.String WriteToXML()
Gets an XML representation of the Model.

Methods inherited from class oracle.AWXML.BaseObject
Alter, CreateAfter, CreateBefore, CreateFirst, DataRead, getColumnName, getId, getLongName, getLongName, getName, getOwner, getPluralName, getPluralName, getSchema, getShortName, getShortName, setColumnName, setLongName, setLongName, setName, setPluralName, setPluralName, setSchema, setShortName, setShortName

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

Model

public Model(BaseObject input)
Creates a Model for the specified Dimension.
Parameters:
input - The Dimension that owns the Model.

Method Detail

addCalculatedMemberRef

public void addCalculatedMemberRef(CalculatedMemberRef input)
Adds the specified CalculatedMemberRef to the end of the calculation list in the model.
Parameters:
input - The CalculatedMemberRef to add.

addCalculatedMemberRefAfter

public void addCalculatedMemberRefAfter(CalculatedMemberRef input,
                                        BaseObject reference)
Adds the specified CalculatedMemberRef after the referenced CalculatedMemberRef in the calculation list in the model.
Parameters:
input - The CalculatedMemberRef to add.
reference - The referenced CalculatedMemberRef.

addCalculatedMemberRefBefore

public void addCalculatedMemberRefBefore(CalculatedMemberRef input,
                                         BaseObject reference)
Adds the specified CalculatedMemberRef before the referenced CalculatedMemberRef in the calculation list in the model.
Parameters:
input - The CalculatedMemberRef to add.
reference - The referenced CalculatedMemberRef.

addCalculatedMemberRefFirst

public void addCalculatedMemberRefFirst(CalculatedMemberRef input)
Adds the specified CalculatedMemberRef to the beginning of the calculation list in the model.
Parameters:
input - The CalculatedMemberRef to add.

removeCalculatedMemberRef

public void removeCalculatedMemberRef(CalculatedMemberRef input)
Removes the specified CalculatedMemberRef from the model.
Parameters:
input - The CalculatedMemberRef to remove.

getCalculatedMemberRefs

public java.util.Vector getCalculatedMemberRefs()
Returns the list of CalculatedMemberRef objects in the model.
Returns:
A Vector of CalculatedMemberRef objects.

createCalculatedMemberRef

public CalculatedMemberRef createCalculatedMemberRef()
Creates a new CalculatedMemberRef at the end of the calculation list in the model.
Returns:
The new CalculatedMemberRef.

createCalculatedMemberRefAfter

public CalculatedMemberRef createCalculatedMemberRefAfter(CalculatedMemberRef input)
Creates a new CalculatedMemberRef after the referenced CalculatedMemberRef in the calculation list.
Parameters:
input - The referenced CalculatedMemberRef
Returns:
The new CalculatedMemberRef.

createCalculatedMemberRefBefore

public CalculatedMemberRef createCalculatedMemberRefBefore(CalculatedMemberRef input)
Creates a new CalculatedMemberRef before the referenced CalculatedMemberRef in the calculation list.
Parameters:
input - The referenced CalculatedMemberRef.
Returns:
The new CalculatedMemberRef.

createCalculatedMemberRefFirst

public CalculatedMemberRef createCalculatedMemberRefFirst()
Creates a new CalculatedMemberRef at the beginning of the calculation list in the model.
Returns:
The new CalculatedMemberRef.

WriteToXML

public java.lang.String WriteToXML()
Gets an XML representation of the Model.
Overrides:
WriteToXML in class BaseObject
Returns:
A String that is an XML representation of the Model.

getContents

public java.lang.String getContents()
Returns the OLAP DML DIMENSION statements that make up the model specification.
Returns:
The OLAP DML model specification.

setContents

public void setContents(java.lang.String input)
Assigns the specified OLAP DML commands to the model.
Parameters:
input - A String containing the OLAP DML commands.

getDimension

public Dimension getDimension()
Returns the Dimension that owns the Model.
Returns:
The owning Dimension.

getAggregationText

public java.lang.String getAggregationText()
Returns the text of the MODEL statement that references the Model in an AggregationDefinition.
Returns:
The OLAP DML MODEL statement in the AggregationDefinition.

Create

public java.lang.String Create(AWConnection connection)
Creates the Model in the current analytic workspace of the specified database connection.
Overrides:
Create in class BaseObject
Parameters:
connection - The AWConnection that represents the database connection.
Returns:
"success" if successful.

Delete

public java.lang.String Delete(AWConnection connection)
Deletes the Model in the current analytic workspace of the specified database connection.
Overrides:
Delete in class BaseObject
Parameters:
connection - The AWConnection that represents the database connection.
Returns:
"success" if successful.

Oracle® OLAP Analytic Workspace Java API Reference
10g Release 2 (10.2)

B14351-01

Copyright © 2003, 2005 Oracle. All rights reserved.