|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.wotonomy.foundation.NSArray net.wotonomy.foundation.NSMutableArray
public class NSMutableArray
NSMutableArray extends NSArray to allow modification.
Field Summary |
---|
Fields inherited from class net.wotonomy.foundation.NSArray |
---|
EmptyArray, NotFound |
Constructor Summary | |
---|---|
NSMutableArray()
Default constructor returns an empty array. |
|
NSMutableArray(java.util.Collection aCollection)
Produces an array containing the objects in the specified collection. |
|
NSMutableArray(int aSize)
Constructor with a size hint. |
|
NSMutableArray(java.lang.Object anObject)
Produces an array containing only the specified object. |
|
NSMutableArray(java.lang.Object[] anArray)
Produces an array containing the specified objects. |
Method Summary | |
---|---|
void |
add(int index,
java.lang.Object element)
|
boolean |
add(java.lang.Object o)
|
boolean |
addAll(java.util.Collection coll)
|
boolean |
addAll(int index,
java.util.Collection c)
|
void |
addObject(java.lang.Object anObject)
Adds the specified object to the end of this array. |
void |
addObjectsFromArray(java.util.Collection aCollection)
Adds all objects in the specified collection. |
void |
clear()
|
java.lang.Object |
clone()
|
NSArray |
immutableClone()
|
void |
insertObjectAtIndex(java.lang.Object anObject,
int anIndex)
Inserts the specified object into this array at the specified index. |
java.util.Iterator |
iterator()
|
java.util.ListIterator |
listIterator()
|
java.util.ListIterator |
listIterator(int index)
|
static NSMutableArray |
mutableArrayBackedByList(java.util.List aList)
Returns an NSArray backed by the specified List. |
NSMutableArray |
mutableClone()
|
java.lang.Object |
remove(int index)
|
boolean |
remove(java.lang.Object o)
|
boolean |
removeAll(java.util.Collection coll)
|
void |
removeAllObjects()
Removes all objects from the array. |
void |
removeIdenticalObject(java.lang.Object anObject)
Removes all occurences of the specified object, comparing by reference. |
void |
removeIdenticalObject(java.lang.Object anObject,
NSRange aRange)
Removes all instances of the specified object within the range of specified indices, comparing by reference. |
void |
removeLastObject()
Removes the last object from the array. |
void |
removeObject(java.lang.Object anObject)
Removes all objects equivalent to the specified object. |
void |
removeObject(java.lang.Object anObject,
NSRange aRange)
Removes all objects equivalent to the specified object within the range of specified indices. |
void |
removeObjectAtIndex(int index)
Removes the object at the specified index. |
void |
removeObjectsInArray(java.util.Collection aCollection)
Removes all objects in the specified collection from the array. |
void |
removeObjectsInRange(NSRange aRange)
Removes all objects in the indices within the specified range from the array. |
void |
replaceObjectAtIndex(int anIndex,
java.lang.Object anObject)
Replaces the object at the specified index with the specified object. |
void |
replaceObjectsInRange(NSRange currentRange,
java.util.List otherArray,
NSRange otherRange)
Replaces objects in the current range with objects from the specified range of the specified array. |
boolean |
retainAll(java.util.Collection coll)
|
java.lang.Object |
set(int index,
java.lang.Object element)
|
void |
setArray(java.util.Collection aCollection)
Clears the current array and then populates it with the contents of the specified collection. |
void |
sortUsingSelector(NSSelector aSelector)
Sorts this array using the values from the specified selector. |
java.util.List |
subList(int fromIndex,
int toIndex)
|
Methods inherited from class net.wotonomy.foundation.NSArray |
---|
arrayBackedByList, arrayByAddingObject, arrayByAddingObjectsFromArray, componentsJoinedByString, componentsSeparatedByString, contains, containsAll, containsObject, count, equals, firstObjectCommonWithArray, get, getObjects, getObjects, hashCode, indexOf, indexOfIdenticalObject, indexOfIdenticalObject, indexOfObject, indexOfObject, isEmpty, isEqualToArray, lastIndexOf, lastObject, objectAtIndex, objectEnumerator, protectedAdd, protectedAddAll, reverseObjectEnumerator, size, subarrayWithRange, toArray, toArray, toString |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public NSMutableArray()
public NSMutableArray(int aSize)
public NSMutableArray(java.lang.Object anObject)
public NSMutableArray(java.lang.Object[] anArray)
public NSMutableArray(java.util.Collection aCollection)
Method Detail |
---|
public static NSMutableArray mutableArrayBackedByList(java.util.List aList)
public void removeLastObject()
public void removeObjectAtIndex(int index)
public void addObjectsFromArray(java.util.Collection aCollection)
public void removeAllObjects()
public void removeObject(java.lang.Object anObject, NSRange aRange)
public void removeIdenticalObject(java.lang.Object anObject, NSRange aRange)
public void removeObjectsInArray(java.util.Collection aCollection)
public void removeObjectsInRange(NSRange aRange)
public void replaceObjectsInRange(NSRange currentRange, java.util.List otherArray, NSRange otherRange)
public void setArray(java.util.Collection aCollection)
public void sortUsingSelector(NSSelector aSelector)
public void removeObject(java.lang.Object anObject)
public void removeIdenticalObject(java.lang.Object anObject)
public void insertObjectAtIndex(java.lang.Object anObject, int anIndex)
public void replaceObjectAtIndex(int anIndex, java.lang.Object anObject)
public void addObject(java.lang.Object anObject)
public java.lang.Object clone()
clone
in class NSArray
public NSArray immutableClone()
immutableClone
in class NSArray
public NSMutableArray mutableClone()
mutableClone
in class NSArray
public void add(int index, java.lang.Object element)
add
in interface java.util.List
add
in class NSArray
public boolean add(java.lang.Object o)
add
in interface java.util.Collection
add
in interface java.util.List
add
in class NSArray
public boolean addAll(java.util.Collection coll)
addAll
in interface java.util.Collection
addAll
in interface java.util.List
addAll
in class NSArray
public boolean addAll(int index, java.util.Collection c)
addAll
in interface java.util.List
addAll
in class NSArray
public void clear()
clear
in interface java.util.Collection
clear
in interface java.util.List
clear
in class NSArray
public java.util.Iterator iterator()
iterator
in interface java.lang.Iterable
iterator
in interface java.util.Collection
iterator
in interface java.util.List
iterator
in class NSArray
public java.util.ListIterator listIterator()
listIterator
in interface java.util.List
listIterator
in class NSArray
public java.util.ListIterator listIterator(int index)
listIterator
in interface java.util.List
listIterator
in class NSArray
public java.lang.Object remove(int index)
remove
in interface java.util.List
remove
in class NSArray
public boolean remove(java.lang.Object o)
remove
in interface java.util.Collection
remove
in interface java.util.List
remove
in class NSArray
public boolean removeAll(java.util.Collection coll)
removeAll
in interface java.util.Collection
removeAll
in interface java.util.List
removeAll
in class NSArray
public boolean retainAll(java.util.Collection coll)
retainAll
in interface java.util.Collection
retainAll
in interface java.util.List
retainAll
in class NSArray
public java.lang.Object set(int index, java.lang.Object element)
set
in interface java.util.List
set
in class NSArray
public java.util.List subList(int fromIndex, int toIndex)
subList
in interface java.util.List
subList
in class NSArray
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |