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

B14351-01

oracle.AWXML
Class AW

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

public class AW
extends BaseObject

Represents an analytic workspace. An AW is a container for Analytic Workspace Java API model objects. For a diagram of AW class associations, see AW Class Associations. For a description and a diagram of the Analytic Workspace Java API object model hierarchy, see Object Hierarchy.

Within the object model hierarchy, an AW owns the top-level objects assigned to it. However, the AW does not participate in the lineage that defines the namespace of the owned objects. Top-level objects assigned to an AW exist within the namespace of the relational schema.

The AW class has methods for adding objects to the analytic workspace and creating objects in the analytic workspace. These methods create the logical objects in memory and associate them with the logical AW object. For example, the addDimension method adds a predefined logical dimension to the collection of objects associated with the AW, but has no affect on any analytic workspace that exists in the Oracle Database.

To create or modify an analytic workspace within the Oracle Database, use methods that take an AWConnection argument. To load and calculate data in the workspace, use the BuildDatabase method in the AWAction package.

See Also:
BuildDatabase

Fields inherited from class oracle.AWXML.BaseObject
DATABASENULL

Constructor Summary
AW()
Creates an AW.

Method Summary
void addCube(Cube input)
Adds the specified Cube to the AW.
void addDimension(Dimension input)
Adds the specified Dimension to the AW.
void addLanguage(java.lang.String input)
Adds the specified language to the languages available to the analytic workspace.
void addMeasureFolder(MeasureFolder input)
Adds the specified MeasureFolder to the AW.
void addSolveGroup(SolveGroup input)
Adds the specified SolveGroup to the AW.
java.lang.String Alter(AWConnection connection)
Alters the class attributes of the object in the current analytic workspace of the specified database connection.
void Attach(AWConnection connection, java.lang.String mode)
Attaches the AW in the specified access mode within the specified database connection.
void Commit(AWConnection connection)
Commits the AW within the specified database connection.
java.lang.String Create(AWConnection connection)
Creates the AW in the specified database connection.
Cube createCube()
Creates a Cube and adds it to the AW.
Dimension createDimension()
Creates a Dimension and adds it to the AW.
ExtendedProperty createGlobalAttributeExtension(java.lang.String name, Attribute input, AWConnection conn)
Creates a global attribute extension, which is managed by Oracle OLAP.
void CreateLanguage(AWConnection connection, java.lang.String language)
Adds the specified language to the languages available to the analytic workspace in memory and to the static analytic workspace.
MeasureFolder createMeasureFolder()
Creates a MeasureFolder and adds it to the AW.
SolveGroup createSolveGroup()
Creates a SolveGroup and adds it to the AW.
void DeleteLanguage(AWConnection connection, java.lang.String language)
Deletes the specified language from the languages available to the analytic workspace in memory and from the static analytic workspace.
void Detach(AWConnection connection)
Detaches the AW within the specified database connection.
Cube findCube(java.lang.String inputName)
Gets the specified Cube owned by the AW.
Dimension findDimension(java.lang.String inputName)
Gets the specified Dimension owned by the AW.
java.util.Vector getCubes()
Get the Cube objects associated with the AW.
static AW getCurAW()
Gets the current AW.
java.lang.String getDefaultLanguage()
Gets the default language of the analytic workspace.
java.util.Vector getDimensions()
Gets dimensions associated with the AW.
java.util.Vector getLanguages()
Gets the languages that are available to the analytic workspace.
java.util.Vector getMeasureFolders()
Gets the MeasureFolder objects associated with the AW.
double getMetaDataFormat()
Gets the metadata format of the Oracle Database instance.
java.util.Vector getSolveGroups()
Gets the SolveGroup objects associated with the AW.
java.lang.String getTableSpace()
Gets the name of the tablespace in which the analytic workspace is stored in the relational database.
static AW readAWDefinitions(AWConnection connection, java.lang.String awName)
Attaches the specified analytic workspace for read-only access within the specified database connection; reads the objects owned by the workspace into memory, thereby making them available for processing.
static AW readAWDefinitions(AWConnection connection, java.lang.String awName, java.lang.String attachMode)
Attaches an analytic workspace in the specified mode within a database connection; reads the objects owned by the workspace into memory, thereby making them available for processing.
static AW readAWTopLevelDefinitions(AWConnection connection, java.lang.String awName, java.lang.String attachMode)
Attaches an analytic workspace in the specified access mode within the specified database connection; reads the top-level objects owned by the workspace into memory, thereby making them available for processing.
void removeCube(Cube input)
Removes the specified Cube from the AW.
void removeDimension(Dimension input)
Removes the specified Dimension from the AW.
void removeLanguage(java.lang.String input)
Removes the specified language from the languages available to the analytic workspace.
void removeMeasureFolder(MeasureFolder input)
Removes the specified MeasureFolder from the AW.
void removeSolveGroup(SolveGroup input)
Removes the specified SolveGroup from the AW.
static void setCurAW(AW input)
Specifies an AW as the current AW.
void setDefaultLanguage(AWConnection connection, java.lang.String input)
Specifies a default language for the analytic workspace.
void setDefaultLanguage(java.lang.String input)
Specifies a default language for the analytic workspace.
void setLanguages(java.lang.String input)
Specifies a set of languages for the analytic workspace.
void setTableSpace(java.lang.String input)
Specifies the tablespace in which you want the relational database to store the analytic workspace.
void ValidateDerivedMeasures(AWConnection connection)
Synchronizes the derived measures in memory with those in the stored analytic workspace.
java.lang.String WriteToXML()
Gets an XML representation of the AW.

