BBM Enterprise iOS SDK  R3
BBMLiveMap Class Reference
Inheritance diagram for BBMLiveMap:
BBMContainer

Instance Methods

(void) - resync
 
(id) - valueForKey:
 
(NSArray *) - valuesForKeys:
 
(NSArray *) - allKeys
 
(NSArray *) - allValues
 
(id) - objectForKeyedSubscript:
 
(void) - addListener:
 
(void) - removeListener:
 
- Instance Methods inherited from BBMContainer
(NSString *) - identifierOfElement:
 
(void) - reset
 

Properties

BBMElementState state
 Returns the current state of this instance. A current state means the live map is not waiting for any operations to complete. A pending state indicates this object is waiting for an operation to complete. More...
 
- Properties inherited from BBMContainer
BBMDSModelmasterModel
 The top level container. required to resolve foreign keys. More...
 
NSString * type
 The container type. More...
 
NSString * listID
 The listID is only set if the container is not a singleton. More...
 
NSString * className
 The name of the class the container holds or vends. More...
 
Class classObject
 The class the container holds or vends. More...
 
void(^ allElementsReceivedCompletion )(NSArray *)
 

Detailed Description

BBMLiveMap is a key-value container that automatically retrieves and updates its content via BBMDS.

The contained objects can be accessed with an NSDictionary-like interface. These objects are retrieved lazily when they are accessed by using their identifier, i.e. valueForKey:"SomeKey". If an object hasn't been retrieved previously, an unpopulated, newly created instance of BBMElement will be returned. At this point in time the state property for the live map will be set to pending. The values for this instance are then retrieved asynchronously and the live map's state will be set to current once this operation has completed.

Since
R3

Method Documentation

◆ addListener:()

- (void) addListener: (NSObject< BBMLiveListener > *)  listener

Add a listener to this live list

Parameters
listenerThe listener
Since
R3

◆ allKeys()

- (NSArray *) allKeys
See also
NSDictionary

◆ allValues()

- (NSArray *) allValues
See also
NSDictionary

◆ objectForKeyedSubscript:()

- (id) objectForKeyedSubscript: (NSString *)  key

theMap["key"] support

See also
NSDictionary

Implements BBMContainer.

◆ removeListener:()

- (void) removeListener: (NSObject< BBMLiveListener > *)  listener

Remove a listener to this live list

Parameters
listenerThe listener
Since
R3

◆ resync()

- (void) resync

Re-requests all elements that are currently in the map.

Since
R3

◆ valueForKey:()

- (id) valueForKey: (NSString *)  aKey
See also
NSDictionary
Since
R3

◆ valuesForKeys:()

- (NSArray*) valuesForKeys: (NSArray *)  keyArray

Returns an array of objects matching any keys in keyArray

Parameters
keyArrayan array of keys
Since
R3

Property Documentation

◆ state

- (BBMElementState) state
readnonatomicassign

Returns the current state of this instance. A current state means the live map is not waiting for any operations to complete. A pending state indicates this object is waiting for an operation to complete.

Since
R3