All Libraries | This Library | Package | Class | Use | Tree | Deprecated | Index | Grand Index | Help
|  | Components |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.sas.storage.olap.sasmdx
Class TupleElement

    com.sas.storage.olap.sasmdx.TupleElement

All Implemented Interfaces:
  TupleElementInterface

    public class TupleElement

implements TupleElementInterface

Contains the client side implementation for com.sas.storage.olap.TupleElementInterface. This implementation uses the IOM/OLAP interfaces provided by the SAS OLAP server.

Constructor Summary
`TupleElement(TupleInterface tuple, int elementIndex, java.lang.String memberUniqueName, java.lang.String memberLabel, java.lang.String levelUniqueName, java.lang.String levelDepth, java.lang.String displayInfo, java.util.Map properties, com.sas.storage.olap.TupleElementType type)`

Method Summary
`int` | `getChildCount()` Get the number of children for this element
`java.lang.String` | `getFormat()` Get the Format associated with this element if it is a measure element null otherwise
`java.lang.String` | `getLabel()` Get the label for this element
`int` | `getLevelDepth()` Get the depth of the level
`int` | `getMaximumCoordinate()` Get the maximum coordinate of this element
`int` | `getMinimumCoordinate()` Get the minimum coordinate of this element
`java.lang.String` | `getName()` Get the unique name (member unique name) of this element
`java.util.Map` | `getProperties()` Get the element properties
`int` | `getSpan()` Get the span value for this element.
`int` | `getSpanDepth()` Return a value indicating the depth at which the element be position in a given span value.
`TupleInterface` | `getTuple()` Get the tuple this element belongs to
`int` | `getTupleElementIndex()` Get the index of this element in a tuple
`com.sas.storage.olap.TupleElementType` | `getType()` Get the type of this tuple element, supported types are Measures, totals, subtotals, and unspecified.
`java.lang.String` | `getUniqueLevelName()` Get the unque level name of the element's level
`boolean` | `isContextual()` Return if this element is part of the query or it is there to show the context info.
`boolean` | `isContinued()` Return if this element has the same parent as previous element
`boolean` | `isDrilledDown()` Return if the element is in a drilled down state
`void` | `setMaximumCoordinate(int maximumCoordinate)` Set the maximum coordinate for this element
`void` | `setMinimumCoordinate(int minimumCoordinate)` Set the minimum coordinate for this element
`void` | `setSpan(int span)` Set the span value for this element.
`void` | `setSpanDepth(int depth)` Sets the number indicating the depth of the lement in to span for this element.
`java.lang.String` | `toString()` Returns a label of this element

Constructor Detail

### TupleElement

    public TupleElement(TupleInterface tuple,
                        int elementIndex,
                        java.lang.String memberUniqueName,
                        java.lang.String memberLabel,
                        java.lang.String levelUniqueName,
                        java.lang.String levelDepth,
                        java.lang.String displayInfo,
                        java.util.Map properties,
                        com.sas.storage.olap.TupleElementType type)
                 throws OLAPException

Throws:
  `OLAPException`

Method Detail

### getSpan

    public int getSpan()

  Get the span value for this element. If this element is on rows, the span value is the number of columns and if it is on columns, the span is number of rows.

  Specified by:
    `getSpan` in interface `TupleElementInterface`
  Returns:
    number of rows or column spanned by this element

### setSpan

    public void setSpan(int span)

  Set the span value for this element. If this element is on rows, the span value is the number of columns and if it is on columns, the span is number of rows.

  Specified by:
    `setSpan` in interface `TupleElementInterface`
  Parameters:
    `number` - of rows or column spanned by this element

### getTuple

    public TupleInterface getTuple()
                            throws OLAPException

  Get the tuple this element belongs to

  Specified by:
    `getTuple` in interface `TupleElementInterface`
  Returns:
    a tuple that belongs to this element
  Throws:
    `OLAPException` - if a database error occurs

### getLabel

    public java.lang.String getLabel()
                              throws OLAPException

  Get the label for this element

  Specified by:
    `getLabel` in interface `TupleElementInterface`
  Returns:
    label of this element
  Throws:
    `OLAPException` - if a database error occurs

### getName

    public java.lang.String getName()
                             throws OLAPException

  Get the unique name (member unique name) of this element

  Specified by:
    `getName` in interface `TupleElementInterface`
  Returns:
    unique name of this element
  Throws:
    `OLAPException` - if a database error occurs

### getTupleElementIndex

    public int getTupleElementIndex()
                             throws OLAPException

  Get the index of this element in a tuple

  Specified by:
    `getTupleElementIndex` in interface `TupleElementInterface`
  Returns:
    index of the element in a tuple
  Throws:
    `OLAPException`

### isDrilledDown

    public boolean isDrilledDown()
                          throws OLAPException

  Return if the element is in a drilled down state

  Specified by:
    `isDrilledDown` in interface `TupleElementInterface`
  Returns:
    if the element is drilldown
  Throws:
    `OLAPException` - if a database error occurs

### isContinued

    public boolean isContinued()
                        throws OLAPException

  Return if this element has the same parent as previous element

  Specified by:
    `isContinued` in interface `TupleElementInterface`
  Returns:
    true if the element has the same parent, flase otherwise
  Throws:
    `OLAPException` - if a database error occurs