Methods inherited from class oracle.AWXML.BaseObject
CreateAfter, CreateBefore, CreateFirst, DataRead, Delete, 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

AW

public AW()
Creates an AW.

Method Detail

getCurAW

public static AW getCurAW()
Gets the current AW.
Returns:
The AW that is currently active.

setCurAW

public static void setCurAW(AW input)
Specifies an AW as the current AW.
Parameters:
input - The AW that you want to be the active AW.

setTableSpace

public void setTableSpace(java.lang.String input)
Specifies the tablespace in which you want the relational database to store the analytic workspace.
Parameters:
input - A String containing the name of the tablespace in which to store the analytic workspace.

getTableSpace

public java.lang.String getTableSpace()
Gets the name of the tablespace in which the analytic workspace is stored in the relational database.
Returns:
A String containing the name of the tablespace.

WriteToXML

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

addDimension

public void addDimension(Dimension input)
Adds the specified Dimension to the AW.
Parameters:
input - The Dimension to add.

removeDimension

public void removeDimension(Dimension input)
Removes the specified Dimension from the AW.
Parameters:
input - The Dimension to remove.

getDimensions

public java.util.Vector getDimensions()
Gets dimensions associated with the AW.
Returns:
A Vector that contains the Dimension objects associated with the AW.

addCube

public void addCube(Cube input)
Adds the specified Cube to the AW.
Parameters:
input - The Cube to add.

removeCube

public void removeCube(Cube input)
Removes the specified Cube from the AW.
Parameters:
input - The Cube to remove.

getCubes

public java.util.Vector getCubes()
Get the Cube objects associated with the AW.
Returns:
A Vector that contains Cube objects associated with the AW.

createDimension

public Dimension createDimension()
Creates a Dimension and adds it to the AW.
Returns:
The new Dimension.

createCube

public Cube createCube()
Creates a Cube and adds it to the AW.
Returns:
The new Cube.

Create

public java.lang.String Create(AWConnection connection)
Creates the AW in the specified database connection.
Overrides:
Create in class BaseObject
Parameters:
connection - The AWConnection that specifies the database connection.
Returns:
A String that contains the value success if the method succeeds.

Attach

public void Attach(AWConnection connection,
                   java.lang.String mode)
Attaches the AW in the specified access mode within the specified database connection. The valid values for mode are the following.
Parameters:
connection - The AWConnection that specifies the database connection.
mode - A String that specifies the type of access to the database.

Detach

public void Detach(AWConnection connection)
Detaches the AW within the specified database connection.
Parameters:
connection - The AWConnection that specifies the connection.

Commit

public void Commit(AWConnection connection)
Commits the AW within the specified database connection. Executes an OLAP DML UPDATE and a SQL COMMIT.
Parameters:
connection - An AWConnection that specifies the database connection.

readAWDefinitions

public static AW readAWDefinitions(AWConnection connection,
                                   java.lang.String awName)
Attaches the specified analytic workspace for read-only access within the specified database connection; reads the objects owned by the workspace into memory, thereby making them available for processing.
Parameters:
connection - An AWConnection that specifies the database connection.
awName - A String that contains the name of the analytic workspace.
Returns:
The AW with the specified name.

readAWDefinitions

public static AW readAWDefinitions(AWConnection connection,
                                   java.lang.String awName,
                                   java.lang.String attachMode)
Attaches an analytic workspace in the specified mode within a database connection; reads the objects owned by the workspace into memory, thereby making them available for processing. For the valid values for attachMode, see the Attach method.
Parameters:
connection - An AWConnection that specifies the database connection.
awName - A String that contains the name of the analytic workspace.
attachMode - A String that specifies the access mode.
Returns:
The AW with the specified name.

findDimension

public Dimension findDimension(java.lang.String inputName)
Gets the specified Dimension owned by the AW.
Parameters:
inputName - The name of the Dimension to get.
Returns:
The specified Dimension.

findCube

public Cube findCube(java.lang.String inputName)
Gets the specified Cube owned by the AW.
Parameters:
inputName - The name of the Cube to get.
Returns:
The specified Cube.

addSolveGroup

public void addSolveGroup(SolveGroup input)
Adds the specified SolveGroup to the AW.
Parameters:
input - The SolveGroup to add.

removeSolveGroup

public void removeSolveGroup(SolveGroup input)
Removes the specified SolveGroup from the AW.
Parameters:
input - The SolveGroup to remove.

getSolveGroups

public java.util.Vector getSolveGroups()
Gets the SolveGroup objects associated with the AW.
Returns:
A Vector that contains the SolveGroup objects of the AW.

