NSArray< E > Class Reference

Inherits java::io::Serializable, com::webobjects::foundation::NSKeyValueCoding, com::webobjects::foundation::NSKeyValueCodingAdditions, com::webobjects::foundation::_NSFoundationCollection, and java::util::List<E>.

Inherited by NSMutableArray< E >.

Collaboration diagram for NSArray< E >:

Collaboration graph
[legend]

List of all members.

Classes

class  _AvgNumberOperator
class  _CountOperator
class  _MaxOperator
class  _MinOperator
class  _Operator
class  _SumNumberOperator
interface  Operator

Public Member Functions

int _shallowHashCode ()
boolean add (E element)
void add (int index, E element)
boolean addAll (int index, Collection<?extends E > collection)
boolean addAll (Collection<?extends E > collection)
NSArray< E > arrayByAddingObject (E object)
NSArray< E > arrayByAddingObjectsFromArray (NSArray<?extends E > otherArray)
ArrayList< E > arrayList ()
Class classForCoder ()
void clear ()
Object clone ()
String componentsJoinedByString (String separator)
boolean contains (Object element)
boolean containsAll (Collection<?> c)
boolean containsObject (Object object)
int count ()
void encodeWithCoder (NSCoder coder)
boolean equals (Object object)
firstObjectCommonWithArray (NSArray<?extends E > otherArray)
get (int index)
void getObjects (Object[] objects, NSRange range)
void getObjects (Object[] objects)
int hashCode ()
NSArray< E > immutableClone ()
int indexOf (Object element)
int indexOfIdenticalObject (Object object, NSRange range)
int indexOfIdenticalObject (Object object)
int indexOfObject (Object object, NSRange range)
int indexOfObject (Object object)
boolean isEmpty ()
boolean isEqualToArray (NSArray<?> otherArray)
Iterator< E > iterator ()
int lastIndexOf (Object element)
lastObject ()
ListIterator< E > listIterator (int index)
ListIterator< E > listIterator ()
void makeObjectsPerformSelector (NSSelector selector, Object...parameters)
NSMutableArray< E > mutableClone ()
 NSArray (Vector<?extends E > vector, NSRange range, boolean ignoreNull)
 NSArray (List<?extends E > list, NSRange range, boolean ignoreNull)
 NSArray (Collection<?extends E > collection)
 NSArray (Collection<?extends E > collection, boolean checkForNull)
 NSArray (List<?extends E > list, boolean checkForNull)
 NSArray (NSArray<?extends E > otherArray)
 NSArray (E[] objects, NSRange range)
 NSArray (E object, E...objects)
 NSArray (E[] objects)
 NSArray (E object)
 NSArray ()
objectAtIndex (int index)
Enumeration< E > objectEnumerator ()
Object[] objects (NSRange range)
Object[] objects ()
boolean remove (Object object)
remove (int index)
boolean removeAll (Collection<?> collection)
boolean retainAll (Collection<?> collection)
Enumeration< E > reverseObjectEnumerator ()
set (int index, E element)
int size ()
NSArray< E > sortedArrayUsingComparator (NSComparator comparator) throws NSComparator.ComparisonException
NSArray sortedArrayUsingSelector (NSSelector selector) throws NSComparator.ComparisonException
NSArray< E > subarrayWithRange (NSRange range)
List< E > subList (int fromIndex, int toIndex)
void takeValueForKey (Object value, String key)
void takeValueForKeyPath (Object value, String keyPath)
Object[] toArray ()
String toString ()
Object valueForKey (String key)
Object valueForKeyPath (String keyPath)
Vector< E > vector ()

Static Public Member Functions

static NSMutableArray< String_mutableComponentsSeparatedByString (String string, String separator)
static NSArray< StringcomponentsSeparatedByString (String string, String separator)
static Object decodeObject (NSCoder coder)
static final< T > NSArray< T > emptyArray ()
static Operator operatorForKey (String operatorName)
static NSArray< StringoperatorNames ()
static void removeOperatorForKey (String operatorName)
static void setOperatorForKey (String operatorName, Operator arrayOperator)

