public interface

StyleCatalog

implements ConfigurationElement ConfigurationFile
com.microstrategy.web.transform.StyleCatalog
Known Indirect Subclasses

Class Overview

The StyleCatalog interface presents the methods that a caller needs to manage the state of a style catalog.

Summary

Public Methods
abstract void deleteTransformDefnFromStyles(TransformDefn trDef, boolean removeStyles)
Cleans all the possible associatios made to the TransformDefn object specified.
abstract BeanDefn getBeanDefn(TransformDefn tDefn)
Returns the BeanDefn for a bean supported by this transform.
abstract BeanDefns getBeanDefns()
Returns the BeanDefns collection.
abstract String getDescription()
Returns the textual description of the style catalog.
abstract String getFileName()
Returns the file name used by the style catalog.
abstract LayoutParserDefns getLayoutParserDefns()
Gets the collection of layout parser definition objects.
abstract LayoutSourceDefns getLayoutSourceDefns()
Gets the collection of layout source definition objects.
abstract MapperDefns getMapperDefns()
Returns the collection fo mapper definitions.
abstract String getName()
Returns the name of the style catalog.
abstract SourceLookup getSourceLookup(String source)
Returns the registered SourceLookup object with the specified name.
abstract StyleMaps getStyleMaps()
Returns the collection of style maps.
abstract Styles getStyles()
Returns the Styles collection.
abstract Transform getTransformByStyle(String styleName, StyleRequestContext context)
Returns the transform object associated with the specified style.
abstract Transform getTransformByStyle(String styleName)
Returns the transform object associated with the specified style.
abstract TransformDefns getTransformDefns()
Returns the TransformDefns collection.
abstract String getVersion()
Returns the current version of the styleCatalog
abstract boolean hasChanged()
Returns whether the style catalog has changed.
abstract Styles listStyles(TransformDefn trDef, int sortBy)
Lists all styles for a specified transform.
abstract Styles listStylesForBean(String beanName, int sortBy)
Lists styles filtered by the bean type and/or sorted by bean type.
abstract TransformDefns listTransformDefns(String beanName, int sortBy)
Lists transform definitions filtered by the bean type and/or sorted by bean type.
abstract void reset()

Reloads the previous style catalog file - undoing any in-memory changes reverting back to the file definition.

abstract void save()
Saves the contents of the style catalog to disk.
abstract StyleCatalog saveAs(String fileName, boolean overwrite)
Saves the contents of the style catalog in a new instance and to disk.
abstract void setDescription(String description)
Sets the textual description of the style catalog.
abstract void setFileName(String fileName)
Sets the name of the file used by the style catalog.
abstract void setName(String name)
Sets the name of the style catalog.
abstract void setSourceLookup(String source, SourceLookup sourceLookup)
Registers a SourceLookup object with the specified key.
[Expand]
Inherited Methods
From interface com.microstrategy.utils.config.ConfigurationElement
From interface com.microstrategy.utils.config.ConfigurationFile

Public Methods

public abstract void deleteTransformDefnFromStyles (TransformDefn trDef, boolean removeStyles)

Cleans all the possible associatios made to the TransformDefn object specified. It will have the option to remove all the Style objects associated with this TransformDefn object.

Parameters
trDef the TransformDefn object you want to remove.
removeStyles inicates whether you want to remove the styles associated with this TransformDefn object or not.
Throws
IllegalArgumentException thrown if the TransformDefn object is null.

public abstract BeanDefn getBeanDefn (TransformDefn tDefn)

Returns the BeanDefn for a bean supported by this transform.

Returns
  • the BeanDefn for a bean supported by this transform.

public abstract BeanDefns getBeanDefns ()

Returns the BeanDefns collection.

Returns

public abstract String getDescription ()

Returns the textual description of the style catalog.

Returns
  • the description of the style catalog.

public abstract String getFileName ()

Returns the file name used by the style catalog.

Returns
  • the file name used by the style catalog.

public abstract LayoutParserDefns getLayoutParserDefns ()

Gets the collection of layout parser definition objects.

Returns
  • The collection of layout parser definition objects.

public abstract LayoutSourceDefns getLayoutSourceDefns ()

Gets the collection of layout source definition objects.

Returns
  • The collection of layout source definition objects.

public abstract MapperDefns getMapperDefns ()

Returns the collection fo mapper definitions.

Returns

public abstract String getName ()

Returns the name of the style catalog.

