com.ibm.portal.cp.services
Interface LocalizedTypeService


public interface LocalizedTypeService

Service that allows to obtain Localized information, e. g. titles, about types.

Since:
7.0.0
Note:
This interface is designed to be implemented by clients.

Field Summary
static java.lang.String ATTR_CLASS
          name of the class attribute used for instantiation
static java.lang.String DEFAULT_EXTENSION_ID
           ID of the default implementation of the LocalizedTypeService.
static java.lang.String EXTENSION_POINT_ID
          ID of the LocalizedTypeService extension point
 
Method Summary
 Localized getLocalized(java.lang.String type, java.util.Map<java.lang.String,java.lang.String[]> params, Context ctx)
          Performs a lookup for the given String to construct a Localized object offering access to titles and descriptions of the type (represented through the given String) in various locales.
 

Field Detail

EXTENSION_POINT_ID

static final java.lang.String EXTENSION_POINT_ID
ID of the LocalizedTypeService extension point

See Also:
Constant Field Values

DEFAULT_EXTENSION_ID

static final java.lang.String DEFAULT_EXTENSION_ID

ID of the default implementation of the LocalizedTypeService. This default implementation can be used to implement a lookup for a localized object if no service has been registered explicitly. It will generate descriptions of the WebSphere Portal provided generic service endpoints.

It is a common usecase to first check for the existence of a localized service that has been registered explicitly for a particular URI and in case no service is registered fall back to the default localized service implementation. Refer to CORLocalizedService for this use case and pass in the default implementation of the localized service as the fallback.

See Also:
Constant Field Values

ATTR_CLASS

static final java.lang.String ATTR_CLASS
name of the class attribute used for instantiation

See Also:
Constant Field Values
Method Detail

getLocalized

Localized getLocalized(java.lang.String type,
                       java.util.Map<java.lang.String,java.lang.String[]> params,
                       Context ctx)
                       throws javax.xml.transform.TransformerException,
                              java.io.IOException,
                              SerializationException,
                              java.net.URISyntaxException,
                              ModelException
Performs a lookup for the given String to construct a Localized object offering access to titles and descriptions of the type (represented through the given String) in various locales. The method may return null in case there is no localized information for the type / parameters combination. In this case a client is free to select a fallback mechanism.

Parameters:
type - type String, must not be null
params - parameter map, must not be null
ctx - COR context, must not be null
Returns:
localized title and description information about the addressed type. Implementors may return null to indicate that the service does not handle the lookup for the specified input parameters.
Throws:
javax.xml.transform.TransformerException - - if the localized object cannot be created
java.io.IOException - - if an IO error occurred when trying to do the lookup
SerializationException
java.net.URISyntaxException
ModelException