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

B14348-01

oracle.olapi.metadata.mdm
Class MdmModel

java.lang.Object
  |
  +--oracle.olapi.metadata.BaseMetadataObject
        |
        +--oracle.olapi.metadata.mdm.MdmObject
              |
              +--oracle.olapi.metadata.mdm.MdmModel
Direct Known Subclasses:
MdmDimensionCalculationModel, MdmDimensionedObjectModel

public abstract class MdmModel
extends MdmObject
implements Model

A Model that assigns a value to an MdmAttribute or an MdmMeasure for a set of MdmDimension members. The values and the MdmDimension members are specified by the Assignment objects of the MdmModel.

As needed, Oracle OLAP implicitly creates an MdmModel for an MdmDimension, MdmAttribute, or MdmMeasure provided by the MdmMetadataProvider.

See Also:
Model

Constructor Summary
MdmModel(MdmMetadataProvider metadataProvider)
Creates an MdmModel for MDM metadata objects provided by the specified MdmMetadataProvider.

Method Summary
void assign(Qualification[] qualifications, Source assigned)
Creates an Assignment with the default precedence and adds it to the MdmModel.
void assign(Qualification[] qualifications, Source assigned, int precedence)
Creates an Assignment and adds it to the MdmModel.
void assign(java.lang.String[] values, Source assigned)
Creates an Assignment with the default precedence and adds it to the MdmModel.
void assign(java.lang.String[] values, Source assigned, int precedence)
Creates an Assignment with the specified precedence and adds it to the MdmModel.
void assign(java.lang.String value, Source assigned)
Creates an Assignment with the default precedence and adds it to the MdmModel.
void assign(java.lang.String value, Source assigned, int precedence)
Creates an Assignment with the specified precedence and adds it to the MdmModel.
Source createSolvedSource()
Creates a Source that represents the results of the evaluation of the Assignment objects of the MdmModel.
Source createSolvedSource(Source defaultValues)
Creates a Source that represents the results of the evaluation of the Assignment objects of the MdmModel.
java.util.List getAssignments()
Gets the Assignment objects of the MdmModel.
int getDefaultPrecedence()
Gets the default precedence value for the MdmModel.
abstract java.util.List getInputs()
Gets the Source objects that are the inputs of the MdmModel.
abstract MdmSource getMdmSource()
Gets the MdmSource for the MdmModel.
java.util.List getOutputs()
Returns an empty List because an MdmModel does not have outputs.
abstract java.util.List getParentModels()
Gets the MdmModel objects that are the parents of the MdmModel; the MdmModel can inherit the Assignment objects of its parents.
abstract Source getType()
Gets the Source that is the type of the MdmModel.
void setDefaultPrecedence(int precedence)
Specifies the default precedence, which is the precedence value for Assignment objects that are created by methods that do not specify a value.
void unassign(Assignment assignment)
Removes an Assignment from the MdmModel.

Methods inherited from class oracle.olapi.metadata.mdm.MdmObject
acceptVisitor, getDescription, getMetadataProvider, getName, getShortDescription, setDescription, setName, setShortDescription

Methods inherited from class oracle.olapi.metadata.BaseMetadataObject
getID

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

Constructor Detail

MdmModel

public MdmModel(MdmMetadataProvider metadataProvider)
Creates an MdmModel for MDM metadata objects provided by the specified MdmMetadataProvider.
Parameters:
metadataProvider - The MdmMetadataProvider to use in creating the MdmModel.

Method Detail

getMdmSource

public abstract MdmSource getMdmSource()
Gets the MdmSource for the MdmModel.
Returns:
The MdmSource for the MdmModel.

getType

public abstract Source getType()
Gets the Source that is the type of the MdmModel.
Specified by:
getType in interface Model
Returns:
The Source that is the type of the MdmModel.

getInputs

public abstract java.util.List getInputs()
Gets the Source objects that are the inputs of the MdmModel.
Specified by:
getInputs in interface Model
Returns:
A List of the Source objects that are the inputs of the MdmModel.

getOutputs

public final java.util.List getOutputs()
Returns an empty List because an MdmModel does not have outputs. A CustomModel can have outputs.
Specified by:
getOutputs in interface Model
Returns:
An empty List.

getParentModels

