Adopted Protocols
Tasks
Creating a Dictionary
+ dictionary+ dictionaryWithContentsOfFile:+ dictionaryWithContentsOfURL:+ dictionaryWithDictionary:+ dictionaryWithObject:forKey:+ dictionaryWithObjects:forKeys:+ dictionaryWithObjects:forKeys:count:+ dictionaryWithObjectsAndKeys:
Initializing an NSDictionary Instance
– initWithContentsOfFile:– initWithContentsOfURL:– initWithDictionary:– initWithDictionary:copyItems:– initWithObjects:forKeys:– initWithObjects:forKeys:count:– initWithObjectsAndKeys:– init
Creating Key Sets for Shared-Key Optimized Dictionaries
Counting Entries
Comparing Dictionaries
Accessing Keys and Values
– allKeys– allKeysForObject:– allValues– getObjects:andKeys:– objectForKey:– objectForKeyedSubscript:– objectsForKeys:notFoundMarker:– valueForKey:
Enumerating Dictionaries
– keyEnumerator– objectEnumerator– enumerateKeysAndObjectsUsingBlock:– enumerateKeysAndObjectsWithOptions:usingBlock:
Sorting Dictionaries
– keysSortedByValueUsingSelector:– keysSortedByValueUsingComparator:– keysSortedByValueWithOptions:usingComparator:
Filtering Dictionaries
Storing Dictionaries
Accessing File Attributes
– fileCreationDate– fileExtensionHidden– fileGroupOwnerAccountID– fileGroupOwnerAccountName– fileHFSCreatorCode– fileHFSTypeCode– fileIsAppendOnly– fileIsImmutable– fileModificationDate– fileOwnerAccountID– fileOwnerAccountName– filePosixPermissions– fileSize– fileSystemFileNumber– fileSystemNumber– fileType
Creating a Description
– description– descriptionInStringsFileFormat– descriptionWithLocale:– descriptionWithLocale:indent:
NSMutableDictionary
Tasks
Creating and Initializing a Mutable Dictionary
Adding Entries to a Mutable Dictionary
– setObject:forKey:– setObject:forKeyedSubscript:– setValue:forKey:– addEntriesFromDictionary:– setDictionary:
NSDictionary与NSMutableDictionary详解
本文详细介绍了NSDictionary和NSMutableDictionary的使用方法,包括创建实例、初始化、添加和移除元素等操作,并提供了多种实用的方法来帮助开发者更好地管理和操作字典。
2556

被折叠的 条评论
为什么被折叠?