Static Public Attributes

static final Class _CLASS = _NSUtilitiesExtra._classWithFullySpecifiedNamePrime("com.webobjects.foundation.NSArray")
static final String AverageOperatorName = "avg"
static final boolean CheckForNull = true
static final String CountOperatorName = "count"
static final NSArray EmptyArray = new NSArray<Object>()
static final boolean IgnoreNull = true
static final String MaximumOperatorName = "max"
static final String MinimumOperatorName = "min"
static final int NotFound = -1
static final String SumOperatorName = "sum"

Protected Member Functions

void _initializeWithCapacity (int capacity)
boolean _mustRecomputeHash ()
Object[] _objects ()
void _setCount (int count)
void _setMustRecomputeHash (boolean change)
void _setObjects (Object[] objects)
 NSArray (Object[] objects, int rangeLocation, int rangeLength, boolean checkForNull, boolean ignoreNull)
Object[] objectsNoCopy ()

Protected Attributes

transient int _hashCache
Object[] _objects

Static Protected Attributes

static final int _NSArrayClassHashCode = _CLASS.hashCode()

Package Functions

public< T > T[] toArray (T[] objects)

Static Package Functions

 [static initializer]

Static Package Attributes

static final long serialVersionUID = -3789592578296478260L

Private Member Functions

boolean _equalsArray (NSArray<?> otherArray)
final int _findObjectInArray (int index, int length, Object object, boolean identical)
Object _valueForKeyPathWithOperator (String keyPath)
void initFromList (List<?extends E > list, int rangeLocation, int rangeLength, int offset, boolean checkForNull, boolean ignoreNull)
void initFromObjects (Object[] objects, int rangeLocation, int rangeLength, int offset, boolean checkForNull, boolean ignoreNull)
void initFromObjects (Object[] objects, int rangeLocation, int rangeLength, boolean checkForNull, boolean ignoreNull)
void readObject (ObjectInputStream s) throws IOException, ClassNotFoundException
Object readResolve () throws ObjectStreamException
void writeObject (ObjectOutputStream s) throws IOException

Private Attributes

transient boolean _recomputeHashCode = true

Static Private Attributes

static final char _OperatorIndicatorChar = '@'
static NSMutableDictionary
< String, Operator > 
_operators = new NSMutableDictionary<String, Operator>(8)
static final String SerializationValuesFieldKey = "objects"
static final ObjectStreamField[] serialPersistentFields = { new ObjectStreamField(SerializationValuesFieldKey, ((Object) (new Object[0])).getClass()) }


Detailed Description

NSArray re-implementation to support JDK 1.5 templates. Use with
 NSArray<Bug> bugs = ds.fetchObjects();

 for(Bug : bugs) {
 	  ...
 }

Parameters:
&lt;E&gt; type of array contents

Constructor & Destructor Documentation

NSArray (  ) 

NSArray ( object  ) 

NSArray ( Object[]  objects,
int  rangeLocation,
int  rangeLength,
boolean  checkForNull,
boolean  ignoreNull 
) [protected]

NSArray ( E[]  objects  ) 

NSArray ( object,
E...  objects 
)

NSArray ( E[]  objects,
NSRange  range 
)

NSArray ( NSArray<?extends E >  otherArray  ) 

NSArray ( List<?extends E >  list,
boolean  checkForNull 
)

NSArray ( Collection<?extends E >  collection,
boolean  checkForNull 
)

NSArray ( Collection<?extends E >  collection  ) 

NSArray ( List<?extends E >  list,
NSRange  range,
boolean  ignoreNull 
)

NSArray ( Vector<?extends E >  vector,
NSRange  range,
boolean  ignoreNull 
)


Member Function Documentation

[static initializer] (  )  [static, package]

boolean _equalsArray ( NSArray<?>  otherArray  )  [private]

