microsoft.exchange.webservices.data.core
Class SimplePropertyBag<TKey>

java.lang.Object
  extended by microsoft.exchange.webservices.data.core.SimplePropertyBag<TKey>
Type Parameters:
TKey - The type of key
All Implemented Interfaces:
Iterable<HashMap<TKey,Object>>

public class SimplePropertyBag<TKey>
extends Object
implements Iterable<HashMap<TKey,Object>>

Represents a simple property bag.


Constructor Summary
SimplePropertyBag()
          Initializes a new instance of the class.
 
Method Summary
 void addOnChangeEvent(IPropertyBagChangedDelegate<TKey> change)
          Set event to happen when property changed.
 void clearChangeLog()
          Clears the change log.
 boolean containsKey(TKey key)
          Determines whether the specified key is in the property bag.
 Iterable<TKey> getAddedItems()
          Gets the added item.
 Iterable<TKey> getModifiedItems()
          Gets the modified item.
 Iterable<TKey> getRemovedItems()
          Gets the removed item.
 Object getSimplePropertyBag(TKey key)
          Gets the simple property bag.
 Iterator<HashMap<TKey,Object>> iterator()
          Returns an iterator over a set of elements of type T.
 void removeChangeEvent(IPropertyBagChangedDelegate<TKey> change)
          Remove the event from happening when property changed.
 void setSimplePropertyBag(TKey key, Object value)
          Sets the simple property bag.
 boolean tryGetValue(TKey key, OutParam<Object> value)
          Tries to get value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimplePropertyBag

public SimplePropertyBag()
Initializes a new instance of the class.

Method Detail

getAddedItems

public Iterable<TKey> getAddedItems()
Gets the added item. The added item.

Returns:
the added item

getRemovedItems

public Iterable<TKey> getRemovedItems()
Gets the removed item. The removed item.

Returns:
the removed item

getModifiedItems

public Iterable<TKey> getModifiedItems()
Gets the modified item. The modified item.

Returns:
the modified item

clearChangeLog

public void clearChangeLog()
Clears the change log.


containsKey

public boolean containsKey(TKey key)
Determines whether the specified key is in the property bag.

Parameters:
key - the key
Returns:
true, if successful if the specified key exists; otherwise, .

tryGetValue

public boolean tryGetValue(TKey key,
                           OutParam<Object> value)
Tries to get value.

Parameters:
key - the key
value - the value
Returns:
True if value exists in property bag.

getSimplePropertyBag

public Object getSimplePropertyBag(TKey key)
Gets the simple property bag.

Parameters:
key - the key
Returns:
the simple property bag

setSimplePropertyBag

public void setSimplePropertyBag(TKey key,
                                 Object value)
Sets the simple property bag.

Parameters:
key - the key
value - the value

addOnChangeEvent

public void addOnChangeEvent(IPropertyBagChangedDelegate<TKey> change)
Set event to happen when property changed.

Parameters:
change - change event

removeChangeEvent

public void removeChangeEvent(IPropertyBagChangedDelegate<TKey> change)
Remove the event from happening when property changed.

Parameters:
change - change event

iterator

public Iterator<HashMap<TKey,Object>> iterator()
Returns an iterator over a set of elements of type T.

Specified by:
iterator in interface Iterable<HashMap<TKey,Object>>
Returns:
an Iterator.


Copyright © 2012–2015 Microsoft. All rights reserved.