# Package net.sf.saxon.ma.arrays

This package implements arrays, as introduced in XPath/XQuery 3.1: arrays provide a list-like data structure that (unlike sequences) allows nesting.

Arrays are immutable, so that adding a new entry to an array creates a new array.

The entries in a array are arbitrary XDM sequences.

There are functions (each supported by its own implementation class) to create a new array, to add an entry to a array, to get an entry from an array, to get the size of an array, and so on..

- Interface Summary
  Interface | Description
  --- | ---
  ArrayItem | Interface supported by different implementations of an XDM array item

- Class Summary
  Class | Description
  --- | ---
  AbstractArrayItem | An abstract implementation of XDM array items, containing methods that can be implemented generically.
  ArrayFunctionSet | Function signatures (and pointers to implementations) of the functions defined in XPath 2.0
  ArrayFunctionSet.ArrayAppend | Implementation of the function array:append(array, item()*) => array
  ArrayFunctionSet.ArrayFilter | Implementation of the function array:filter(array, function) => array
  ArrayFunctionSet.ArrayFlatten | Implementation of the function array:flatten => item()*
  ArrayFunctionSet.ArrayFoldLeft | Implementation of the function array:fold-left(array, item()*, function) => array
  ArrayFunctionSet.ArrayFoldRight | Implementation of the function array:fold-left(array, item()*, function) => array
  ArrayFunctionSet.ArrayForEach | Implementation of the function array:for-each(array, function) => array
  ArrayFunctionSet.ArrayForEachPair | Implementation of the function array:for-each-pair(array, array, function) => array
  ArrayFunctionSet.ArrayFromSequence | Implementation of the function array:_from-sequence(item()*) => array(*) which is used internally for the implementation of array{} and of the saxon:array extension
  ArrayFunctionSet.ArrayGet | Implementation of the function array:get(array, xs:integer) => item()*
  ArrayFunctionSet.ArrayHead | Implementation of the function array:head(array) => item()*
  ArrayFunctionSet.ArrayInsertBefore | Implementation of the function array:insert-before(array, xs:integer, item()*) => array
  ArrayFunctionSet.ArrayJoin | Implementation of the function array:join(arrays) => array
  ArrayFunctionSet.ArrayPut | Implementation of the function array:put(arrays, index, newValue) => array
  ArrayFunctionSet.ArrayRemove | Implementation of the function array:remove(array, xs:integer) => array
  ArrayFunctionSet.ArrayReverse | Implementation of the function array:reverse(array, xs:integer, xs:integer) => array
  ArrayFunctionSet.ArraySize | Implementation of the function array:size(array) => integer
  ArrayFunctionSet.ArraySubarray | Implementation of the function array:subarray(array, xs:integer, xs:integer) => array
  ArrayFunctionSet.ArrayTail | Implementation of the function array:tail(array) => item()*
  ArrayFunctionSet.ArrayToSequence | Implementation of the function array:_to-sequence(array) => item()* which is used internally for the implementation of array?*
  ArrayItemType | An instance of this class represents a specific array item type, for example function(xs:int) as xs:boolean
  ArraySort | Implementation of the extension function array:sort(array, function) => array
  ImmutableArrayItem | Implementation of ArrayItem backed by a persistent immutable array, so that operations that "update" the array do not have to copy the whole array
  SimpleArrayItem | A simple implementation of XDM array items, in which the array is backed by a Java List.
  SquareArrayConstructor | An expression that delivers a fixed size array whose members are the result of evaluating corresponding expressions: [a,b,c,d]