org.apache.ojb.odmg.collections
Class DMapImpl

java.lang.Object
  extended byjava.util.AbstractMap
      extended byorg.apache.ojb.odmg.collections.DMapImpl
All Implemented Interfaces:
DMap, java.util.Map, java.io.Serializable

public class DMapImpl
extends java.util.AbstractMap
implements DMap, java.io.Serializable

Version:
$Id: DMapImpl.java,v 1.19 2004/01/07 19:11:11 arminw Exp $
Author:
Thomas Mahler
See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class java.util.AbstractMap
 
Nested classes inherited from class java.util.Map
java.util.Map.Entry
 
Field Summary
 
Fields inherited from class java.util.AbstractMap
 
Constructor Summary
DMapImpl()
          DMapImpl constructor comment.
DMapImpl(int theId, int theSize)
          DMapImpl constructor comment.
DMapImpl(PBKey key)
          DListImpl constructor comment.
 
Method Summary
 java.util.Set entrySet()
          Returns a set view of the mappings contained in this map.
protected  int generateNewId()
          return a unique id
 ManageableHashSet getEntries()
          Gets the entries.
 int getId()
          lazily retrieve the ID of the set, no need to precompute it.
 PBKey getPBKey()
           
 int getSize()
          Gets the size.
 java.lang.Object put(java.lang.Object key, java.lang.Object value)
           
 java.lang.Object remove(java.lang.Object key)
           
 void setEntries(ManageableHashSet entries)
          Sets the entries.
 void setId(int id)
          Sets the id.
 void setPBKey(PBKey pbKey)
           
 void setSize(int size)
          Sets the size.
 
Methods inherited from class java.util.AbstractMap
clear, clone, containsKey, containsValue, equals, get, hashCode, isEmpty, keySet, putAll, size, toString, values
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.Map
clear, containsKey, containsValue, equals, get, hashCode, isEmpty, keySet, putAll, size, values
 

Constructor Detail

DMapImpl

public DMapImpl()
DMapImpl constructor comment.


DMapImpl

public DMapImpl(PBKey key)
DListImpl constructor comment.


DMapImpl

public DMapImpl(int theId,
                int theSize)
DMapImpl constructor comment.

Method Detail

getPBKey

public PBKey getPBKey()

setPBKey

public void setPBKey(PBKey pbKey)

entrySet

public java.util.Set entrySet()
Returns a set view of the mappings contained in this map. Each element in the returned set is a Map.Entry. The set is backed by the map, so changes to the map are reflected in the set, and vice-versa. If the map is modified while an iteration over the set is in progress, the results of the iteration are undefined. The set supports element removal, which removes the corresponding mapping from the map, via the Iterator.remove, Set.remove, removeAll, retainAll and clear operations. It does not support the add or addAll operations.

Specified by:
entrySet in interface java.util.Map
Returns:
a set view of the mappings contained in this map.

generateNewId

protected int generateNewId()
return a unique id


getId

public int getId()
lazily retrieve the ID of the set, no need to precompute it.


put

public java.lang.Object put(java.lang.Object key,
                            java.lang.Object value)
Specified by:
put in interface java.util.Map

remove

public java.lang.Object remove(java.lang.Object key)
Specified by:
remove in interface java.util.Map

getEntries

public ManageableHashSet getEntries()
Gets the entries.

Returns:
Returns a ManageableHashSet

setEntries

public void setEntries(ManageableHashSet entries)
Sets the entries.

Parameters:
entries - The entries to set

setId

public void setId(int id)
Sets the id.

Parameters:
id - The id to set

getSize

public int getSize()
Gets the size.

Returns:
Returns a int

setSize

public void setSize(int size)
Sets the size.

Parameters:
size - The size to set


Authors: Thomas Mahler and others. (C) 2000 - 2003 Apache Software Foundation
All rights reserved. Published under the Apache License.
http://db.apache.org/ojb
Version: 1.0.rc5, 2003-12-14