com.ibm.pim.utils
Interface TimezoneResolver


public interface TimezoneResolver


Field Summary
static java.lang.String copyright
           
 
Method Summary
 java.lang.String getEncodedFormFromOffset(int offset)
          Accepts an integer value, representing an offset in minutes past GMT, and returns an encoded timezone (if one exists) that represents that offset.
 java.lang.String getEncodedFormFromTimezoneString(java.lang.String timezoneString)
          Accepts a textual representation of a timezone, and returns an appropriate encoded timezone (if one exists) Where there are multiple possible matches for a timezone string, this method will return the first match found.
 java.lang.String[] getEncodedTimezoneStrings()
          Retrieve an array of all encoded timezone strings, representing every timezone.
 java.lang.String getOffsetFromEncodedForm(java.lang.String encodedTimezone)
          Accepts an encoded timezone, as retrievable via getAttribute, and returns the offset in minutes from GMT
 java.lang.String getTimezoneStringFromEncodedForm(java.lang.String encodedTimezone)
          Accepts an encoded timezone, as retrievable via getAttribute, and returns a textual representation of it
 java.lang.String[] getTimezoneStrings()
          Retrieve an array of textual representations of every timezone
 

Field Detail

copyright

static final java.lang.String copyright
See Also:
Constant Field Values
Method Detail

getOffsetFromEncodedForm

java.lang.String getOffsetFromEncodedForm(java.lang.String encodedTimezone)
Accepts an encoded timezone, as retrievable via getAttribute, and returns the offset in minutes from GMT

Parameters:
encodedTimezone - an encoded timezone
Returns:
string containing the offset from GMT
Throws:
java.lang.IllegalArgumentException - If the encodedTimezone is null or an empty string or the encodedTimezone passed is not supported by the PIMSystem.

getTimezoneStringFromEncodedForm

java.lang.String getTimezoneStringFromEncodedForm(java.lang.String encodedTimezone)
Accepts an encoded timezone, as retrievable via getAttribute, and returns a textual representation of it

Parameters:
encodedTimezone - an encoded timezone
Returns:
textual representation of timezone.
Throws:
java.lang.IllegalArgumentException - If the encodedTimezone is null or an empty string or the encodedTimezone passed is not supported by the PIMSystem.

getEncodedFormFromOffset

java.lang.String getEncodedFormFromOffset(int offset)
Accepts an integer value, representing an offset in minutes past GMT, and returns an encoded timezone (if one exists) that represents that offset. Where there are multiple possible matches for a timezone offset, this method will return the first match found.

Parameters:
offset - in minutes from GMT
Returns:
an encoded Timezone string, suitable for use with setAttribute etc.
Throws:
java.lang.IllegalArgumentException - If the offset passed is not supported by the PIMSystem.

getEncodedFormFromTimezoneString

java.lang.String getEncodedFormFromTimezoneString(java.lang.String timezoneString)
Accepts a textual representation of a timezone, and returns an appropriate encoded timezone (if one exists) Where there are multiple possible matches for a timezone string, this method will return the first match found.

Parameters:
timezoneString - a textual representation of a timezone, as obtained by 'getTimezoneStringFromEncodedForm' or 'getTimezoneStrings'
Returns:
an encoded Timezone string, suitable for use with setAttribute etc.
Throws:
java.lang.IllegalArgumentException - If the timezoneString is null or an empty string or the timezoneString passed is not supported by the PIMSystem.

getTimezoneStrings

java.lang.String[] getTimezoneStrings()
Retrieve an array of textual representations of every timezone

Returns:
an array of timezone strings.

getEncodedTimezoneStrings

java.lang.String[] getEncodedTimezoneStrings()
Retrieve an array of all encoded timezone strings, representing every timezone.