### isContextual

    public boolean isContextual()
                         throws OLAPException

  Return if this element is part of the query or it is there to show the context info. In a query that has 1999 and 2000 with 1999 expanded to 1, 2, 3, 4. the element 1999 is contextual element

  Specified by:
    `isContextual` in interface `TupleElementInterface`
  Returns:
    true if this element is contextual, false otherwise
  Throws:
    `OLAPException`

### getUniqueLevelName

    public java.lang.String getUniqueLevelName()
                                        throws OLAPException

  Get the unque level name of the element's level

  Specified by:
    `getUniqueLevelName` in interface `TupleElementInterface`
  Returns:
    element's unique level name
  Throws:
    `OLAPException` - if a database error occurs

### getLevelDepth

    public int getLevelDepth()
                      throws OLAPException

  Get the depth of the level

  Specified by:
    `getLevelDepth` in interface `TupleElementInterface`
  Parameters:
    `the` - level depth
  Returns:
    The level number associated with this tuple element.
  Throws:
    `OLAPException` - if a database error occurs

### getChildCount

    public int getChildCount()
                      throws OLAPException

  Get the number of children for this element

  Specified by:
    `getChildCount` in interface `TupleElementInterface`
  Returns:
    number of children
  Throws:
    `OLAPException` - if a database error occurs

### getProperties

    public java.util.Map getProperties()
                                throws OLAPException

  Get the element properties

  Specified by:
    `getProperties` in interface `TupleElementInterface`
  Returns:
    map of element properties
  Throws:
    `OLAPException` - if a database error occurs

### getMinimumCoordinate

    public int getMinimumCoordinate()
                             throws OLAPException

  Get the minimum coordinate of this element

  Specified by:
    `getMinimumCoordinate` in interface `TupleElementInterface`
  Returns:
    minimum coordinate of this element
  Throws:
    `OLAPException` - if a database error occurs
  See Also:
    `TupleElementInterface.getMaximumCoordinate()`

### getMaximumCoordinate

    public int getMaximumCoordinate()
                             throws OLAPException

  Get the maximum coordinate of this element

  Specified by:
    `getMaximumCoordinate` in interface `TupleElementInterface`
  Returns:
    maximum coordinate of this element
  Throws:
    `OLAPException` - if a database error occurs
  See Also:
    `TupleElementInterface.getMinimumCoordinate()`

### setMinimumCoordinate

    public void setMinimumCoordinate(int minimumCoordinate)
                              throws OLAPException

  Set the minimum coordinate for this element

  Specified by:
    `setMinimumCoordinate` in interface `TupleElementInterface`
  Parameters:
    `minimum` - Coordinate of this element
  Throws:
    `OLAPException` - if a database error occurs
  See Also:
    `TupleElementInterface.setMaximumCoordinate(int)`

### setMaximumCoordinate

    public void setMaximumCoordinate(int maximumCoordinate)
                              throws OLAPException

  Set the maximum coordinate for this element

  Specified by:
    `setMaximumCoordinate` in interface `TupleElementInterface`
  Parameters:
    `maximum` - Coordinate of this element
  Throws:
    `OLAPException` - if a database error occurs
  See Also:
    `TupleElementInterface.setMinimumCoordinate(int)`

### getFormat

    public java.lang.String getFormat()
                               throws OLAPException

  Get the Format associated with this element if it is a measure element null otherwise

  Specified by:
    `getFormat` in interface `TupleElementInterface`
  Returns:
    the Format associated with this tuple element. This method will return null if this is not a measure element
  Throws:
    `OLAPException`

### getSpanDepth

    public int getSpanDepth()
                     throws OLAPException

  Description copied from interface: `TupleElementInterface`
  Return a value indicating the depth at which the element be position in a given span value. This is a convienience method that helps the viewer in position of this element. This is used in ragged hierarchy case.

  Specified by:
    `getSpanDepth` in interface `TupleElementInterface`
  Returns:
    span depth value for the span, 1 based.
  Throws:
    `OLAPException`

### getType

    public com.sas.storage.olap.TupleElementType getType()
                                                  throws OLAPException

  Description copied from interface: `TupleElementInterface`
  Get the type of this tuple element, supported types are Measures, totals, subtotals, and unspecified.

  Specified by:
    `getType` in interface `TupleElementInterface`
  Returns:
    element type of either `TupleElementType.TOTAL`, `TupleElementType.SUBTOTAL`, `TupleElementType.MEASURE`, `TupleElementType.UNSPECIFIED`
  Throws:
    `OLAPException`

### setSpanDepth

    public void setSpanDepth(int depth)

  Description copied from interface: `TupleElementInterface`
  Sets the number indicating the depth of the lement in to span for this element. This is a convienience method that helps the viewer in position of this element. This is mainly used in case of ragged hierarchy

  Specified by:
    `setSpanDepth` in interface `TupleElementInterface`

### toString

    public java.lang.String toString()

  Returns a label of this element

  Overrides:
    `toString` in class `java.lang.Object`
  Returns:
    label of this element

All Libraries | This Library | Package | Class | Use | Tree | Deprecated | Index | Grand Index | Help
|  | Components |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2009 SAS Institute Inc. All Rights Reserved.