GATE
Version 3.1-2270

gate.util
Class OptionsMap

java.lang.Object
  extended by java.util.AbstractMap
      extended by java.util.HashMap
          extended by gate.util.OptionsMap
All Implemented Interfaces:
Serializable, Cloneable, Map

public class OptionsMap
extends HashMap

A map that stores values as strings and provides support for converting some frequently used types to and from string

See Also:
Serialized Form

Constructor Summary
OptionsMap()
           
 
Method Summary
 Boolean getBoolean(Object key)
          If the object stored under key is a Boolean then returns its value otherwise returns null;
 Font getFont(Object key)
          If the object stored under key is a String then returns its value otherwise returns null;
 Integer getInt(Object key)
          If the object stored under key is an Integer then returns its value otherwise returns null;
 String getString(Object key)
          If the object stored under key is a String then returns its value otherwise returns null;
 Object put(Object key, Object value)
          Converts the value to string using its toString() method and then stores it
 
Methods inherited from class java.util.HashMap
clear, clone, containsKey, containsValue, entrySet, get, isEmpty, keySet, putAll, remove, size, values
 
Methods inherited from class java.util.AbstractMap
equals, hashCode, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.Map
equals, hashCode
 

Constructor Detail

OptionsMap

public OptionsMap()
Method Detail

put

public Object put(Object key,
                  Object value)
Converts the value to string using its toString() method and then stores it

Specified by:
put in interface Map
Overrides:
put in class HashMap

getInt

public Integer getInt(Object key)
If the object stored under key is an Integer then returns its value otherwise returns null;


getBoolean

public Boolean getBoolean(Object key)
If the object stored under key is a Boolean then returns its value otherwise returns null;


getString

public String getString(Object key)
If the object stored under key is a String then returns its value otherwise returns null;


getFont

public Font getFont(Object key)
If the object stored under key is a String then returns its value otherwise returns null;


GATE
Version 3.1-2270