ObjFW  Diff

Differences From Artifact [5f2fde2cb0]:

To Artifact [5975df7964]:


47
48
49
50
51
52
53
54
55
56
57
58
59






60
61
62
63
64
65
66
67
68
69
70
71
47
48
49
50
51
52
53






54
55
56
57
58
59


60


61
62
63
64
65
66
67







-
-
-
-
-
-
+
+
+
+
+
+
-
-

-
-







 * @brief An abstract class for storing objects in a dictionary.
 *
 * Keys are copied and thus must conform to the OFCopying protocol.
 *
 * @note Fast enumeration on a dictionary enumerates through the keys of the
 *	 dictionary.
 */
#ifdef OF_HAVE_GENERICS
@interface OFDictionary<KeyType, ObjectType>:
#else
# ifndef DOXYGEN
#  define KeyType id
#  define ObjectType id
@interface OFDictionary OF_GENERIC(KeyType, ObjectType): OFObject <OFCopying,
    OFMutableCopying, OFCollection, OFSerialization, OFJSONRepresentation,
    OFMessagePackRepresentation>
#if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN)
# define KeyType id
# define ObjectType id
# endif
@interface OFDictionary:
#endif
    OFObject <OFCopying, OFMutableCopying, OFCollection, OFSerialization,
    OFJSONRepresentation, OFMessagePackRepresentation>
/*!
 * @brief Creates a new OFDictionary.
 *
 * @return A new autoreleased OFDictionary
 */
+ (instancetype)dictionary;

301
302
303
304
305
306
307
308
309
310
311
312

313
314
315
316
317
318
319
320
321
297
298
299
300
301
302
303

304
305
306
307
308
309
310
311
312
313
314
315
316
317







-




+









 * @param block A block which determines if the object should be in the new
 *		dictionary
 * @return A new autoreleased OFDictionary
 */
- (OFDictionary OF_GENERIC(KeyType, ObjectType) *)filteredDictionaryUsingBlock:
    (of_dictionary_filter_block_t)block;
#endif
@end
#if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN)
# undef KeyType
# undef ObjectType
#endif
@end

OF_ASSUME_NONNULL_END

#import "OFMutableDictionary.h"

#if !defined(NSINTEGER_DEFINED) && !__has_feature(modules)
/* Required for dictionary literals to work */
@compatibility_alias NSDictionary OFDictionary;
#endif