final int _findObjectInArray ( int  index,
int  length,
Object  object,
boolean  identical 
) [private]

void _initializeWithCapacity ( int  capacity  )  [protected]

Reimplemented in NSMutableArray< E >.

boolean _mustRecomputeHash (  )  [protected]

static NSMutableArray<String> _mutableComponentsSeparatedByString ( String  string,
String  separator 
) [static]

Object [] _objects (  )  [protected]

void _setCount ( int  count  )  [protected]

Reimplemented in NSMutableArray< E >.

void _setMustRecomputeHash ( boolean  change  )  [protected]

void _setObjects ( Object[]  objects  )  [protected]

int _shallowHashCode (  ) 

Object _valueForKeyPathWithOperator ( String  keyPath  )  [private]

boolean add ( element  ) 

Reimplemented in NSMutableArray< E >, and SubList< E >.

void add ( int  index,
element 
)

Reimplemented in NSMutableArray< E >, and SubList< E >.

boolean addAll ( int  index,
Collection<?extends E >  collection 
)

Reimplemented in NSMutableArray< E >, and SubList< E >.

boolean addAll ( Collection<?extends E >  collection  ) 

Reimplemented in NSMutableArray< E >, and SubList< E >.

NSArray<E> arrayByAddingObject ( object  ) 

NSArray<E> arrayByAddingObjectsFromArray ( NSArray<?extends E >  otherArray  ) 

ArrayList<E> arrayList (  ) 

Class classForCoder (  ) 

void clear (  ) 

Reimplemented in NSMutableArray< E >.

Object clone (  ) 

Reimplemented in NSMutableArray< E >.

String componentsJoinedByString ( String  separator  ) 

static NSArray<String> componentsSeparatedByString ( String  string,
String  separator 
) [static]

boolean contains ( Object  element  ) 

boolean containsAll ( Collection<?>  c  ) 

boolean containsObject ( Object  object  ) 

int count (  ) 

Reimplemented in NSMutableArray< E >.

static Object decodeObject ( NSCoder  coder  )  [static]

static final<T> NSArray<T> emptyArray (  )  [static]

void encodeWithCoder ( NSCoder  coder  ) 

boolean equals ( Object  object  ) 

E firstObjectCommonWithArray ( NSArray<?extends E >  otherArray  ) 

E get ( int  index  ) 

Reimplemented in SubList< E >.

void getObjects ( Object[]  objects,
NSRange  range 
)

Deprecated:
Method getObjects is deprecated

void getObjects ( Object[]  objects  ) 

Deprecated:
Method getObjects is deprecated

int hashCode (  ) 

NSArray<E> immutableClone (  ) 

Reimplemented in NSMutableArray< E >.

int indexOf ( Object  element  ) 

int indexOfIdenticalObject ( Object  object,
NSRange  range 
)

int indexOfIdenticalObject ( Object  object  ) 

int indexOfObject ( Object  object,
NSRange  range 
)

int indexOfObject ( Object  object  ) 

void initFromList ( List<?extends E >  list,
int  rangeLocation,
int  rangeLength,
int  offset,
boolean  checkForNull,
boolean  ignoreNull 
) [private]

void initFromObjects ( Object[]  objects,
int  rangeLocation,
int  rangeLength,
int  offset,
boolean  checkForNull,
boolean  ignoreNull 
) [private]

void initFromObjects ( Object[]  objects,
int  rangeLocation,
int  rangeLength,
boolean  checkForNull,
boolean  ignoreNull 
) [private]

boolean isEmpty (  ) 

boolean isEqualToArray ( NSArray<?>  otherArray  ) 

Iterator<E> iterator (  ) 

Reimplemented in NSMutableArray< E >, and SubList< E >.

int lastIndexOf ( Object  element  ) 

E lastObject (  ) 

ListIterator<E> listIterator ( int  index  ) 

ListIterator<E> listIterator (  ) 

Reimplemented in NSMutableArray< E >.

