wt.ixb.objectset
Class ObjectSetHandlerTemplate

java.lang.Object
  extended bywt.ixb.objectset.ObjectSetHandlerTemplate
All Implemented Interfaces:
ObjectSetHandler
Direct Known Subclasses:
ObjectSetFilterTemplate, ObjectSetGeneratorTemplate

public abstract class ObjectSetHandlerTemplate
extends Object
implements ObjectSetHandler

Class extends ObjectSetHandler interface with trivial implementations for most methods.- It can be used by application to make application less dependent of future extension of ObjectSetHandler interface.

Supported API: true

Extendable: false


Field Summary
private static String CLASSNAME
           
private static String RESOURCE
           
private  IxbElement xmlDescription
           
 
Fields inherited from interface wt.ixb.objectset.ObjectSetHandler
XML_TAG_DISPLAY, XML_TAG_OBJECT_CREATOR_NAME, XML_TAG_OBJECT_SET_CREATOR, XML_TAG_OBJECT_SET_DIALOG_CLASS_NAME, XML_TAG_OBJECT_SET_HANDLER_CREATOR, XML_TAG_OBJECT_SET_HANDLER_FILTER, XML_TAG_OBJECT_SET_HANDLER_GENERATOR, XML_TAG_OBJECT_SET_HANDLER_HANDLER, XML_TAG_OBJECT_SET_HANDLER_ID, XML_TAG_OBJECT_SET_HANDLER_PARAMETERS, XML_TAG_OBJECT_SET_LOCALIZED_DESCR, XML_TAG_OBJECT_SET_LOCALIZED_MSG_CLASS, XML_TAG_OBJECT_SET_LOCALIZED_MSG_KEY, XML_TAG_OBJECT_SET_LOCALIZED_NAME
 
Constructor Summary
ObjectSetHandlerTemplate()
           
 
Method Summary
 String getAppletClassName()
          Get the associated java class name which interacts with the client for this ObjectSetHandler type, e.g.
protected  Locale getClientLocale()
           
 String getId()
          Get the identifier of this ObjectSetHandler type.
abstract  String getLocalizedDescription()
          Get the localized description of this ObjectSetHandler instance.
private  String getLocalizedMessageClass(IxbElement el)
           
private  String getLocalizedMessageKey(IxbElement el)
           
 String getLocalizedMessageWithoutParams(IxbElement el)
           
 String getLocalizedMessageWithoutParams(IxbElement el, Locale locale)
           
 String getLocalizedMessageWithParams(IxbElement el, String[] params)
           
 String getLocalizedName()
          Returns the localized name of the ObjectSetHandler type.
 String getLocalizedName(Locale locale)
          Returns the localized name of the ObjectSetHandler type for the specific Locale.
abstract  String getParametersAsString()
          This method can be used only after setParametersAsString(String) is called.
 void initialize(IxbElement xmlDescription)
          Initialize this ObjectSetHandler instance.
abstract  void setParametersAsString(String params)
          Save the value for this ObjectSetHandler instance.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RESOURCE

private static final String RESOURCE
See Also:
Constant Field Values

CLASSNAME

private static final String CLASSNAME

xmlDescription

private IxbElement xmlDescription
Constructor Detail

ObjectSetHandlerTemplate

public ObjectSetHandlerTemplate()
Method Detail

setParametersAsString

public abstract void setParametersAsString(String params)
                                    throws WTException
Save the value for this ObjectSetHandler instance. For example, for ObjectSetGenerator instance, this is the object identifier of the seed object.

Supported API: true

Specified by:
setParametersAsString in interface ObjectSetHandler
Parameters:
params -
Throws:
WTException

getParametersAsString

public abstract String getParametersAsString()
                                      throws WTException
This method can be used only after setParametersAsString(String) is called.

Supported API: true

Specified by:
getParametersAsString in interface ObjectSetHandler
Returns:
String
Throws:
WTException

getLocalizedDescription

public abstract String getLocalizedDescription()
                                        throws WTException
Get the localized description of this ObjectSetHandler instance. Usually it contains the localized information of this ObjectSetHandler type as well as the parameter set from setParametersAsString. The import/export will try to find the locale from the session context for localization purpose.
This method can be used only after setParametersAsString(String) is called.

Supported API: true

Specified by:
getLocalizedDescription in interface ObjectSetHandler
Returns:
String
Throws:
WTException

initialize

public void initialize(IxbElement xmlDescription)
                throws WTException
Initialize this ObjectSetHandler instance. Usually the parameter xmlDescription is corresponding to the XML files from server registry.

Supported API: true

Specified by:
initialize in interface ObjectSetHandler
Parameters:
xmlDescription - The information for initialize this ObjectSetHandler instance.
Throws:
WTException

getId

public String getId()
             throws WTException
Get the identifier of this ObjectSetHandler type. The identifier is specified in the server registry.

Supported API: true

Specified by:
getId in interface ObjectSetHandler
Returns:
String
Throws:
WTException

getLocalizedName

public String getLocalizedName()
                        throws WTException
Returns the localized name of the ObjectSetHandler type.
To get the localized name for the specific Locale, use the method getLocalizedName(Locale locale).

Supported API: true

Specified by:
getLocalizedName in interface ObjectSetHandler
Returns:
String
Throws:
WTException

getLocalizedName

public String getLocalizedName(Locale locale)
                        throws WTException
Returns the localized name of the ObjectSetHandler type for the specific Locale. Refer the server registry file for details.

Supported API: true

Specified by:
getLocalizedName in interface ObjectSetHandler
Parameters:
locale -
Returns:
String
Throws:
WTException

getAppletClassName

public String getAppletClassName()
                          throws WTException
Get the associated java class name which interacts with the client for this ObjectSetHandler type, e.g. wt.clients.ixb.exp.NavigatorSearchDialog. See the registry file for details.

Supported API: true

Specified by:
getAppletClassName in interface ObjectSetHandler
Returns:
String
Throws:
WTException

getLocalizedMessageWithoutParams

public String getLocalizedMessageWithoutParams(IxbElement el)
                                        throws WTException
Throws:
WTException

getLocalizedMessageWithoutParams

public String getLocalizedMessageWithoutParams(IxbElement el,
                                               Locale locale)
                                        throws WTException
Throws:
WTException

getLocalizedMessageWithParams

public String getLocalizedMessageWithParams(IxbElement el,
                                            String[] params)
                                     throws WTException
Throws:
WTException

getClientLocale

protected Locale getClientLocale()

getLocalizedMessageKey

private String getLocalizedMessageKey(IxbElement el)
                               throws WTException
Throws:
WTException

getLocalizedMessageClass

private String getLocalizedMessageClass(IxbElement el)
                                 throws WTException
Throws:
WTException