Adopted Protocols
Tasks
Creating an Array
+ arrayWithContentsOfFile: --从文件中初始化数组
+ arrayWithObject: --只能初始化一个元素
+ arrayWithObjects: --初始化多个元素
Initializing an Array
Querying an Array
– containsObject: -- 是否包含字符串
– count --获取元素中的个数
– objectAtIndex: --访问数组中的某个元素
– getObjects: Deprecated in OS X v10.6
Finding Objects in an Array
Sending Messages to Elements
Comparing Arrays
Deriving New Arrays
– arrayByAddingObject: --追加数组的内容
Sorting
Working with String Elements
– componentsJoinedByString: -- 数组-->字符串
Creating a Description
Collecting Paths
Key-Value Observing
Key-Value Coding
NSMutableArray
Tasks
Creating and Initializing a Mutable Array
Adding Objects
Removing Objects
– removeObjectsFromIndices:numIndices: Deprecated in OS X v10.6
Replacing Objects
Filtering Content
Rearranging Content
本文出自 “8464349” 博客,请务必保留此出处http://8474349.blog.51cto.com/8464349/1364177