createSolveGroup

public SolveGroup createSolveGroup()
Creates a SolveGroup and adds it to the AW.
Returns:
The new SolveGroup.

addMeasureFolder

public void addMeasureFolder(MeasureFolder input)
Adds the specified MeasureFolder to the AW.
Parameters:
input - The MeasureFolder to add.

removeMeasureFolder

public void removeMeasureFolder(MeasureFolder input)
Removes the specified MeasureFolder from the AW.
Parameters:
input - The MeasureFolder to remove.

getMeasureFolders

public java.util.Vector getMeasureFolders()
Gets the MeasureFolder objects associated with the AW.
Returns:
A Vector that contains the MeasureFolder objects of the AW.

createMeasureFolder

public MeasureFolder createMeasureFolder()
Creates a MeasureFolder and adds it to the AW.
Returns:
The new MeasureFolder.

readAWTopLevelDefinitions

public static AW readAWTopLevelDefinitions(AWConnection connection,
                                           java.lang.String awName,
                                           java.lang.String attachMode)
Attaches an analytic workspace in the specified access mode within the specified database connection; reads the top-level objects owned by the workspace into memory, thereby making them available for processing. The top-level objects are Cube, Dimension, and SolveGroup.

For the valid values for attachMode, see the Attach method.

Parameters:
connection - An AWConnection that specifies the database connection.
awName - A String that contains the name of the analytic workspace.
attachMode - A String that specifies the access mode.
Returns:
The AW with the specified name.

createGlobalAttributeExtension

public ExtendedProperty createGlobalAttributeExtension(java.lang.String name,
                                                       Attribute input,
                                                       AWConnection conn)
Creates a global attribute extension, which is managed by Oracle OLAP. A global attribute extension applies to all Hierarchy, HierarchyLevelAssociation, and Level objects owned by the AW.
Parameters:
name - A String that contains a name for the attribute extension.
input - The Attribute.
conn - An AWConnection that specifies the database connection.

ValidateDerivedMeasures

public void ValidateDerivedMeasures(AWConnection connection)
Synchronizes the derived measures in memory with those in the stored analytic workspace.
Parameters:
connection - The AWConnection that specifies the database connection.

setLanguages

public void setLanguages(java.lang.String input)
Specifies a set of languages for the analytic workspace. In the input object, separate the languages with double colons, as in the following example.
 aw.setLanguages("French::Spanish::German");
Parameters:
input - The languages to specify for the analytic workspace.

getLanguages

public java.util.Vector getLanguages()
Gets the languages that are available to the analytic workspace.
Returns:
A Vector containing the languages that are available to the analytic workspace.

addLanguage

public void addLanguage(java.lang.String input)
Adds the specified language to the languages available to the analytic workspace. For example, the following code adds French to an AW.
 aw.addLanguage("French");
Parameters:
input - The language to add to the analytic workspace.

removeLanguage

public void removeLanguage(java.lang.String input)
Removes the specified language from the languages available to the analytic workspace.
Parameters:
input - The language to remove from the analytic workspace.

CreateLanguage

public void CreateLanguage(AWConnection connection,
                           java.lang.String language)
Adds the specified language to the languages available to the analytic workspace in memory and to the static analytic workspace. For example, the following code adds French to the AW object and to the analytic workspace stored in the database.
 aw.CreateLanguage("French");
Parameters:
connection - The AWConnection that specifies the database connection.
input - The language to add to the analytic workspace.

DeleteLanguage

public void DeleteLanguage(AWConnection connection,
                           java.lang.String language)
Deletes the specified language from the languages available to the analytic workspace in memory and from the static analytic workspace.
Parameters:
connection - The AWConnection that specifies the database connection.
input - The language to delete from the analytic workspace.

getDefaultLanguage

public java.lang.String getDefaultLanguage()
Gets the default language of the analytic workspace.
Returns:
A String containing the name of the default language.

setDefaultLanguage

public void setDefaultLanguage(java.lang.String input)
Specifies a default language for the analytic workspace.
Parameters:
input - A String containing the name of the language that you want as the default language.

setDefaultLanguage

public void setDefaultLanguage(AWConnection connection,
                               java.lang.String input)
Specifies a default language for the analytic workspace.
Parameters:
connection - The AWConnection that represents the database connection.
input - A String containing the name of the language that you want as the default language.

getMetaDataFormat

public double getMetaDataFormat()
Gets the metadata format of the Oracle Database instance. The format values are 10.1 and 10.2.
Returns:
A double that indicates the metadata format of the database instance.

Alter

public java.lang.String Alter(AWConnection connection)
Description copied from class: BaseObject
Alters the class attributes of the object in the current analytic workspace of the specified database connection. You can use the Alter method to change descriptive names of the object or to reset the schema of a top-level object. To alter the structural definition of a BaseObject, you must create, modify, or remove its owned objects.
Overrides:
Alter in class BaseObject
Tags copied from class: BaseObject
Parameters:
connection - The AWConnection that represents the database connection.
Returns:
If successful, a String that contains success.

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

B14351-01

Copyright © 2003, 2005 Oracle. All rights reserved.