void makeObjectsPerformSelector ( NSSelector  selector,
Object...  parameters 
)

NSMutableArray<E> mutableClone (  ) 

Reimplemented in NSMutableArray< E >.

E objectAtIndex ( int  index  ) 

Enumeration<E> objectEnumerator (  ) 

Object [] objects ( NSRange  range  ) 

Object [] objects (  ) 

Object [] objectsNoCopy (  )  [protected]

Reimplemented in NSMutableArray< E >.

static Operator operatorForKey ( String  operatorName  )  [static]

static NSArray<String> operatorNames (  )  [static]

void readObject ( ObjectInputStream  s  )  throws IOException, ClassNotFoundException [private]

Object readResolve (  )  throws ObjectStreamException [private]

boolean remove ( Object  object  ) 

Reimplemented in NSMutableArray< E >, and SubList< E >.

E remove ( int  index  ) 

Reimplemented in NSMutableArray< E >, and SubList< E >.

boolean removeAll ( Collection<?>  collection  ) 

Reimplemented in NSMutableArray< E >.

static void removeOperatorForKey ( String  operatorName  )  [static]

boolean retainAll ( Collection<?>  collection  ) 

Reimplemented in NSMutableArray< E >.

Enumeration<E> reverseObjectEnumerator (  ) 

E set ( int  index,
element 
)

Reimplemented in NSMutableArray< E >, and SubList< E >.

static void setOperatorForKey ( String  operatorName,
Operator  arrayOperator 
) [static]

int size (  ) 

Reimplemented in SubList< E >.

NSArray<E> sortedArrayUsingComparator ( NSComparator  comparator  )  throws NSComparator.ComparisonException

NSArray sortedArrayUsingSelector ( NSSelector  selector  )  throws NSComparator.ComparisonException

Deprecated:
Method sortedArrayUsingSelector is deprecated

NSArray<E> subarrayWithRange ( NSRange  range  ) 

List<E> subList ( int  fromIndex,
int  toIndex 
)

void takeValueForKey ( Object  value,
String  key 
)

void takeValueForKeyPath ( Object  value,
String  keyPath 
)

public<T> T [] toArray ( T[]  objects  )  [package]

Reimplemented in NSMutableArray< E >.

Object [] toArray (  ) 

String toString (  ) 

Object valueForKey ( String  key  ) 

Object valueForKeyPath ( String  keyPath  ) 

Vector<E> vector (  ) 

void writeObject ( ObjectOutputStream  s  )  throws IOException [private]


Member Data Documentation

final Class _CLASS = _NSUtilitiesExtra._classWithFullySpecifiedNamePrime("com.webobjects.foundation.NSArray") [static]

Reimplemented in NSMutableArray< E >.

transient int _hashCache [protected]

final int _NSArrayClassHashCode = _CLASS.hashCode() [static, protected]

Object [] _objects [protected]

final char _OperatorIndicatorChar = '@' [static, private]

NSMutableDictionary<String, Operator> _operators = new NSMutableDictionary<String, Operator>(8) [static, private]

transient boolean _recomputeHashCode = true [private]

final String AverageOperatorName = "avg" [static]

final boolean CheckForNull = true [static]

final String CountOperatorName = "count" [static]

final NSArray EmptyArray = new NSArray<Object>() [static]

final boolean IgnoreNull = true [static]

final String MaximumOperatorName = "max" [static]

final String MinimumOperatorName = "min" [static]

final int NotFound = -1 [static]

final String SerializationValuesFieldKey = "objects" [static, private]

final ObjectStreamField [] serialPersistentFields = { new ObjectStreamField(SerializationValuesFieldKey, ((Object) (new Object[0])).getClass()) } [static, private]

final long serialVersionUID = -3789592578296478260L [static, package]

Reimplemented in NSMutableArray< E >.

final String SumOperatorName = "sum" [static]


The documentation for this class was generated from the following file:

Generated on Sat May 26 06:42:32 2012 for Project Wonder by  doxygen 1.5.8