| Modifier and Type | Field and Description |
|---|---|
| private NSObject[] |
| Access | Constructor and Description |
|---|---|
| public | NSArray(int
The number of elements the NSArray instance will be able to hold. length)Creates a new NSArray instance of the specified size. |
| public |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv void | assignIDs(BinaryPropertyListWriter out)
Overrides com. Assigns IDs to all the objects in this NSObject subtree. |
| public NSArray | clone()
Implements abstract com. Creates and returns a deep copy of this instance. |
| public int | compareTo(NSObject o)
Implements java. Compares this object with the specified object for order. |
| public boolean | Returns: true, when the object could be found. false otherwise.The object to look for. obj)Checks whether an object is present in the array or whether it is equal to any of the objects in the array. |
| public int | |
| public boolean | equals(Object obj)
Overrides java. Indicates whether some other object is "equal to" this one. |
| public NSObject[] | Returns: The actual array represented by this NSArray.Returns the array of NSObjects represented by this NSArray. |
| public int | |
| public int | Returns: The index of the object, if it was found. -1 otherwise.The object to look for. obj)Searches for a specific object in the array. |
| public int | Returns: The index of the object, if it was found. -1 otherwise.The object to look for. obj)Searches for an object in the array. |
| public NSObject | Returns: The value of the highest index in the array.Returns the last object contained in this array. |
| public NSObject | Returns: The object at the given index.The index of the object. i)Returns the object stored at the given index. |
| public NSObject[] | Returns: The new array containing the objects stored at the given indices.The indices of the objects. indexes)Returns a new array containing only the values stored at the given indices. |
| public void | |
| public void | |
| protected void | toASCII(StringBuilder ascii, int level)
Implements abstract com. Generates the ASCII representation of this object. |
| private void | |
| protected void | toASCIIGnuStep(StringBuilder ascii, int level)
Implements abstract com. Generates the ASCII representation of this object in the GnuStep format. |
| public String | Returns: ASCII representation of this object.Generates a valid ASCII property list which has this NSArray as its root object. |
| pack-priv void | toBinary(BinaryPropertyListWriter out)
Implements abstract com. Generates the binary representation of the object. |
| public String | Returns: GnuStep ASCII representation of this object.Generates a valid ASCII property list in GnuStep format which has this NSArray as its root object. |
| public Object | toJavaObject()
Implements abstract com. Converts this NSObject into an equivalent object of the Java Runtime Environment. |
| pack-priv void | toXML(StringBuilder xml, int level)
Implements abstract com. Generates the XML representation of the object (without XML headers or enclosing plist-tags). |
| array | back to summary |
|---|---|
| private NSObject[] array | |
| NSArray | back to summary |
|---|---|
| public NSArray(int length) Creates a new NSArray instance of the specified size.
| |
| NSArray | back to summary |
|---|---|
| public NSArray(NSObject... a) Creates a new NSArray instance containing the specified elements.
| |
| assignIDs | back to summary |
|---|---|
| pack-priv void assignIDs(BinaryPropertyListWriter out) Overrides com. Doc from com. Assigns IDs to all the objects in this NSObject subtree.
| |
| clone | back to summary |
|---|---|
| public NSArray clone() Implements abstract com. Doc from com. Creates and returns a deep copy of this instance.
| |
| compareTo | back to summary |
|---|---|
| public int compareTo(NSObject o) Implements java. Doc from java. Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object. The implementor must ensure The implementor must also ensure that the relation is transitive:
Finally, the implementor must ensure that
| |
| containsObject | back to summary |
|---|---|
| public boolean containsObject(Object obj) Checks whether an object is present in the array or whether it is equal to any of the objects in the array.
| |
| count | back to summary |
|---|---|
| public int count() Returns the size of the array.
| |
| equals | back to summary |
|---|---|
| public boolean equals(Object obj) Overrides java. Doc from java. Indicates whether some other object is "equal to" this one.
The
An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes.
| |
| getArray | back to summary |
|---|---|
| public NSObject[] getArray() Returns the array of NSObjects represented by this NSArray. Any changes to the values of this array will also affect the NSArray.
| |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |
| indexOfIdenticalObject | back to summary |
|---|---|
| public int indexOfIdenticalObject(Object obj) Searches for a specific object in the array. If the specified object is found (reference equality), its index is returned. Otherwise, -1 is returned.
| |
| indexOfObject | back to summary |
|---|---|
| public int indexOfObject(Object obj) Searches for an object in the array. If the specified object or an object equal to it is found, its index is returned. Otherwise, -1 is returned.
| |
| lastObject | back to summary |
|---|---|
| public NSObject lastObject() Returns the last object contained in this array.
Equivalent to
| |
| objectAtIndex | back to summary |
|---|---|
| public NSObject objectAtIndex(int i) Returns the object stored at the given index.
Equivalent to
| |
| objectsAtIndexes | back to summary |
|---|---|
| public NSObject[] objectsAtIndexes(int... indexes) Returns a new array containing only the values stored at the given indices. The values are sorted by their index.
| |
| remove | back to summary |
|---|---|
| public void remove(int i) Removes the i-th element from the array. The array will be resized.
| |
| setValue | back to summary |
|---|---|
| public void setValue(int key, Object value) Stores an object at the specified index.
If there was another object stored at that index it will be replaced.
Equivalent to
| |
| toASCII | back to summary |
|---|---|
| protected void toASCII(StringBuilder ascii, int level) Implements abstract com. Doc from com. Generates the ASCII representation of this object. The generated ASCII representation does not end with a newline. Complies with the Old-Style ASCII Property Lists definition.
| |
| toASCII | back to summary |
|---|---|
| private void toASCII(StringBuilder ascii, int level, boolean gnustep) | |
| toASCIIGnuStep | back to summary |
|---|---|
| protected void toASCIIGnuStep(StringBuilder ascii, int level) Implements abstract com. Doc from com. Generates the ASCII representation of this object in the GnuStep format. The generated ASCII representation does not end with a newline.
| |
| toASCIIPropertyList | back to summary |
|---|---|
| public String toASCIIPropertyList() Generates a valid ASCII property list which has this NSArray as its root object. The generated property list complies with the format as described in Property List Programming Guide - Old-Style ASCII Property Lists.
| |
| toBinary | back to summary |
|---|---|
| pack-priv void toBinary(BinaryPropertyListWriter out) throws IOException Implements abstract com. Doc from com. Generates the binary representation of the object.
| |
| toGnuStepASCIIPropertyList | back to summary |
|---|---|
| public String toGnuStepASCIIPropertyList() Generates a valid ASCII property list in GnuStep format which has this NSArray as its root object. The generated property list complies with the format as described in GnuStep - NSPropertyListSerialization class documentation
| |
| toJavaObject | back to summary |
|---|---|
| public Object toJavaObject() Implements abstract com. Doc from com. Converts this NSObject into an equivalent object of the Java Runtime Environment.
| |
| toXML | back to summary |
|---|---|
| pack-priv void toXML(StringBuilder xml, int level) Implements abstract com. Doc from com. Generates the XML representation of the object (without XML headers or enclosing plist-tags).
| |