org.iternine.jeppetto.dao.mongodb.enhance
Class DirtyableDBObjectMap

java.lang.Object
  extended by org.iternine.jeppetto.dao.mongodb.enhance.DirtyableDBObjectMap
All Implemented Interfaces:
com.mongodb.DBObject, Map, org.bson.BSONObject, DirtyableDBObject

public class DirtyableDBObjectMap
extends Object
implements Map, DirtyableDBObject


Nested Class Summary
 
Nested classes/interfaces inherited from interface java.util.Map
Map.Entry<K,V>
 
Constructor Summary
DirtyableDBObjectMap()
           
DirtyableDBObjectMap(Map delegate)
           
 
Method Summary
 void clear()
           
 boolean containsField(String field)
           
 boolean containsKey(Object o)
           
 boolean containsKey(String key)
           
 boolean containsValue(Object o)
           
 Set entrySet()
           
 Object get(Object o)
           
 Object get(String key)
           
 boolean isDirty()
           
 boolean isEmpty()
           
 boolean isPartialObject()
           
 boolean isPersisted()
           
 Set keySet()
           
 void markAsPartialObject()
           
 void markPersisted()
          Consider the current state of the object to be in sync with the persisted state.
 Object put(Object key, Object value)
           
 Object put(String key, Object value)
           
 void putAll(org.bson.BSONObject bsonObject)
           
 void putAll(Map m)
           
 Object remove(Object key)
           
 Object removeField(String key)
           
 int size()
           
 Map toMap()
           
 Collection values()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Map
equals, hashCode
 

Constructor Detail

DirtyableDBObjectMap

public DirtyableDBObjectMap()

DirtyableDBObjectMap

public DirtyableDBObjectMap(Map delegate)
Method Detail

put

public Object put(Object key,
                  Object value)
Specified by:
put in interface Map

remove

public Object remove(Object key)
Specified by:
remove in interface Map

putAll

public void putAll(Map m)
Specified by:
putAll in interface Map
Specified by:
putAll in interface org.bson.BSONObject

clear

public void clear()
Specified by:
clear in interface Map

size

public int size()
Specified by:
size in interface Map

isEmpty

public boolean isEmpty()
Specified by:
isEmpty in interface Map

containsKey

public boolean containsKey(Object o)
Specified by:
containsKey in interface Map

containsValue

public boolean containsValue(Object o)
Specified by:
containsValue in interface Map

get

public Object get(Object o)
Specified by:
get in interface Map

keySet

public Set keySet()
Specified by:
keySet in interface Map
Specified by:
keySet in interface org.bson.BSONObject

values

public Collection values()
Specified by:
values in interface Map

entrySet

public Set entrySet()
Specified by:
entrySet in interface Map

isDirty

public boolean isDirty()
Specified by:
isDirty in interface DirtyableDBObject
Returns:
true if this object is dirtied from it's persisted state

markPersisted

public void markPersisted()
Description copied from interface: DirtyableDBObject
Consider the current state of the object to be in sync with the persisted state.

Specified by:
markPersisted in interface DirtyableDBObject

isPersisted

public boolean isPersisted()
Specified by:
isPersisted in interface DirtyableDBObject
Returns:
true if this object has a representation in the underlying store.

markAsPartialObject

public void markAsPartialObject()
Specified by:
markAsPartialObject in interface com.mongodb.DBObject

isPartialObject

public boolean isPartialObject()
Specified by:
isPartialObject in interface com.mongodb.DBObject

put

public Object put(String key,
                  Object value)
Specified by:
put in interface org.bson.BSONObject

putAll

public void putAll(org.bson.BSONObject bsonObject)
Specified by:
putAll in interface org.bson.BSONObject

get

public Object get(String key)
Specified by:
get in interface org.bson.BSONObject

toMap

public Map toMap()
Specified by:
toMap in interface org.bson.BSONObject

removeField

public Object removeField(String key)
Specified by:
removeField in interface org.bson.BSONObject

containsKey

public boolean containsKey(String key)
Specified by:
containsKey in interface org.bson.BSONObject

containsField

public boolean containsField(String field)
Specified by:
containsField in interface org.bson.BSONObject


Copyright © 2012. All Rights Reserved.