Packageorg.as3collections.utils
Classpublic class ListUtil
InheritanceListUtil Inheritance Object

A utility class to work with implementations of the IList interface.



Public Methods
 MethodDefined By
  
ListUtil is a static class and shouldn't be instantiated.
ListUtil
  
getTypedList(wrapList:IList, type:*):TypedList
[static] Returns a new TypedList with the wrapList argument wrapped.
ListUtil
  
[static] Returns a new TypedSortedList with the wrapList argument wrapped.
ListUtil
  
[static] Returns a new UniqueList with the wrapList argument wrapped.
ListUtil
  
[static] Returns a new UniqueSortedList with the wrapList argument wrapped.
ListUtil
  
[static] Returns a new TypedList that wraps a new UniqueList that wraps the wrapList argument.
ListUtil
  
[static] Returns a new TypedSortedList that wraps a new UniqueSortedList that wraps the wrapList argument.
ListUtil
Constructor Detail
ListUtil()Constructor
public function ListUtil()

ListUtil is a static class and shouldn't be instantiated.


Throws
IllegalOperationError ListUtil is a static class and shouldn't be instantiated.
Method Detail
getTypedList()method
public static function getTypedList(wrapList:IList, type:*):TypedList

Returns a new TypedList with the wrapList argument wrapped.

Parameters

wrapList:IList — the target list to be wrapped by the TypedList.
 
type:* — the type of the elements allowed by the returned TypedList.

Returns
TypedList — a new TypedList with the wrapList argument wrapped.

Throws
ArgumentError — if the wrapList argument is null.
 
ArgumentError — if the type argument is null.
 
org.as3coreaddendum.errors:ClassCastError — if the types of one or more elements in the wrapList argument are incompatible with the type argument.
getTypedSortedList()method 
public static function getTypedSortedList(wrapList:ISortedList, type:*):TypedSortedList

Returns a new TypedSortedList with the wrapList argument wrapped.

Parameters

wrapList:ISortedList — the target list to be wrapped by the TypedSortedList.
 
type:* — the type of the elements allowed by the returned TypedSortedList.

Returns
TypedSortedList — a new TypedSortedList with the wrapList argument wrapped.

Throws
ArgumentError — if the wrapList argument is null.
 
ArgumentError — if the type argument is null.
 
org.as3coreaddendum.errors:ClassCastError — if the types of one or more elements in the wrapList argument are incompatible with the type argument.
getUniqueList()method 
public static function getUniqueList(wrapList:IList):UniqueList

Returns a new UniqueList with the wrapList argument wrapped.

Parameters

wrapList:IList — the target list to be wrapped by the UniqueList.

Returns
UniqueList — a new UniqueList with the wrapList argument wrapped.

Throws
ArgumentError — if the wrapList argument is null.
getUniqueSortedList()method 
public static function getUniqueSortedList(wrapList:ISortedList):UniqueSortedList

Returns a new UniqueSortedList with the wrapList argument wrapped.

Parameters

wrapList:ISortedList — the target list to be wrapped by the UniqueSortedList.

Returns
UniqueSortedList — a new UniqueSortedList with the wrapList argument wrapped.

Throws
ArgumentError — if the wrapList argument is null.
getUniqueTypedList()method 
public static function getUniqueTypedList(wrapList:IList, type:*):TypedList

Returns a new TypedList that wraps a new UniqueList that wraps the wrapList argument.

The result will be a unique and typed array list, despite of the return type TypedList.

Parameters

wrapList:IList — the target list to be wrapped.
 
type:* — the type of the elements allowed by the returned TypedList.

Returns
TypedList — a new TypedList that wraps a new UniqueList that wraps the wrapList argument.

Throws
ArgumentError — if the wrapList argument is null.
 
ArgumentError — if the type argument is null.
 
org.as3coreaddendum.errors:ClassCastError — if the types of one or more elements in the wrapList argument are incompatible with the type argument.
getUniqueTypedSortedList()method 
public static function getUniqueTypedSortedList(wrapList:ISortedList, type:*):TypedSortedList

Returns a new TypedSortedList that wraps a new UniqueSortedList that wraps the wrapList argument.

The result will be a unique and typed sorted list, despite of the return type TypedSortedList.

Parameters

wrapList:ISortedList — the target list to be wrapped.
 
type:* — the type of the elements allowed by the returned TypedSortedList.

Returns
TypedSortedList — a new TypedSortedList that wraps a new UniqueSortedList that wraps the wrapList argument.

Throws
ArgumentError — if the wrapList argument is null.
 
ArgumentError — if the type argument is null.
 
org.as3coreaddendum.errors:ClassCastError — if the types of one or more elements in the wrapList argument are incompatible with the type argument.