What is the difference between these two NSArray methods?
+5
A:
indexOfObjectIdenticalTo checks for the exact same id (same address). indexOfObject checks that isEqual returns YES.
Matthew Flaschen
2010-07-02 17:30:15
+3
A:
The first uses isEqual: to find a matching object, while the second looks for the same object (i.e., the object at the same memory location).
Marcelo Cantos
2010-07-02 17:31:40