public abstract java.util.List getParentModels()
Gets the MdmModel objects that are the parents of the MdmModel; the MdmModel can inherit the Assignment objects of its parents.
Specified by:
getParentModels in interface Model
Returns:
A List of the MdmModel objects that are the parents of the MdmModel.

getAssignments

public java.util.List getAssignments()
Gets the Assignment objects of the MdmModel.
Specified by:
getAssignments in interface Model
Returns:
A List of the Assignment objects of the MdmModel.

assign

public void assign(Qualification[] qualifications,
                   Source assigned)
Creates an Assignment with the default precedence and adds it to the MdmModel.
Specified by:
assign in interface Model
Parameters:
qualifications - An array of Qualification objects, each of which specifies a dimension member.
assigned - A Source that defines a value to assign as the value of a measure or attribute for the specified dimension members.

assign

public void assign(Qualification[] qualifications,
                   Source assigned,
                   int precedence)
Creates an Assignment and adds it to the MdmModel.
Specified by:
assign in interface Model
Parameters:
qualifications - An array of Qualification objects, each of which specifies a dimension member.
assigned - A Source that defines a value to assign as the value of a measure or attribute for the specified dimension members.
precedence - An integer that specifies the precedence to use for the Assignment.

assign

public void assign(java.lang.String value,
                   Source assigned)
Creates an Assignment with the default precedence and adds it to the MdmModel.
Specified by:
assign in interface Model
Parameters:
value - A String that specifies a dimension member.
assigned - A Source that defines a value to assign as the value of a measure or attribute for the specified dimension member.

assign

public void assign(java.lang.String value,
                   Source assigned,
                   int precedence)
Creates an Assignment with the specified precedence and adds it to the MdmModel.
Specified by:
assign in interface Model
Parameters:
value - A String that specifies a dimension member.
assigned - A Source that defines a value to assign as the value of a measure or attribute for the specified dimension member.
precedence - An integer that specifies the precedence to use for the Assignment.

assign

public void assign(java.lang.String[] values,
                   Source assigned)
Creates an Assignment with the default precedence and adds it to the MdmModel.
Specified by:
assign in interface Model
Parameters:
value - An array of String objects that specify dimension members.
assigned - A Source that defines a value to assign as the value of a measure or attribute for the specified dimension members.

assign

public void assign(java.lang.String[] values,
                   Source assigned,
                   int precedence)
Creates an Assignment with the specified precedence and adds it to the MdmModel.
Specified by:
assign in interface Model
Parameters:
value - An array of String objects that specify dimension members.
assigned - A Source that defines a value to assign as the value of a measure or attribute for the specified dimension members.
precedence - An integer that specifies the precedence to use for the Assignment.

unassign

public void unassign(Assignment assignment)
Removes an Assignment from the MdmModel.
Specified by:
unassign in interface Model
Parameters:
assignment - The Assignment to remove.

getDefaultPrecedence

public int getDefaultPrecedence()
Gets the default precedence value for the MdmModel.
Specified by:
getDefaultPrecedence in interface Model
Returns:
An integer that represents the precedence for Assignment objects that are created by methods that do not specify a precedence value.

setDefaultPrecedence

public void setDefaultPrecedence(int precedence)
Specifies the default precedence, which is the precedence value for Assignment objects that are created by methods that do not specify a value.
Specified by:
setDefaultPrecedence in interface Model
Parameters:
precedence - The integer value to set as the default precedence.

createSolvedSource

public final Source createSolvedSource()
Creates a Source that represents the results of the evaluation of the Assignment objects of the MdmModel. The elements of the returned Source that do not have an assigned value have a value of null.
Specified by:
createSolvedSource in interface Model
Returns:
A Source that represents the results of the evaluation of the Assignment objects of the Model and that has null for unassigned values.

createSolvedSource

public final Source createSolvedSource(Source defaultValues)
Creates a Source that represents the results of the evaluation of the Assignment objects of the MdmModel. The elements of the returned Source that do not have an assigned value have the value specified by the defaultValues Source.
Specified by:
createSolvedSource in interface Model
Parameters:
defaultValues - A Source that specifies the value that you want Oracle OLAP to assign for a member of an input when the Assignment objects of the MdmmModel do not assign a value for the input member.
Returns:
A Source that represents the results of the evaluation of the Assignment objects of the MdmModel and that has the value of defaultValues for unassigned values.

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

B14348-01

Copyright © 2002, 2005, Oracle. All rights reserved.