FMIceLinkManagedConcurrentDictionary Class Reference
Inherits from | NSObject |
---|---|
Conforms to | TKey TValue __covariant |
Declared in | FMIceLinkManagedConcurrentDictionary.h FMIceLinkManagedConcurrentDictionary.m |
– addOrUpdateWithKey:addValue:updateValueFactory:
- (id)addOrUpdateWithKey:(id)key addValue:(id)addValue updateValueFactory:(FMIceLinkFunction2 *)updateValueFactory
Parameters
key |
The key to use for updating for adding. |
---|---|
addValue |
The value to be added for an absent key. |
updateValueFactory |
The function to use for generating a value based on an existing key. @return |
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– addOrUpdateWithKey:addValue:updateValueFactoryBlock:
- (id)addOrUpdateWithKey:(id)key addValue:(id)addValue updateValueFactoryBlock:(id ( ^ ) ( id , id ))updateValueFactoryBlock
Parameters
key |
The key to use for updating for adding. |
---|---|
addValue |
The value to be added for an absent key. |
updateValueFactoryBlock |
The function to use for generating a value based on an existing key. @return |
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– addOrUpdateWithKeyAndAddValueAndUpdateValueFactoryBlock
@inlineparam key The key to use for updating for adding. @inlineparam addValue The value to be added for an absent key. @inlineparam updateValueFactoryBlock The function to use for generating a value based on an existing key. @return
- (id ( ^ ) ( id , id , id ( ^ ) ( id , id ) ))addOrUpdateWithKeyAndAddValueAndUpdateValueFactoryBlock
Discussion
@inlineparam key The key to use for updating for adding. @inlineparam addValue The value to be added for an absent key. @inlineparam updateValueFactoryBlock The function to use for generating a value based on an existing key. @return
Declared In
FMIceLinkManagedConcurrentDictionary.h
– clear
- (void)clear
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– containsKey:
- (bool)containsKey:(id)key
Parameters
key |
The key to check. |
---|
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– count
- (int)count
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– getOrAddWithKey:valueFactory:
- (id)getOrAddWithKey:(id)key valueFactory:(FMIceLinkFunction1 *)valueFactory
Parameters
key |
The key to use when adding to the dictionary. |
---|---|
valueFactory |
The Func that will create a value if needed. |
Return Value
The dictionary value if exist, the value returned by the Func if not.
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– getOrAddWithKey:valueFactoryBlock:
- (id)getOrAddWithKey:(id)key valueFactoryBlock:(id ( ^ ) ( id ))valueFactoryBlock
Parameters
key |
The key to use when adding to the dictionary. |
---|---|
valueFactoryBlock |
The Func that will create a value if needed. |
Return Value
The dictionary value if exist, the value returned by the Func if not.
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– getOrAddWithKeyAndValueFactoryBlock
@inlineparam key The key to use when adding to the dictionary. @inlineparam valueFactoryBlock The Func that will create a value if needed.
- (id ( ^ ) ( id , id ( ^ ) ( id ) ))getOrAddWithKeyAndValueFactoryBlock
Return Value
The dictionary value if exist, the value returned by the Func if not.
Discussion
@inlineparam key The key to use when adding to the dictionary. @inlineparam valueFactoryBlock The Func that will create a value if needed.
Declared In
FMIceLinkManagedConcurrentDictionary.h
– init
- (instancetype)init
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– initWithHashCallback:
- (instancetype)initWithHashCallback:(FMIceLinkFunction1 *)hashCallback
Parameters
hashCallback |
The hash function to use when the backing dictionary requires the key to be a string. |
---|
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– initWithHashCallbackBlock:
- (instancetype)initWithHashCallbackBlock:(NSString *( ^ ) ( id ))hashCallbackBlock
Parameters
hashCallbackBlock |
The hash function to use when the backing dictionary requires the key to be a string. |
---|
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– isEmpty
- (bool)isEmpty
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– keys
- (NSMutableArray *)keys
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
+ managedConcurrentDictionary
+ (FMIceLinkManagedConcurrentDictionary *)managedConcurrentDictionary
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
+ managedConcurrentDictionaryWithHashCallback:
+ (FMIceLinkManagedConcurrentDictionary *)managedConcurrentDictionaryWithHashCallback:(FMIceLinkFunction1 *)hashCallback
Parameters
hashCallback |
The hash function to use when the backing dictionary requires the key to be a string. |
---|
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
+ managedConcurrentDictionaryWithHashCallbackBlock:
+ (FMIceLinkManagedConcurrentDictionary *)managedConcurrentDictionaryWithHashCallbackBlock:(NSString *( ^ ) ( id ))hashCallbackBlock
Parameters
hashCallbackBlock |
The hash function to use when the backing dictionary requires the key to be a string. |
---|
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– tryAddWithKey:value:
- (bool)tryAddWithKey:(id)key value:(id)value
Parameters
key |
The key to use when adding. |
---|---|
value |
The value to be added to the dictionary. |
Return Value
True if added, false if key already exists.
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– tryGetValueWithKey:value:
- (bool)tryGetValueWithKey:(id)key value:(id *)value
Parameters
key |
They key of the item to get form the dictionary. |
---|---|
value |
The value that was just received or null if failed. |
Return Value
True if succeeded.
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– tryRemoveWithKey:value:
- (bool)tryRemoveWithKey:(id)key value:(id *)value
Parameters
key |
The key of the item to remove. |
---|---|
value |
The value that was just removed. |
Return Value
True if successful.
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– tryUpdateWithKey:newValue:comparisonValue:
- (bool)tryUpdateWithKey:(id)key newValue:(id)newValue comparisonValue:(id)comparisonValue
Parameters
key |
The key to use when updating. |
---|---|
newValue |
The new value. |
comparisonValue |
The value to compare with the current value in the dictionary. |
Return Value
True if succeeded.
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h
– values
- (NSMutableArray *)values
Discussion
Declared In
FMIceLinkManagedConcurrentDictionary.h