com.bankframe.services.resource
Class BankFrameResourceSubset

java.lang.Object
  extended bycom.bankframe.services.resource.BankFrameResourceSubset
All Implemented Interfaces:
BankFrameResource

public class BankFrameResourceSubset
extends java.lang.Object
implements BankFrameResource

This class provides a standard implementation of BankFrameResource subsets

Author:
ETU

Field Summary
static char SEPARATOR_CHAR
           
 
Constructor Summary
BankFrameResourceSubset(java.lang.String prefix, BankFrameResource parent)
          Constructor.
 
Method Summary
 java.lang.Object get(java.lang.String key)
          This method gets a value.
 java.lang.Boolean getBoolean(java.lang.String keyName)
          This method gets the value of the specified property as a Boolean value.
 java.lang.String getDescription(java.lang.String key)
          This method gets a textual description for the specified key (or subset)
 java.lang.String getDescription(java.lang.String key, java.util.Locale locale)
          This method gets a textual description for the specified key (or subset) localised to the specified locale
 java.lang.Double getDouble(java.lang.String keyName)
          This method gets the value of the specified property as a Double object.
 java.lang.Integer getInteger(java.lang.String keyName)
          This method gets the value of the specified property as an Integer object.
 java.lang.Long getLong(java.lang.String keyName)
          This method gets the value of the specified property as a Long object.
 java.lang.String getString(java.lang.String key)
          This method gets a value associated with a given key.
 BankFrameResource getSubset(java.lang.String prefix)
          This method gets a subset of values whose keys all begin with the specified prefix.
 java.util.Enumeration keys()
          This method gets the names of all the values in this resource bundle.
 java.lang.Object put(java.lang.String key, java.lang.Object value)
          This method adds or updates a value in the resource bundle.
 void remove(java.util.Enumeration keys)
          This method removes keys from the resource.
 java.lang.Object remove(java.lang.String key)
          This method removes a value from the resource bundle.
 void removeAll()
          This method removes all entries in this subset from the bundle.
 void removeSubset(java.lang.String prefix)
          This method removes a subset of values from the resource.
 int size()
          This method returns the number of elements in the resource
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SEPARATOR_CHAR

public static final char SEPARATOR_CHAR
See Also:
Constant Field Values
Constructor Detail

BankFrameResourceSubset

public BankFrameResourceSubset(java.lang.String prefix,
                               BankFrameResource parent)
Constructor.

Parameters:
prefix - the prefix that this subset starts with
parent - the resource bundle that this subset belongs to
Method Detail

get

public java.lang.Object get(java.lang.String key)
This method gets a value.

Specified by:
get in interface BankFrameResource
Parameters:
key - the key name of the value to get
Returns:
the value for the given key or null if the value is not found

getString

public java.lang.String getString(java.lang.String key)
This method gets a value associated with a given key.

Specified by:
getString in interface BankFrameResource
Parameters:
key - The key name of the value to get.
Returns:
The value for the key or null if no value exists.

getSubset

public BankFrameResource getSubset(java.lang.String prefix)
This method gets a subset of values whose keys all begin with the specified prefix.

Specified by:
getSubset in interface BankFrameResource
Parameters:
prefix - the prefix that the subset starts with
Returns:
a BankFrameResource instance containing the subset

keys

public java.util.Enumeration keys()
This method gets the names of all the values in this resource bundle.

Specified by:
keys in interface BankFrameResource
Returns:
an enumeration of key names

put

public java.lang.Object put(java.lang.String key,
                            java.lang.Object value)
This method adds or updates a value in the resource bundle.

Specified by:
put in interface BankFrameResource
Parameters:
key - the name of the value
value - the value

remove

public java.lang.Object remove(java.lang.String key)
This method removes a value from the resource bundle.

Specified by:
remove in interface BankFrameResource
Parameters:
key - the name of the key to remove
Returns:
the object removed or null if there was no object for the given key

remove

public void remove(java.util.Enumeration keys)
This method removes keys from the resource.

Specified by:
remove in interface BankFrameResource
Parameters:
keys - an enumeration of keys to remove.

removeAll

public void removeAll()
This method removes all entries in this subset from the bundle.

Specified by:
removeAll in interface BankFrameResource

removeSubset

public void removeSubset(java.lang.String prefix)
This method removes a subset of values from the resource.

Specified by:
removeSubset in interface BankFrameResource
Parameters:
prefix - he prefix that the subset starts with

getLong

public java.lang.Long getLong(java.lang.String keyName)
Description copied from interface: BankFrameResource
This method gets the value of the specified property as a Long object.

Specified by:
getLong in interface BankFrameResource
Returns:
the value of the specifed property or null if a value does not exist
See Also:
BankFrameResource.getLong(String)

getInteger

public java.lang.Integer getInteger(java.lang.String keyName)
Description copied from interface: BankFrameResource
This method gets the value of the specified property as an Integer object.

Specified by:
getInteger in interface BankFrameResource
Returns:
the value of the specifed property or null if a value does not exist
See Also:
BankFrameResource.getInteger(String)

getBoolean

public java.lang.Boolean getBoolean(java.lang.String keyName)
Description copied from interface: BankFrameResource
This method gets the value of the specified property as a Boolean value. If the value contains 'true' this method will return Boolean.TRUE, or Boolean.FALSE otherwise.

Specified by:
getBoolean in interface BankFrameResource
Returns:
the value of the specifed property or null if a value does not exist
See Also:
BankFrameResource.getBoolean(String)

getDouble

public java.lang.Double getDouble(java.lang.String keyName)
Description copied from interface: BankFrameResource
This method gets the value of the specified property as a Double object.

Specified by:
getDouble in interface BankFrameResource
Returns:
the value of the specifed property or null if a value does not exist
See Also:
BankFrameResource.getDouble(String)

size

public int size()
Description copied from interface: BankFrameResource
This method returns the number of elements in the resource

Specified by:
size in interface BankFrameResource
See Also:
Exercise caution in calling this method. To determine the number of keys in this subset, this method must iterate over all keys in the parent set, finding those that start with the prefix for this set.

getDescription

public java.lang.String getDescription(java.lang.String key,
                                       java.util.Locale locale)
Description copied from interface: BankFrameResource
This method gets a textual description for the specified key (or subset) localised to the specified locale

Specified by:
getDescription in interface BankFrameResource
See Also:
BankFrameResource.getDescription(String, Locale)

getDescription

public java.lang.String getDescription(java.lang.String key)
Description copied from interface: BankFrameResource
This method gets a textual description for the specified key (or subset)

Specified by:
getDescription in interface BankFrameResource
See Also:
BankFrameResource.getDescription(String)


Copyright © 2004 Siebel Systems, Inc. All rights reserved.