Package org.scopemvc.util

Utility classes that include two main areas of interest to application developers: ScopeConfig for configuring the Scope framework, and UIStrings used to look up user-readable Strings from localised resources.

See:
          Description

Interface Summary
ObjectPool Pool of objects
PoolableObjectFactory Interface for creating poolable objects.
 

Class Summary
BasicObjectPool Pools objects given a factory and optional maximum pool size.
BasicPoolableObjectFactory Creates pooleable instances of a specific class.
DateTime An empty marker subclass of java.util.Date that DateTimeStringConvertor is associated with in the default configuration.
Debug A (very simple) general purpose Debug class for assertion checking.
DefaultScopeConfig Default resources for Scope.
KeyValue Holds two Objects: a key and a value.
ObjectPoolManager Manages pooling of instances of different classes.
ResourceLoader Utility class for loading resources.
ScopeConfig Loads the Scope config in such a way that custom properties can be set from the Java command line (-D switch) or from a custom ResourceBundle.
Time An empty marker subclass of java.util.Date that TimeStringConvertor is associated with in the default configuration.
UIStrings Uses a ResourceBundle as a dictionary mapping IDs against user-readable Strings that can be presented on the UI.
WeakSet Holds a set of objects where the fact that the object is contained within the set does not prevent it from being garbage collected.
 

Exception Summary
LocalizedException An Exception that implements LocalizedException.getLocalizedMessage() by looking up its message as an ID that is looked up in UIStrings to present the user with a localised message: message parameters passed in are substituted in the message as java.text.MessageFormat.
 

Package org.scopemvc.util Description

Utility classes that include two main areas of interest to application developers: ScopeConfig for configuring the Scope framework, and UIStrings used to look up user-readable Strings from localised resources.

ScopeConfig

ScopeConfig is the configuration manager used to configure various aspects of Scope. Default configuration is provided by the DefaultScopeConfig ResourceBundle.

Scope can be configured by supplying an application-specific ResourceBundle and calling setPropertiesName during application startup. Any properties defined in a custom config in this way will override the defaults.

Scope configuration includes the following:

{ "org.scopemvc.view.servlet.xml.ServletXSLView.ModelElement", "data" }, { "org.scopemvc.view.servlet.xml.ServletXSLView.ElementElement", "element" }, { "org.scopemvc.view.servlet.xml.ServletXSLView.IDAttribute", "id" }, { "org.scopemvc.view.servlet.xml.ServletXSLView.IndexElement", "index" }, { "org.scopemvc.controller.servlet.ScopeServlet.maxControllerPoolSize", new Integer(10) },

UIStrings

A dictionary that uses localised ResourceBundle(s) to look up user-readable Strings by a key. This is used by the default ControlException handler in BasicController treating the message in the exception as a key to look up a localised String from UIStrings.

The property resource used for an application must be set up by calling UIStrings.setPropertiesName(java.lang.String) at application startup. The usual ResourceBundle localisation applies to the resource specified.



Copyright © 2000-2002 The Scope Team. All Rights Reserved.