public class

StyleMapsImpl

extends AbstractStyleCatalogList
implements StyleMaps
java.lang.Object
   ↳ com.microstrategy.utils.config.AbstractConfigurationElement
     ↳ com.microstrategy.utils.config.AbstractElementList
       ↳ com.microstrategy.web.transform.AbstractStyleCatalogList
         ↳ com.microstrategy.web.transform.StyleMapsImpl

Class Overview

This class implements the StyleMaps interface for the Style Catalog.

Summary

Constants
String ELEM_NAME_STYLEMAPS The name of the style maps element.
[Expand]
Inherited Constants
From class com.microstrategy.utils.config.AbstractConfigurationElement
Public Constructors
StyleMapsImpl()
Public Methods
StyleMap getStyleMap(String name)
Gets the StyleMap associated with a given style name.
StyleMap getStyleMap(int index)
Gets the StyleMap associated with supplied index.
String mapStyle(String origStyleName, StyleRequestContext context)
Map an incoming style ('origStyleName') to a new style, based on the definition of the maps and any contextual data.
StyleMap newStyleMap(String styleName)
Creates a new style map object for the supplied style name.
Protected Methods
Class getListClass()
Returns the Class items beloging to this list will be instance of.
String getListNodeName()
Returns the name of the node representing children of this list.
[Expand]
Inherited Methods
From class com.microstrategy.web.transform.AbstractStyleCatalogList
From class com.microstrategy.utils.config.AbstractElementList
From class com.microstrategy.utils.config.AbstractConfigurationElement
From class java.lang.Object
From interface com.microstrategy.utils.config.ConfigurationElement
From interface com.microstrategy.utils.config.ConfigurationFile
From interface com.microstrategy.web.transform.StyleMaps

Constants

public static final String ELEM_NAME_STYLEMAPS

The name of the style maps element.

Constant Value: "StyleMaps"

Public Constructors

public StyleMapsImpl ()

Public Methods

public StyleMap getStyleMap (String name)

Gets the StyleMap associated with a given style name.

Parameters
name The name of the style map object to return.
Returns
  • The StyleMap object for the associated style.
Throws
IllegalArgumentException This exception is thrown if the argument does not match one of the stored names.

public StyleMap getStyleMap (int index)

Gets the StyleMap associated with supplied index. A valid index begins at 0 and continues to getCount() - 1.

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

public String mapStyle (String origStyleName, StyleRequestContext context)

Map an incoming style ('origStyleName') to a new style, based on the definition of the maps and any contextual data.

Parameters
origStyleName The original name of the style being requested.
context The StyleRequestContext that can be used to determine whether a mapping should be performed.
Returns
  • The name of the mapped style.

public StyleMap newStyleMap (String styleName)

Creates a new style map object for the supplied style name.

Parameters
styleName The name of the style to create a map for.
Returns
  • The new style map object.
Throws
IllegalArgumentException This exception is thrown if the argument already matches one of the stored names.
UnsupportedOperationException This exception is thrown if the Style Catalog is in "read only" mode.

Protected Methods

protected Class getListClass ()

Returns the Class items beloging to this list will be instance of.

protected String getListNodeName ()

Returns the name of the node representing children of this list.