| JGL - The Generic Collection Library for Java |
All Packages Class Hierarchy This Package Previous Next Index
Class com.objectspace.jgl.Map
java.lang.Object
|
+----java.util.Dictionary
|
+----com.objectspace.jgl.Map
- public abstract class Map
- extends Dictionary
- implements Container
- super class of:
- HashMap, OrderedMap
Map is the abstract class that in implemented by all JGL maps.
This is an abstract class and not an interface because it extends the JDK
Dictionary class.
- See Also:
- HashMap, OrderedMap, Dictionary
-
Map()
-
-
add(Object)
- Add an object to myself.
-
clear()
- Remove all of my objects.
-
clone()
- Return a shallow copy of myself.
-
count(Object)
- Return the number of key/value pairs that match a particular key.
-
countValues(Object)
- Return the number of values that match a given object.
-
elements()
- Return an Enumeration of the components in this container
-
equals(Object)
- Return true if I'm equal to a specified object.
-
finish()
- Return an iterator positioned immediately after my last item.
-
isEmpty()
- Return true if I contain no objects.
-
keys(Object)
- Return an Enumeration of all my keys that are associated with a particular value.
-
maxSize()
- Return the maximum number of objects that I can contain.
-
size()
- Return the number of objects that I contain.
-
start()
- Return an iterator positioned at my first item.
-
toString()
- Return a string that describes me.
-
values(Object)
- Return an Enumeration of all my values that are associated with a particular key.
Map
public Map()
count
public abstract int count(Object key)
- Return the number of key/value pairs that match a particular key.
- Parameters:
- key - The key to match against.
countValues
public abstract int countValues(Object value)
- Return the number of values that match a given object.
- Parameters:
- value - The value to match against.
keys
public abstract Enumeration keys(Object value)
- Return an Enumeration of all my keys that are associated with a particular value.
- Parameters:
- value - The value to match.
values
public abstract Enumeration values(Object key)
- Return an Enumeration of all my values that are associated with a particular key.
- Parameters:
- key - The key to match.
clone
public Object clone()
- Return a shallow copy of myself.
- Overrides:
- clone in class Object
toString
public String toString()
- Return a string that describes me.
- Overrides:
- toString in class Object
equals
public boolean equals(Object object)
- Return true if I'm equal to a specified object.
- Parameters:
- object - The object to compare myself against.
- Returns:
- true if I'm equal to the specified object.
- Overrides:
- equals in class Object
size
public int size()
- Return the number of objects that I contain.
- Overrides:
- size in class Dictionary
maxSize
public int maxSize()
- Return the maximum number of objects that I can contain.
isEmpty
public boolean isEmpty()
- Return true if I contain no objects.
- Overrides:
- isEmpty in class Dictionary
clear
public void clear()
- Remove all of my objects.
elements
public Enumeration elements()
- Return an Enumeration of the components in this container
- Overrides:
- elements in class Dictionary
start
public ForwardIterator start()
- Return an iterator positioned at my first item.
finish
public ForwardIterator finish()
- Return an iterator positioned immediately after my last item.
add
public Object add(Object object)
- Add an object to myself. If appropriate, return the object that it replaced, otherwise
return null.
All Packages Class Hierarchy This Package Previous Next Index