Returns
  • the name of the style catalog.

public abstract SourceLookup getSourceLookup (String source)

Returns the registered SourceLookup object with the specified name.

Parameters
source the name used to look up the SourceLookup object.
Returns
  • the SourceLookup object with the specified name.

public abstract StyleMaps getStyleMaps ()

Returns the collection of style maps.

Returns

public abstract Styles getStyles ()

Returns the Styles collection.

Returns

public abstract Transform getTransformByStyle (String styleName, StyleRequestContext context)

Returns the transform object associated with the specified style.

Parameters
styleName the name of the style.
context the StyleRequestContext object used to resolve dynamic actual parameter values.
Returns
Throws
WebTransformException thrown if there is an error getting a new instance of the transform
IllegalArgumentException thrown if the style name was not found in this style catalog.

public abstract Transform getTransformByStyle (String styleName)

Returns the transform object associated with the specified style.

Parameters
styleName the name of the style.
Returns
Throws
WebTransformException thrown if there is an error getting a new instance of the transform
IllegalArgumentException thrown if the style name was not found in this style catalog.

public abstract TransformDefns getTransformDefns ()

Returns the TransformDefns collection.

Returns

public abstract String getVersion ()

Returns the current version of the styleCatalog

Returns
  • the version of the styleCatalog

public abstract boolean hasChanged ()

Returns whether the style catalog has changed.

Returns
  • whether the style catalog changed.

public abstract Styles listStyles (TransformDefn trDef, int sortBy)

Lists all styles for a specified transform. Styles will be sorted according to the sortBy value.

Parameters
trDef the TransformDefn object used to filter the list of styles.
sortBy Defines sorting order. From EnumSortBy
Returns
  • a subset of Style objects belonging to the specified TransformDefinition and sorted according to the sortBy parameter Returned subset is read-only, calling any update method on it will result in UnsupportedOperationException.
Throws
IllegalArgumentException thrown if the sortBy parameter is invalid or the TransformDefn object is null.

public abstract Styles listStylesForBean (String beanName, int sortBy)

Lists styles filtered by the bean type and/or sorted by bean type.

Parameters
beanName the filer bean type. Must be a valid bean type or FILTER_NONE, in which case no filtering will be performed.
sortBy Defines sorting order. From EnumSortBy
Returns
  • a subset of Style objects filtered according to the beanName parameter and sorted according to the sortBy parameter. Returned subset is read-only, calling any update method on it will result in UnsupportedOperationException.
Throws
IllegalArgumentException thrown if the sortBy parameter is invalid.

public abstract TransformDefns listTransformDefns (String beanName, int sortBy)

Lists transform definitions filtered by the bean type and/or sorted by bean type.

Parameters
beanName the filer bean type. Must be a valid bean type or FILTER_NONE, in which case no filtering will be performed.
sortBy Defines sorting order. From EnumSortBy
Returns
  • a subset of TransformDefinition objects filtered according to the beanName parameter and sorted according to the sortBy parameter. Returned subset is read-only, calling any update method on it will result in UnsupportedOperationException.
Throws
IllegalArgumentException thrown if the sortBy parameter is invalid.

public abstract void reset ()

Reloads the previous style catalog file - undoing any in-memory changes reverting back to the file definition. Nothing happens if a style catalog was not previously loaded.

public abstract void save ()

Saves the contents of the style catalog to disk.

Throws
WebTransformException thrown if an error saving to the file occurs.

public abstract StyleCatalog saveAs (String fileName, boolean overwrite)

Saves the contents of the style catalog in a new instance and to disk.

Parameters
fileName the name of the file for the new StyleCatalog object.
overwrite whether it overwrites the file if already exists.
Returns
  • a new instance of the StyleCatalog object with the copied contents.
Throws
WebTransformException thrown if an error saving to the file occurs.
IllegalArgumentException thrown if the file name exists and it can't overwrite it.

public abstract void setDescription (String description)

Sets the textual description of the style catalog.

Parameters
description the description of the style catalog.

public abstract void setFileName (String fileName)

Sets the name of the file used by the style catalog.

Parameters
fileName the file name used by the style catalog.

public abstract void setName (String name)

Sets the name of the style catalog.

Parameters
name the name of the style catalog.

public abstract void setSourceLookup (String source, SourceLookup sourceLookup)

Registers a SourceLookup object with the specified key.

Parameters
source the key mapped to the SourceLookup object
sourceLookup the SourceLookup object to register