public interface

StyleMap

implements ConfigurationElement
com.microstrategy.web.transform.StyleMap
Known Indirect Subclasses

Class Overview

The StyleMap interface represents a collection of "style mapping clauses" that are evaluated for a particular style in this Style Catalog. "style mapping clauses" include zero or multiple mapping conditions and 0 or 1 default condition. default condition will be always eveluated as the last clause, and it will be met.

Summary

Public Methods
abstract void clear()
Clears the collection of style map clause objects.
abstract int getCount()
Returns the number of StyleMapClause objects in this collection.
abstract StyleMapClause getStyleMapClause(int index)
Gets the StyleMapClause, both mapping conditions and default conditions, associated with supplied index.
abstract String getStyleName()
Returns the style name that this map exists for.
abstract String mapStyle(String origStyleName, StyleRequestContext context)
Maps the original style name to a new one, based on the "style map clauses" contained in this map along with any contextual data.
abstract StyleMapCondition newStyleMapCondition(String toStyle)
Creates a new style map condition object that, if the conditions were satifisfied, would map the style to the specified name.
abstract void remove(int index)
Removes the StyleMapClause object at the specified index.
abstract StyleMapDefault setStyleMapDefault(String toStyle)
Sets a new style map default object that maps the style to the specified name.
abstract void setStyleName(String styleName)
Sets the style name that this map exists for.
[Expand]
Inherited Methods
From interface com.microstrategy.utils.config.ConfigurationElement

Public Methods

public abstract void clear ()

Clears the collection of style map clause objects.

Throws
UnsupportedOperationException This exception is thrown if the Style Catalog is in "read only" mode.

public abstract int getCount ()

Returns the number of StyleMapClause objects in this collection.

Returns
  • The count of style map clause objects.

public abstract StyleMapClause getStyleMapClause (int index)

Gets the StyleMapClause, both mapping conditions and default conditions, associated with supplied index. A valid index begins at 0 and continues to getCount() - 1.

Parameters
index The index of the StyleMapClause to return.
Returns
Throws
IndexOutOfBoundsException This exception is thown if the argument is outside the range of a valid index.

public abstract String getStyleName ()

Returns the style name that this map exists for.

Returns
  • The style name that this map exists for.

public abstract String mapStyle (String origStyleName, StyleRequestContext context)

Maps the original style name to a new one, based on the "style map clauses" contained in this map along with any contextual data.

Parameters
origStyleName The original style name.
context The StyleRequestContext object that contain context data.
Returns
  • The name of the new style name to use.

public abstract StyleMapCondition newStyleMapCondition (String toStyle)

Creates a new style map condition object that, if the conditions were satifisfied, would map the style to the specified name.

Parameters
toStyle The name of the style to use if the conditions were met.
Returns
Throws
UnsupportedOperationException This exception is thrown if the Style Catalog is in "read only" mode.

public abstract void remove (int index)

Removes the StyleMapClause object at the specified index.

Parameters
index The index of the style map clause object to remove.
Throws
IndexOutOfBoundsException This exception is thown if the argument is outside the range of a valid index.
UnsupportedOperationException This exception is thrown if the Style Catalog is in "read only" mode.

public abstract StyleMapDefault setStyleMapDefault (String toStyle)

Sets a new style map default object that maps the style to the specified name.

Parameters
toStyle The name of the style to use.
Returns
Throws
UnsupportedOperationException This exception is thrown if the Style Catalog is in "read only" mode.

public abstract void setStyleName (String styleName)

Sets the style name that this map exists for.

Parameters
styleName The name of the style that this map exists for.