public abstract class

AbstractLayoutSource

extends Object
implements LayoutSource
java.lang.Object
   ↳ com.microstrategy.web.transform.AbstractLayoutSource
Known Direct Subclasses
Known Indirect Subclasses

Class Overview

This abstract base class manages caching of Layout definitions and provides a simple implementation of LayoutParser.MessageListener

Summary

Nested Classes
class AbstractLayoutSource.LayoutCacheHint This class serves as both CacheHint and Cache key. 
Public Constructors
AbstractLayoutSource()
Protected Methods
void checkNullObject(Object o, String msg)
A utility method to check whether an object is null.
LayoutTag getLayout(AbstractLayoutSource.LayoutCacheHint hint)
Returns a layout definition from cache based on the cache hint.
abstract String getLayoutString(String location)
Returns the string representation of a layout definition.
[Expand]
Inherited Methods
From class java.lang.Object
From interface com.microstrategy.web.transform.LayoutSource

Public Constructors

public AbstractLayoutSource ()

Protected Methods

protected void checkNullObject (Object o, String msg)

A utility method to check whether an object is null. IllegalArgumentException is thrown if the object is null.

Parameters
o the object to check
msg the error message used to report error

protected LayoutTag getLayout (AbstractLayoutSource.LayoutCacheHint hint)

Returns a layout definition from cache based on the cache hint.

Parameters
hint the cache hint
Returns
  • the layout definition
Throws
CacheException thrown if there is any error retrieving the object from cache or loading the object into cache

protected abstract String getLayoutString (String location)

Returns the string representation of a layout definition. The layout cache uses this method to load the layout definition string and then delegates to the layout parser to parse it. The parsed layou definition is cached.

Parameters
location the layout location, defined in the StyleCatalog XML file.
Returns
  • the string representation of a layout definition.
Throws
WebTransformException if there is any error while retrieving the layout string