| java.lang.Object com.jcorporate.expresso.core.dbobj.ValidValue com.jcorporate.expresso.core.dbobj.ISOValidValue
ISOValidValue | public class ISOValidValue extends ValidValue (Code) | | An ISO valid value is a enumerated collection very similar to a
pure Struts label and value bean with internationalization
(i18n) support. It typically represent an item of data that is
displayed in a drop-down list box or a menu selection. A valid
value has a real value as known as a key and description.
To support internationalisation (i18n) the description
field also has a dual role. The description field is used a look-up
key into a resource bundle during canonisation.
author: Peter A. Pilgrim, Fri Dec 27 22:33:27 GMT 2002, Created XeNoNSoFT.com version: $Id: ISOValidValue.java,v 1.7 2004/11/18 02:03:27 lhamel Exp $ |
Constructor Summary | |
public | ISOValidValue() Default constructor for creating a valid value. | public | ISOValidValue(String newValue, String newDescrip) Original constructor for creating a valid value. | public | ISOValidValue(String schemaClass, String prefix, String value, String description) | public | ISOValidValue(String schemaClass, Locale locale, String prefix, String value, String description) | public | ISOValidValue(RequestContext request, String schemaClass, String prefix, String value, String description) |
ISOValidValue | public ISOValidValue()(Code) | | Default constructor for creating a valid value.
Please note: no canonization takes place within this method.
|
ISOValidValue | public ISOValidValue(String newValue, String newDescrip)(Code) | | Original constructor for creating a valid value.
Please note: no canonization takes place within this method.
Parameters: newValue - the real value of the enumeration Parameters: newDescrip - the description of the enumeration |
ISOValidValue | public ISOValidValue(String schemaClass, String prefix, String value, String description)(Code) | | Constructor of valid value enumeration which automatically
canonizes the description attribute if it can be found
in the schema resource bundle in the default locale
Parameters: schemaClass - the fully qualified class name of the schema Parameters: prefix - the optional prefix argument Parameters: value - the real value string of the enumeration Parameters: description - the description string of the enumerationthat is used as look-up key in the resource bundle See Also: ISOValidValue.canonize(String schemaClass,Locale locale,String prefix) |
ISOValidValue | public ISOValidValue(String schemaClass, Locale locale, String prefix, String value, String description)(Code) | | Constructor of valid value enumeration which automatically
canonizes the description attribute if it can be found
in the schema resource bundle
Parameters: schemaClass - the fully qualified class name of the schema Parameters: locale - the locale Parameters: prefix - the optional prefix argument Parameters: value - the real value string of the enumeration Parameters: description - the description string of the enumerationthat is used as look-up key in the resource bundle See Also: ISOValidValue.canonize(String schemaClass,Locale locale,String prefix) |
ISOValidValue | public ISOValidValue(RequestContext request, String schemaClass, String prefix, String value, String description)(Code) | | Constructor of valid value enumeration which automatically
canonizes the description attribute if it can be found
in the schema resource bundle
Parameters: schemaClass - the fully qualified class name of the schema Parameters: request - the request context Parameters: prefix - the optional prefix argument Parameters: value - the real value string of the enumeration Parameters: description - the description string of the enumerationthat is used as look-up key in the resource bundle See Also: ISOValidValue.canonize(RequestContext request,String schemaClass,String prefix) |
canonize | public String canonize(String schemaClass, String prefix)(Code) | | This is method will attempt to convert the
description attribute into a the default locale value
string from a message resource bundle. If the
prefix parameter is not null then the
description attribute is prepended with a full
stop "." to the original description string to make a new look
up key. Otherwise if the prefix parameter is null
then original description is the look up key. The key value is
used to look up the description from a resource bundle.
Parameters: schemaClass - the fully qualified class name of the schema Parameters: prefix - the optional prefix argument result the string if found in the resource bundle or null See Also: ISOValidValue.canonize(String schemaClass,Locale locale,String prefix) |
canonize | public String canonize(String schemaClass, Locale locale, String prefix)(Code) | | This is method will attempt to convert the
description attribute into a localised value
string from a message resource bundle. If the
prefix parameter is not null then the
description attribute is prepended with a full
stop "." to the original description string to make a new look
up key. Otherwise if the prefix parameter is null
then original description is the look up key. The key value is
used to look up the description from a resource bundle.
Parameters: schemaClass - the fully qualified class name of the schema Parameters: locale - the locale Parameters: prefix - the optional prefix argument result the string if found in the resource bundle or null See Also: ISOValidValue.getDescription |
getDescription | public String getDescription()(Code) | | Gets the description of the valid value
the description |
setDescription | public void setDescription(String description)(Code) | | Sets the real description of the valid value
Parameters: description - the new description string See Also: ISOValidValue.getDescription |
toString | public String toString()(Code) | | Human readable string for debugging
java.lang.String |
|
|