ResizeArray Module
The main module for functions on ResizeArray. A ResizeArray is a System.Collections.Generic.List<'T>. This module has all functions from the FSharp.Core.Array module implemented for ResizeArray. And more.
Nested modules
Modules | Description |
Parallel operations on ResizeArray using Threading.Tasks.Parallel.For The API is aligned with from FSharp.Core.Array.Parallel module |
Functions and values
Function or value |
Description
|
||
Full Usage:
add item resizeArray
Parameters:
'T
resizeArray : ResizeArray<'T>
Modifiers: inline Type parameters: 'T |
Adds an object to the end of the ResizeArray.
|
||
Full Usage:
allPairs resizeArray1 resizeArray2
Parameters:
ResizeArray<'T>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'U>
-
The second input ResizeArray.
Returns: ResizeArray<'T * 'U>
The resulting ResizeArray of pairs of length: resizeArray1.Count * resizeArray2.Count.
|
Returns a new ResizeArray that contains all pairings (or combinations) of elements from the first and second ResizeArrays.
|
||
Full Usage:
append resizeArray1 resizeArray2
Parameters:
ResizeArray<'T>
-
The input ResizeArray that will be at the beginning.
resizeArray2 : ResizeArray<'T>
-
The input ResizeArray that will be at the end.
Returns: List<'T>
The resulting ResizeArray of length: resizeArray1.Count + resizeArray2.Count..
Modifiers: inline Type parameters: 'T |
Builds a new ResizeArray that contains the elements of the first ResizeArray followed by the elements of the second ResizeArray. When used with the pipeline operator |> the first and only argument to this function with be at the start of the resulting list. This can be counter intuitive. Use the function ResizeArray.prepend instead to append the first argument at the end of the second argument.
|
||
Full Usage:
applyIfInputAndResult inputPredicate resultPredicate transform resizeArray
Parameters:
ResizeArray<'T> -> bool
resultPredicate : ResizeArray<'T> -> bool
transform : ResizeArray<'T> -> ResizeArray<'T>
resizeArray : ResizeArray<'T>
Returns: ResizeArray<'T>
Modifiers: inline Type parameters: 'T |
Applies a function to List if it meets the inputPredicate, otherwise just returns input. If resulting List meets the resultPredicate it is returned, otherwise original input is returned.
|
||
Full Usage:
applyIfResult resultPredicate transform resizeArray
Parameters:
ResizeArray<'T> -> bool
transform : ResizeArray<'T> -> ResizeArray<'T>
resizeArray : ResizeArray<'T>
Returns: ResizeArray<'T>
Modifiers: inline Type parameters: 'T |
Applies a function to List If resulting List meets the resultPredicate it is returned, otherwise the original input is returned.
|
||
Full Usage:
asArray resizeArray
Parameters:
ResizeArray<'T>
Returns: 'T[]
Modifiers: inline Type parameters: 'T |
Return a fixed-length Array containing the elements of the input ResizeArray as a copy. When this function is used in Fable (JavaScript) the ResizeArray is just casted to an Array. In .NET a new Array is still allocated and the elements are copied.
|
||
Full Usage:
average resizeArray
Parameters:
ResizeArray<^T>
-
The input ResizeArray.
Returns: ^T
The average of the elements in the ResizeArray.
Modifiers: inline Type parameters: ^T |
Returns the average of the elements in the ResizeArray.
|
||
Full Usage:
averageBy projection resizeArray
Parameters:
'T -> ^Key
-
The function to transform the ResizeArray elements before averaging.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ^Key
The computed average.
Modifiers: inline Type parameters: 'T, ^Key |
Returns the average of the elements generated by applying the function to each element of the ResizeArray.
|
||
Full Usage:
blit source sourceIndex target targetStartIndex count
Parameters:
ResizeArray<'T>
-
The source ResizeArray.
sourceIndex : int
-
The starting index of the source ResizeArray.
target : ResizeArray<'T>
-
The target ResizeArray.
targetStartIndex : int
-
The starting index of the target ResizeArray.
count : int
-
The number of elements to copy.
Modifiers: inline Type parameters: 'T |
Reads a range of elements from the first ResizeArray and write them into the second. The target ResizeArray must already have the required minimum size to fit targetStartIndex + count.
|
||
Full Usage:
blitExtend source sourceIndex target targetStartIndex count
Parameters:
ResizeArray<'T>
-
The source ResizeArray.
sourceIndex : int
-
The starting index of the source ResizeArray.
target : ResizeArray<'T>
-
The target ResizeArray.
targetStartIndex : int
-
The starting index of the target ResizeArray.
count : int
-
The number of elements to copy.
Modifiers: inline Type parameters: 'T |
Reads a range of elements from the first ResizeArray and write them into the second. The target ResizeArray increases in size if needed.
But it needs to have minimum
|
||
Full Usage:
choose chooser resizeArray
Parameters:
'T -> 'U option
-
The function to generate options from the elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'U>
The ResizeArray of results.
Modifiers: inline Type parameters: 'T, 'U |
Applies the given function to each element of the ResizeArray. Returns the ResizeArray comprised of the results "x" for each element where the function returns Some(x)
|
||
Full Usage:
chunkBySize chunkSize resizeArray
Parameters:
int
-
The maximum size of each chunk.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<ResizeArray<'T>>
The ResizeArray divided into chunks.
|
Divides the input ResizeArray into chunks of size at most
|
||
Full Usage:
clone resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: List<'T>
A copy of the input ResizeArray.
Modifiers: inline Type parameters: 'T |
Builds a new ResizeArray that contains the elements of the given ResizeArray. A shallow copy by calling resizeArray.GetRange(0,resizeArray.Count)
|
||
Full Usage:
collect mapping resizeArray
Parameters:
'T -> ResizeArray<'U>
-
The function to create sub-ResizeArrays from the input ResizeArray elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'U>
The concatenation of the sub-ResizeArrays.
|
For each element of the ResizeArray, applies the given function. Concatenates all the results and return the combined ResizeArray.
|
||
Full Usage:
compareWith comparer resizeArray1 resizeArray2
Parameters:
'T -> 'T -> int
-
A function that takes an element from each ResizeArray and returns an int.
If it evaluates to a non-zero value iteration is stopped and that value is returned.
resizeArray1 : ResizeArray<'T>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'T>
-
The second input ResizeArray.
Returns: int
Returns the first non-zero result from the comparison function. If the first ResizeArray has
a larger element, the return value is always positive. If the second ResizeArray has a larger
element, the return value is always negative. When the elements are equal in the two
ResizeArrays, 1 is returned if the first ResizeArray is longer, 0 is returned if they are equal in
length, and -1 is returned when the second ResizeArray is longer.
Modifiers: inline Type parameters: 'T |
Compares two ResizeArrays using the given comparison function, element by element.
|
||
Full Usage:
concat resizeArrays
Parameters:
ResizeArray<ResizeArray<'T>>
-
The input sequence of ResizeArrays.
Returns: ResizeArray<'T>
The concatenation of the sequence of input ResizeArrays.
|
Builds a new ResizeArray that contains the elements of each of the given sequence of sequences.
|
||
Full Usage:
contains value resizeArray
Parameters:
'T
-
The value to locate in the input ResizeArray.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: bool
true if the input ResizeArray contains the specified element; false otherwise.
Modifiers: inline Type parameters: 'T |
Tests if the ResizeArray contains the specified element.
|
||
Full Usage:
copy resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: List<'T>
A copy of the input ResizeArray.
Modifiers: inline Type parameters: 'T |
Builds a new ResizeArray that contains the elements of the given ResizeArray. A shallow copy by calling resizeArray.GetRange(0,resizeArray.Count)
|
||
Full Usage:
count resizeArray
Parameters:
ResizeArray<'T>
Returns: int
Modifiers: inline Type parameters: 'T |
Return the length or count of the collection. Same as ResizeArray.length
|
||
Full Usage:
countBy projection resizeArray
Parameters:
'T -> 'Key
-
A function transforming each item of the input ResizeArray into a key to be
compared against the others.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'Key * int>
The result ResizeArray.
|
Applies a key-generating function to each element of a ResizeArray and returns a ResizeArray yielding unique keys and their number of occurrences in the original ResizeArray.
|
||
Full Usage:
countIf predicate resizeArray
Parameters:
'T -> bool
resizeArray : ResizeArray<'T>
Returns: int
Modifiers: inline Type parameters: 'T |
Counts for how many items of the collection the predicate returns true. Same as ResizeArray.filter and then ResizeArray.length
|
||
Full Usage:
create count value
Parameters:
int
-
The length of the ResizeArray to create.
value : 'T
-
The value for the elements.
Returns: ResizeArray<'T>
The created ResizeArray.
|
Creates a ResizeArray whose elements are all initially the given value.
|
||
Full Usage:
distinct resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The result ResizeArray.
|
Returns a ResizeArray that contains no duplicate entries according to generic hash and equality comparisons on the entries. If an element occurs multiple times in the ResizeArray then the later occurrences are discarded.
|
||
Full Usage:
distinctBy projection resizeArray
Parameters:
'T -> 'Key
-
A function transforming the ResizeArray items into comparable keys.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The result ResizeArray.
|
Returns a ResizeArray that contains no duplicate entries according to the generic hash and equality comparisons on the keys returned by the given key-generating function. If an element occurs multiple times in the ResizeArray then the later occurrences are discarded.
|
||
|
Returns all elements that exists more than once in ResizeArray. Each element that exists more than once is only returned once. Returned order is by first occurrence of first duplicate.
|
||
Full Usage:
duplicatesBy f resizeArray
Parameters:
'T -> 'U
resizeArray : ResizeArray<'T>
Returns: List<'T>
|
Returns all elements that exists more than once in ResizeArray. Each element that exists more than once is only returned once. Returned order is by first occurrence of first duplicate.
|
||
Full Usage:
empty
Returns: ResizeArray<'T>
Modifiers: inline Type parameters: 'T |
Returns a new empty ResizeArray of the given type. With initial capacity zero. Upon adding the first element to the ResizeArray an internal Array of size 4 is allocated, and then increased in multiples of two as required.
|
||
Full Usage:
equals resizeArray1 resizeArray2
Parameters:
ResizeArray<'T>
resizeArray2 : ResizeArray<'T>
Returns: bool
Modifiers: inline Type parameters: 'T |
Shallow Structural equality comparison in .NET. Compares each element in both lists for equality. However nested ResizeArrays inside a ResizeArray are only compared for referential equality. (Like the default behavior of Collections.Generic.List) Raises ArgumentNullException if either list is null. When used in Fable (JavaScript) the ResizeArrays are always compared for full structural equality see https://github.com/fable-compiler/Fable/issues/3718 Use ResizeArray.equals2 or ResizeArray.equal3 for comparing nested ResizeArrays too.
|
||
Full Usage:
equals2 resizeArrays1 resizeArrays2
Parameters:
ResizeArray<ResizeArray<'T>>
resizeArrays2 : ResizeArray<ResizeArray<'T>>
Returns: bool
|
Structural equality comparison of ResizeArrays nested in ResizeArrays in .NET. Compares each element in each nested list for equality. So that two levels deep nested 'T are still compared for equality in .NET. Raises ArgumentNullException if either list is null. When used in Fable (JavaScript) the ResizeArrays are always compared for full structural equality see https://github.com/fable-compiler/Fable/issues/3718
|
||
Full Usage:
equals3 resizeArrays1 resizeArrays2
Parameters:
ResizeArray<ResizeArray<ResizeArray<'T>>>
resizeArrays2 : ResizeArray<ResizeArray<ResizeArray<'T>>>
Returns: bool
|
Structural equality comparison of ResizeArrays nested in ResizeArrays nested in ResizeArrays in .NET. Compares each element in each twice nested list for equality. So that three levels deep nested 'T are still compared for equality. Raises ArgumentNullException if either list is null. When used in Fable (JavaScript) the ResizeArrays are always compared for full structural equality see https://github.com/fable-compiler/Fable/issues/3718
|
||
Full Usage:
exactlyOne resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T
The only element of the ResizeArray.
|
Returns the only element of the ResizeArray.
|
||
Full Usage:
except itemsToExclude resizeArray
Parameters:
'T seq
-
A sequence whose elements that also occur in the input ResizeArray will cause those elements to be
removed from the result.
resizeArray : ResizeArray<'T>
-
A ResizeArray whose elements that are not also in itemsToExclude will be returned.
Returns: ResizeArray<'T>
A ResizeArray that contains the distinct elements of ResizeArray that do not appear in itemsToExclude .
|
Returns a new list with the distinct elements of the input ResizeArray which do not appear in the itemsToExclude sequence. Uses generic hash and equality comparisons to compare values.
|
||
Full Usage:
exists predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: bool
true if any result from predicate is true .
|
Tests if any element of the ResizeArray satisfies the given predicate.
The predicate is applied to the elements of the input ResizeArray. If any application
returns true then the overall result is
|
||
Full Usage:
exists2 predicate resizeArray1 resizeArray2
Parameters:
'T -> 'U -> bool
-
The function to test the input elements.
resizeArray1 : ResizeArray<'T>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'U>
-
The second input ResizeArray.
Returns: bool
true if any result from predicate is true .
|
Tests if any pair of corresponding elements of the ResizeArrays satisfies the given predicate.
The predicate is applied to matching elements in the two collections up to the lesser of the
two lengths of the collections. If any application returns true then the overall result is
true and no further elements are tested. Otherwise, if one collections is longer
than the other then the
|
||
Full Usage:
failIfEmpty errorMessage arr
Parameters:
string
arr : ResizeArray<'T>
Returns: ResizeArray<'T>
Modifiers: inline Type parameters: 'T |
Raises an Exception if the Array is empty. (Useful for chaining) Returns the input Array
|
||
Full Usage:
failIfLessThan count errorMessage arr
Parameters:
int
errorMessage : string
arr : ResizeArray<'T>
Returns: ResizeArray<'T>
|
Raises an Exception if the Array has less then count items. (Useful for chaining) Returns the input Array
|
||
Full Usage:
fill target startIndex count value
Parameters:
ResizeArray<'T>
-
The target ResizeArray.
startIndex : int
-
The index of the first element to set.
count : int
-
The number of elements to set.
value : 'T
-
The value to set.
|
Fills a range of elements of the ResizeArray with the given value. Extends the ResizeArray if needed
|
||
Full Usage:
filter predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: List<'T>
A ResizeArray containing the elements for which the given predicate returns true.
Modifiers: inline Type parameters: 'T |
Returns a new collection containing only the elements of the collection
for which the given predicate returns
|
||
Full Usage:
filteri predicate resizeArray
Parameters:
int -> 'T -> bool
-
The function to test the current index.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
A ResizeArray containing the elements for which the given predicate returns true.
Modifiers: inline Type parameters: 'T |
Returns a new collection containing only the elements of the collection
for which the given predicate run on the index returns
|
||
Full Usage:
find predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T
The first element for which predicate returns true.
|
Returns the first element for which the given function returns
|
||
Full Usage:
findBack predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T
The last element for which predicate returns true.
|
Returns the last element for which the given function returns
|
||
Full Usage:
findIndex predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: int
The index of the first element in the ResizeArray that satisfies the given predicate.
|
Returns the index of the first element in the ResizeArray that satisfies the given predicate. Raises KeyNotFoundException if none of the elements satisfy the predicate.
|
||
Full Usage:
findIndexBack predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: int
The index of the last element in the ResizeArray that satisfies the given predicate.
|
Returns the index of the last element in the ResizeArray that satisfies the given predicate. Raise KeyNotFoundException if none of the elements satisfy the predicate.
|
||
Full Usage:
findIndexi predicate resizeArray
Parameters:
int -> 'T -> bool
-
The function to test each indexed element against.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: int
The index of the first element that satisfies the predicate, or an exception.
|
Returns the index of the first element in the ResizeArray that satisfies the given indexed predicate.
|
||
Full Usage:
first arr
Parameters:
ResizeArray<'T>
Returns: 'T
Modifiers: inline Type parameters: 'T |
Gets the first item in the Array. Same as this.[0]
|
||
Full Usage:
firstAndOnly arr
Parameters:
ResizeArray<'T>
Returns: 'T
Modifiers: inline Type parameters: 'T |
Gets the the only item in the Array. Fails if the Array does not have exactly one element.
|
||
Full Usage:
fold folder state resizeArray
Parameters:
'State -> 'T -> 'State
-
The function to update the state given the input elements.
state : 'State
-
The initial state.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'State
The final state.
|
Applies a function to each element of the collection, threading an accumulator argument
through the computation. If the input function is
|
||
Full Usage:
fold2 folder state resizeArray1 resizeArray2
Parameters:
'State -> 'T1 -> 'T2 -> 'State
-
The function to update the state given the input elements.
state : 'State
-
The initial state.
resizeArray1 : ResizeArray<'T1>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'T2>
-
The second input ResizeArray.
Returns: 'State
The final state.
|
Applies a function to pairs of elements drawn from the two collections,
left-to-right, threading an accumulator argument
through the computation. The two input
ResizeArrays must have the same lengths, otherwise an
|
||
Full Usage:
foldBack folder resizeArray state
Parameters:
'T -> 'State -> 'State
-
The function to update the state given the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
state : 'State
-
The initial state.
Returns: 'State
The state object after the folding function is applied to each element of the ResizeArray.
|
Applies a function to each element of the ResizeArray, starting from the end, threading an accumulator argument
through the computation. If the input function is
|
||
Full Usage:
foldBack2 folder resizeArray1 resizeArray2 state
Parameters:
'T1 -> 'T2 -> 'State -> 'State
-
The function to update the state given the input elements.
resizeArray1 : ResizeArray<'T1>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'T2>
-
The second input ResizeArray.
state : 'State
-
The initial state.
Returns: 'State
The final state.
|
Apply a function to pairs of elements drawn from the two collections, right-to-left,
threading an accumulator argument through the computation. The two input
ResizeArrays must have the same lengths, otherwise an
|
||
Full Usage:
forall predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: bool
true if all of the ResizeArray elements satisfy the predicate.
|
Tests if all elements of the ResizeArray satisfy the given predicate. The predicate is applied to the elements of the input collection. If any application returns false then the overall result is false and no further elements are tested. Otherwise, true is returned.
|
||
Full Usage:
forall2 predicate resizeArray1 resizeArray2
Parameters:
'T -> 'U -> bool
-
The function to test the input elements.
resizeArray1 : ResizeArray<'T>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'U>
-
The second input ResizeArray.
Returns: bool
true if all of the ResizeArray elements satisfy the predicate.
|
Tests if all corresponding elements of the ResizeArray satisfy the given predicate pairwise.
The predicate is applied to matching elements in the two collections up to the lesser of the
two lengths of the collections. If any application returns false then the overall result is
false and no further elements are tested. Otherwise, if one collection is longer
than the other then the
|
||
Full Usage:
get arr index
Parameters:
ResizeArray<'T>
-
The input Array.
index : int
-
The input index.
Returns: 'T
The value of the Array at the given index.
Modifiers: inline Type parameters: 'T |
Gets an element from an Array. (Use Array.getNeg(i) function if you want to use negative indices too.)
|
||
Full Usage:
getLooped index arr
Parameters:
int
arr : ResizeArray<'T>
Returns: 'T
Modifiers: inline Type parameters: 'T |
Any index will return a value. Array is treated as an endless loop in positive and negative direction
|
||
Full Usage:
getNeg index arr
Parameters:
int
arr : ResizeArray<'T>
Returns: 'T
Modifiers: inline Type parameters: 'T |
Gets an item in the Array by index. Allows for negative index too ( -1 is last item, like Python) (a negative index can also be done with '^' prefix. E.g. ^0 for the last item)
|
||
Full Usage:
groupBy projection resizeArray
Parameters:
'T -> 'Key
-
A function that transforms an element of the ResizeArray into a comparable key. Null or Option.None is allowed as key.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'Key * ResizeArray<'T>>
The result ResizeArray.
|
Applies a key-generating function to each element of a ResizeArray and yields a ResizeArray of unique keys. Each unique key contains a ResizeArray of all elements that match to this key.
|
||
Full Usage:
groupByDict projection resizeArray
Parameters:
'T -> 'Key
-
A function that transforms an element of the ResizeArray into a comparable key. As opposed to ResizeArray.groupBy the key may not be null or Option.None
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: Dictionary<'Key, ResizeArray<'T>>
The result ResizeArray.
|
Applies a key-generating function to each element of a ResizeArray and yields a Dict of unique keys and respective elements that match to this key. As opposed to ResizeArray.groupBy the key may not be null or Option.None
|
||
Full Usage:
hasItems count resizeArray
Parameters:
int
resizeArray : ResizeArray<'T>
Returns: bool
Modifiers: inline Type parameters: 'T |
Returns true if the given ResizeArray has count items.
|
||
Full Usage:
hasMaximumItems count resizeArray
Parameters:
int
resizeArray : ResizeArray<'T>
Returns: bool
Modifiers: inline Type parameters: 'T |
Returns true if the given ResizeArray has equal or less than count items.
|
||
Full Usage:
hasMinimumItems count resizeArray
Parameters:
int
resizeArray : ResizeArray<'T>
Returns: bool
Modifiers: inline Type parameters: 'T |
Returns true if the given ResizeArray has equal or more than count items.
|
||
Full Usage:
hasOne resizeArray
Parameters:
ResizeArray<'T>
Returns: bool
Modifiers: inline Type parameters: 'T |
Returns true if the given ResizeArray has just one item. Same as ResizeArray.isSingleton
|
||
Full Usage:
head resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T
The first element of the ResizeArray.
Modifiers: inline Type parameters: 'T |
Returns the first element of the ResizeArray.
|
||
Full Usage:
iPrevThisNext resizeArray
Parameters:
ResizeArray<'T>
Returns: (int * 'T * 'T * 'T) seq
|
Yields looped Seq from (1, last, first, second) up to (lastIndex, second-last, last, first) The resulting seq has the same element count as the input ResizeArray.
|
||
Full Usage:
iThisNext resizeArray
Parameters:
ResizeArray<'T>
Returns: (int * 'T * 'T) seq
|
Yields looped Seq from (0,first, second) up to (lastIndex, last, first). The resulting seq has the same element count as the input ResizeArray.
|
||
Full Usage:
indexed resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<int * 'T>
The ResizeArray of indexed elements.
|
Builds a new ResizeArray whose elements are the corresponding elements of the input ResizeArray paired with the integer index (from 0) of each element.
|
||
Full Usage:
init count initializer
Parameters:
int
-
The number of elements to initialize.
initializer : int -> 'T
-
The function to generate the initial values for each index.
Returns: ResizeArray<'T>
The created ResizeArray.
Modifiers: inline Type parameters: 'T |
Creates a ResizeArray given the dimension and a generator function to compute the elements.
|
||
Full Usage:
insertAt index value resizeArray
Parameters:
int
-
The index where the item should be inserted.
value : 'T
-
The value to insert.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The result ResizeArray.
|
Return a new ResizeArray with a new item inserted before the given index.(does NOT modify in place !)
|
||
Full Usage:
insertManyAt index values resizeArray
Parameters:
int
-
The index where the items should be inserted.
values : ICollection<'T>
-
The values to insert.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The result ResizeArray.
|
Return a new ResizeArray with new items inserted before the given index.(does NOT modify in place !) If required increases the count of the ResizeArray.
|
||
Full Usage:
isEmpty resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: bool
true if the ResizeArray is empty.
Modifiers: inline Type parameters: 'T |
Returns true if the given ResizeArray is empty, otherwise false.
|
||
Full Usage:
isNotEmpty resizeArray
Parameters:
ResizeArray<'T>
Returns: bool
Modifiers: inline Type parameters: 'T |
Returns true if the given ResizeArray is not empty.
|
||
Full Usage:
isSingleton resizeArray
Parameters:
ResizeArray<'T>
Returns: bool
Modifiers: inline Type parameters: 'T |
Returns true if the given ResizeArray has just one item. Same as ResizeArray.hasOne
|
||
Full Usage:
item index resizeArray
Parameters:
int
-
The input index.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T
The value of the ResizeArray at the given index.
Modifiers: inline Type parameters: 'T |
Gets an element from a ResizeArray.
|
||
Full Usage:
iter action resizeArray
Parameters:
'T -> unit
-
The function to apply.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Modifiers: inline Type parameters: 'T |
Applies the given function to each element of the ResizeArray.
|
||
Full Usage:
iter2 action resizeArray1 resizeArray2
Parameters:
'T -> 'U -> unit
-
The function to apply.
resizeArray1 : ResizeArray<'T>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'U>
-
The second input ResizeArray.
Modifiers: inline Type parameters: 'T, 'U |
Applies the given function to pair of elements drawn from matching indices in two ResizeArrays. The
two ResizeArrays must have the same lengths, otherwise an
|
||
Full Usage:
iteri action resizeArray
Parameters:
int -> 'T -> unit
-
The function to apply to each index and element.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Modifiers: inline Type parameters: 'T |
Applies the given function to each element of the ResizeArray. The integer passed to the function indicates the index of element.
|
||
Full Usage:
iteri2 action resizeArray1 resizeArray2
Parameters:
int -> 'T -> 'U -> unit
-
The function to apply to each index and pair of elements.
resizeArray1 : ResizeArray<'T>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'U>
-
The second input ResizeArray.
Modifiers: inline Type parameters: 'T, 'U |
Applies the given function to pair of elements drawn from matching indices in two ResizeArrays,
also passing the index of the elements. The two ResizeArrays must have the same lengths,
otherwise an
|
||
Full Usage:
last resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T
The last element of the ResizeArray.
Modifiers: inline Type parameters: 'T |
Returns the last element of the ResizeArray.
|
||
Full Usage:
length resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: int
The length or count of the ResizeArray.
Modifiers: inline Type parameters: 'T |
Returns the length of a ResizeArray. You can also use property resizeArray.Count.
|
||
Full Usage:
map mapping resizeArray
Parameters:
'T -> 'U
-
The function to transform elements of the ResizeArray.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'U>
The ResizeArray of transformed elements.
Modifiers: inline Type parameters: 'T, 'U |
Builds a new ResizeArray whose elements are the results of applying the given function to each of the elements of the ResizeArray.
|
||
Full Usage:
map2 mapping resizeArray1 resizeArray2
Parameters:
'T1 -> 'T2 -> 'U
-
The function to transform the pairs of the input elements.
resizeArray1 : ResizeArray<'T1>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'T2>
-
The second input ResizeArray.
Returns: ResizeArray<'U>
The ResizeArray of transformed elements.
|
Builds a new collection whose elements are the results of applying the given function
to the corresponding elements of the two collections pairwise. The two input
ResizeArrays must have the same lengths, otherwise an
|
||
Full Usage:
map3 mapping resizeArray1 resizeArray2 resizeArray3
Parameters:
'T1 -> 'T2 -> 'T3 -> 'U
-
The function to transform the pairs of the input elements.
resizeArray1 : ResizeArray<'T1>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'T2>
-
The second input ResizeArray.
resizeArray3 : ResizeArray<'T3>
-
The third input ResizeArray.
Returns: ResizeArray<'U>
The ResizeArray of transformed elements.
|
Builds a new collection whose elements are the results of applying the given function
to the corresponding triples from the three collections. The three input
ResizeArrays must have the same length, otherwise an
|
||
Full Usage:
mapFold mapping state resizeArray
Parameters:
'State -> 'T -> 'Result * 'State
-
The function to transform elements from the input ResizeArray and accumulate the final value.
state : 'State
-
The initial state.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'Result> * 'State
The ResizeArray of transformed elements, and the final accumulated value.
|
Combines map and fold. Builds a new ResizeArray whose elements are the results of applying the given function to each of the elements of the input ResizeArray. The function is also used to accumulate a final value.
|
||
Full Usage:
mapFoldBack mapping resizeArray state
Parameters:
'T -> 'State -> 'Result * 'State
-
The function to transform elements from the input ResizeArray and accumulate the final value.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
state : 'State
-
The initial state.
Returns: ResizeArray<'Result> * 'State
The ResizeArray of transformed elements, and the final accumulated value.
|
Combines map and foldBack. Builds a new ResizeArray whose elements are the results of applying the given function to each of the elements of the input ResizeArray. The function is also used to accumulate a final value.
|
||
Full Usage:
mapFromArray mapping arr
Parameters:
'T -> 'U
-
The function to transform elements of the ResizeArray.
arr : 'T array
-
The input Array.
Returns: ResizeArray<'U>
The ResizeArray of transformed elements.
Modifiers: inline Type parameters: 'T, 'U |
Builds a new ResizeArray whose elements are the results of applying the given function to each of the elements of the Array.
|
||
Full Usage:
mapFromIList mapping list
Parameters:
'T -> 'U
-
The function to transform elements of the ResizeArray.
list : IList<'T>
-
The input collection with IList interface.
Returns: ResizeArray<'U>
The ResizeArray of transformed elements.
Modifiers: inline Type parameters: 'T, 'U |
Builds a new ResizeArray whose elements are the results of applying the given function to each of the elements of a collection with IList interface.
|
||
Full Usage:
mapFromSeq mapping sequence
Parameters:
'T -> 'U
-
The function to transform elements of the ResizeArray.
sequence : 'T seq
-
The input IEnumerable.
Returns: ResizeArray<'U>
The ResizeArray of transformed elements.
Modifiers: inline Type parameters: 'T, 'U |
Builds a new ResizeArray whose elements are the results of applying the given function to each of the elements of an IEnumerable.
|
||
Full Usage:
mapToArray mapping resizeArray
Parameters:
'T -> 'U
-
The function to transform elements of the ResizeArray.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'U[]
The Array of transformed elements.
Modifiers: inline Type parameters: 'T, 'U |
Builds a new Array whose elements are the results of applying the given function to each of the elements of the ResizeArray.
|
||
Full Usage:
mapi mapping resizeArray
Parameters:
int -> 'T -> 'U
-
The function to transform elements and their indices.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'U>
The ResizeArray of transformed elements.
|
Builds a new ResizeArray whose elements are the results of applying the given function to each of the elements of the ResizeArray. The integer index passed to the function indicates the index of element being transformed.
|
||
Full Usage:
mapi2 mapping resizeArray1 resizeArray2
Parameters:
int -> 'T1 -> 'T2 -> 'U
-
The function to transform pairs of input elements and their indices.
resizeArray1 : ResizeArray<'T1>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'T2>
-
The second input ResizeArray.
Returns: ResizeArray<'U>
The ResizeArray of transformed elements.
|
Builds a new collection whose elements are the results of applying the given function
to the corresponding elements of the two collections pairwise, also passing the index of
the elements. The two input ResizeArrays must have the same lengths, otherwise an
|
||
Full Usage:
max resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T
The maximum element.
Modifiers: inline Type parameters: 'T |
Returns the greatest of all elements of the ResizeArray, compared via Operators.max on the function result. Throws ArgumentException for empty ResizeArrays.
|
||
Full Usage:
max2 resizeArray
Parameters:
ResizeArray<'T>
Returns: 'T * 'T
Modifiers: inline Type parameters: 'T |
Returns the biggest and the second biggest element of the ResizeArray. If they are equal then the order is kept
|
||
Full Usage:
max2By f resizeArray
Parameters:
'T -> 'a
resizeArray : ResizeArray<'T>
Returns: 'T * 'T
Modifiers: inline Type parameters: 'T, 'a |
Returns the biggest and the second biggest element of the ResizeArray. Elements are compared by applying the predicate function first. If they are equal after function is applied then the order is kept
|
||
Full Usage:
max2IndicesBy f resizeArray
Parameters:
'T -> 'a
resizeArray : ResizeArray<'T>
Returns: int * int
Modifiers: inline Type parameters: 'T, 'a |
Returns the indices of the biggest and the second biggest element of the ResizeArray. Elements are compared by applying the predicate function first. If they are equal after function is applied then the order is kept
|
||
Full Usage:
max3 resizeArray
Parameters:
ResizeArray<'T>
Returns: 'T * 'T * 'T
Modifiers: inline Type parameters: 'T |
Returns the biggest three elements of the ResizeArray. The first element is the biggest, the second is the second biggest and the third is the third biggest. If they are equal then the order is kept
|
||
Full Usage:
max3By f resizeArray
Parameters:
'T -> 'a
resizeArray : ResizeArray<'T>
Returns: 'T * 'T * 'T
Modifiers: inline Type parameters: 'T, 'a |
Returns the biggest three elements of the ResizeArray. The first element is the biggest, the second is the second biggest and the third is the third biggest. Elements are compared by applying the predicate function first. If they are equal after function is applied then the order is kept
|
||
Full Usage:
max3IndicesBy f resizeArray
Parameters:
'T -> 'a
resizeArray : ResizeArray<'T>
Returns: int * int * int
Modifiers: inline Type parameters: 'T, 'a |
Returns the indices of the three biggest elements of the ResizeArray. The first element is the index of the biggest, the second is the index of the second biggest and the third is the index of the third biggest. Elements are compared by applying the predicate function first. If they are equal after function is applied then the order is kept
|
||
Full Usage:
maxBy projection resizeArray
Parameters:
'T -> 'Key
-
The function to transform the elements into a type supporting comparison.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T
The maximum element.
Modifiers: inline Type parameters: 'T, 'Key |
Returns the greatest of all elements of the ResizeArray, compared via Operators.max on the function result.
|
||
Full Usage:
maxIndexBy projection resizeArray
Parameters:
'T -> 'Key
-
The function to transform the elements into a type supporting comparison.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: int
The index of the maximum element.
Modifiers: inline Type parameters: 'T, 'Key |
Returns the index of the greatest of all elements of the ResizeArray, compared via Operators.max on the function result.
|
||
Full Usage:
min resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T
The minimum element.
Modifiers: inline Type parameters: 'T |
Returns the lowest of all elements of the ResizeArray, compared via Operators.min.
|
||
Full Usage:
min2 resizeArray
Parameters:
ResizeArray<'T>
Returns: 'T * 'T
Modifiers: inline Type parameters: 'T |
Returns the smallest and the second smallest element of the ResizeArray. If they are equal then the order is kept
|
||
Full Usage:
min2By f resizeArray
Parameters:
'T -> 'a
resizeArray : ResizeArray<'T>
Returns: 'T * 'T
Modifiers: inline Type parameters: 'T, 'a |
Returns the smallest and the second smallest element of the ResizeArray. Elements are compared by applying the predicate function first. If they are equal after function is applied then the order is kept
|
||
Full Usage:
min2IndicesBy f resizeArray
Parameters:
'T -> 'a
resizeArray : ResizeArray<'T>
Returns: int * int
Modifiers: inline Type parameters: 'T, 'a |
Returns the indices of the smallest and the second smallest element of the ResizeArray. Elements are compared by applying the predicate function first. If they are equal after function is applied then the order is kept
|
||
Full Usage:
min3 resizeArray
Parameters:
ResizeArray<'T>
Returns: 'T * 'T * 'T
Modifiers: inline Type parameters: 'T |
Returns the smallest three elements of the ResizeArray. The first element is the smallest, the second is the second smallest and the third is the third smallest. If they are equal then the order is kept
|
||
Full Usage:
min3By f resizeArray
Parameters:
'T -> 'a
resizeArray : ResizeArray<'T>
Returns: 'T * 'T * 'T
Modifiers: inline Type parameters: 'T, 'a |
Returns the smallest three elements of the ResizeArray. The first element is the smallest, the second is the second smallest and the third is the third smallest. Elements are compared by applying the predicate function first. If they are equal after function is applied then the order is kept
|
||
Full Usage:
min3IndicesBy f resizeArray
Parameters:
'T -> 'a
resizeArray : ResizeArray<'T>
Returns: int * int * int
Modifiers: inline Type parameters: 'T, 'a |
Returns the indices of the three smallest elements of the ResizeArray. The first element is the index of the smallest, the second is the index of the second smallest and the third is the index of the third smallest. Elements are compared by applying the predicate function first. If they are equal after function is applied then the order is kept
|
||
Full Usage:
minBy projection resizeArray
Parameters:
'T -> 'Key
-
The function to transform the elements into a type supporting comparison.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T
The minimum element.
Modifiers: inline Type parameters: 'T, 'Key |
Returns the lowest of all elements of the ResizeArray, compared via Operators.min on the function result.
|
||
Full Usage:
minIndexBy projection resizeArray
Parameters:
'T -> 'Key
-
The function to transform the elements into a type supporting comparison.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: int
The index of the smallest element.
Modifiers: inline Type parameters: 'T, 'Key |
Returns the index of the smallest of all elements of the ResizeArray, compared via Operators.max on the function result.
|
||
Full Usage:
notExists predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: bool
false if any result from predicate is true .
|
Tests if none of the elements of the ResizeArray satisfies the given predicate.
The predicate is applied to the elements of the input ResizeArray. If any application
returns true then the overall result is
|
||
Full Usage:
ofArray arr
Parameters:
'T[]
Returns: ResizeArray<'T>
Modifiers: inline Type parameters: 'T |
Builds a new ResizeArray from the given Array. (Use the asResizeArray function if you want to just cast an Array to a ResizeArray in Fable-JavaScript)
|
||
Full Usage:
ofIList arr
Parameters:
IList<'T>
Returns: ResizeArray<'T>
Modifiers: inline Type parameters: 'T |
|||
Full Usage:
ofList list
Parameters:
'T list
-
The input list.
Returns: ResizeArray<'T>
The ResizeArray of elements from the list.
|
Builds a ResizeArray from the given list.
|
||
Full Usage:
ofSeq source
Parameters:
'T seq
-
The input sequence.
Returns: ResizeArray<'T>
The ResizeArray of elements from the sequence.
|
Builds a new ResizeArray from the given enumerable object.
|
||
Full Usage:
pairwise resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T * 'T>
The result ResizeArray.
|
Returns a ResizeArray of each element in the input ResizeArray and its predecessor, with the exception of the first element which is only returned as the predecessor of the second element. If the ResizeArray has 0 or 1 item an empty ResizeArray is returned
|
||
Full Usage:
partition predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T> * ResizeArray<'T>
A pair of ResizeArrays. The first containing the elements the predicate evaluated to true ,
and the second containing those evaluated to false .
|
Splits the collection into two collections, containing the
elements for which the given predicate returns
|
||
Full Usage:
partition3 predicate1 predicate2 resizeArray
Parameters:
'T -> bool
-
The first function to test the input elements.
predicate2 : 'T -> bool
-
The second function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T> * ResizeArray<'T> * ResizeArray<'T>
Three ResizeArrays.
|
Splits the collection into three collections,
first containing the elements for which the given predicate1 returns
|
||
Full Usage:
partition3By partitioner resizeArray
Parameters:
'T -> Choice<'U1, 'U2, 'U3>
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'U1> * ResizeArray<'U2> * ResizeArray<'U3>
Three ResizeArrays.
|
Splits the collection into three collections, containing the elements for which the
given function returns
|
||
Full Usage:
partition4 predicate1 predicate2 predicate3 resizeArray
Parameters:
'T -> bool
-
The first function to test the input elements.
predicate2 : 'T -> bool
-
The second function to test the input elements.
predicate3 : 'T -> bool
-
The third function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T> * ResizeArray<'T> * ResizeArray<'T> * ResizeArray<'T>
Four ResizeArrays.
|
Splits the collection into four collections,
first containing the elements for which the given predicate1 returns
|
||
Full Usage:
partition4By partitioner resizeArray
Parameters:
'T -> Choice<'U1, 'U2, 'U3, 'U4>
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'U1> * ResizeArray<'U2> * ResizeArray<'U3> * ResizeArray<'U4>
Four ResizeArrays.
|
Splits the collection into four collections, containing the elements for which the
given function returns
|
||
Full Usage:
partition5 predicate1 predicate2 predicate3 predicate4 resizeArray
Parameters:
'T -> bool
-
The first function to test the input elements.
predicate2 : 'T -> bool
-
The second function to test the input elements.
predicate3 : 'T -> bool
-
The third function to test the input elements.
predicate4 : 'T -> bool
-
The fourth function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T> * ResizeArray<'T> * ResizeArray<'T> * ResizeArray<'T> * ResizeArray<'T>
Five ResizeArrays.
|
Splits the collection into five collections,
first containing the elements for which the given predicate1 returns
|
||
Full Usage:
partition5By partitioner resizeArray
Parameters:
'T -> Choice<'U1, 'U2, 'U3, 'U4, 'U5>
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'U1> * ResizeArray<'U2> * ResizeArray<'U3> * ResizeArray<'U4> * ResizeArray<'U5>
Five ResizeArrays.
|
Splits the collection into five collections, containing the elements for which the
given function returns
|
||
Full Usage:
partitionBy partitioner resizeArray
Parameters:
'T -> Choice<'U1, 'U2>
resizeArray : ResizeArray<'T>
Returns: ResizeArray<'U1> * ResizeArray<'U2>
Modifiers: inline Type parameters: 'T, 'U1, 'U2 |
Splits the collection into two collections, containing the elements for which the
given function returns
|
||
Full Usage:
permute indexMap resizeArray
Parameters:
int -> int
-
The function that maps input indices to output indices.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The output ResizeArray.
|
Returns a ResizeArray with all elements permuted according to the specified permutation.
|
||
Full Usage:
pick chooser resizeArray
Parameters:
'T -> 'U option
-
The function to generate options from the elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'U
The first result.
|
Applies the given function to successive elements, returning the first
result where function returns
|
||
Full Usage:
pickBack chooser resizeArray
Parameters:
'T -> 'U option
-
The function to generate options from the elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'U
The first result. From the end of the ResizeArray.
|
Starting from last element going backwards. Applies the given function to successive elements, returning the first
result where function returns
|
||
Full Usage:
prepend resizeArray2 resizeArray1
Parameters:
ResizeArray<'T>
-
The input ResizeArray that will be at the end.
resizeArray1 : ResizeArray<'T>
-
The input ResizeArray that will be at the beginning.
Returns: List<'T>
The resulting ResizeArray of length: resizeArray2.Count + resizeArray1.Count..
Modifiers: inline Type parameters: 'T |
Builds a new ResizeArray that contains the elements of the second ResizeArray followed by the elements of the first ResizeArray. When used with the pipeline operator |> the first and only argument to this function with be at the end of the resulting list. Compared to ResizeArray.append this function has the order of its arguments flipped
|
||
Full Usage:
prevThis resizeArray
Parameters:
ResizeArray<'T>
Returns: ('T * 'T) seq
|
Yields looped Seq from (last,first) up to (second-last, last). The resulting seq has the same element count as the input ResizeArray.
|
||
Full Usage:
prevThisNext resizeArray
Parameters:
ResizeArray<'T>
Returns: ('T * 'T * 'T) seq
|
Yields looped Seq of from (last, first, second) up to (second-last, last, first). The resulting seq has the same element count as the input ResizeArray.
|
||
Full Usage:
reduce reduction resizeArray
Parameters:
'T -> 'T -> 'T
-
The function to reduce a pair of elements to a single element.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T
The final result of the reductions.
|
Applies a function to each element of the ResizeArray, threading an accumulator argument
through the computation. If the input function is
|
||
Full Usage:
reduceBack reduction resizeArray
Parameters:
'T -> 'T -> 'T
-
A function that takes in the next-to-last element of the list and the
current accumulated result to produce the next accumulated result.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T
The final result of the reductions.
|
Applies a function to each element of the ResizeArray, starting from the end, threading an accumulator argument
through the computation. If the input function is
|
||
Full Usage:
removeAt index resizeArray
Parameters:
int
-
The index of the item to be removed.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The result ResizeArray.
|
Return a new ResizeArray with the item at a given index removed. (does NOT modify in place !)
|
||
Full Usage:
removeManyAt index count resizeArray
Parameters:
int
-
The index of the first item to be removed.
count : int
-
The number of items to remove.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The result ResizeArray.
|
Return a new ResizeArray with the number of items starting at a given index removed. (does NOT modify in place !)
|
||
Full Usage:
replicate count initial
Parameters:
int
-
The number of elements to replicate.
initial : 'T
-
The value to replicate
Returns: ResizeArray<'T>
The generated ResizeArray.
|
Creates a ResizeArray by replicating the given initial value.
|
||
Full Usage:
rev resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The reversed ResizeArray.
|
Returns a new ResizeArray with the elements in reverse order.
|
||
Full Usage:
revInPlace resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
|
Reverses the order of ResizeArray in place.
|
||
Full Usage:
rotate amount resizeArray
Parameters:
int
-
How many elements to shift forward. Or backward if number is negative
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The new result ResizeArray.
Modifiers: inline Type parameters: 'T |
Considers List circular and move elements up for positive integers or down for negative integers. e.g.: rotate +1 [ a, b, c, d] = [ d, a, b, c] e.g.: rotate -1 [ a, b, c, d] = [ b, c, d, a] the amount can even be bigger than the list's size. I will just rotate more than one loop.
|
||
Full Usage:
rotateDownTill condition resizeArray
Parameters:
'T -> bool
-
The condition to meet.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The new result ResizeArray.
Modifiers: inline Type parameters: 'T |
Considers List circular and move elements down till condition is met for the first item. The algorithm takes elements from the start and put them at the end till the first element in the list meets the condition. If the first element in the input meets the condition no changes are made. But still a shallow copy is returned.
|
||
Full Usage:
rotateDownTillLast condition resizeArray
Parameters:
'T -> bool
-
The condition to meet.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The new result ResizeArray.
Modifiers: inline Type parameters: 'T |
Considers List circular and move elements down till condition is met for the last item. The algorithm takes elements from the start and put them at the end till the last element in the list meets the condition. If the last element in the input meets the condition no changes are made. But still a shallow copy is returned.
|
||
Full Usage:
rotateUpTill condition resizeArray
Parameters:
'T -> bool
-
The condition to meet.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The new result ResizeArray.
Modifiers: inline Type parameters: 'T |
Considers List circular and move elements up till condition is met for the first item. The algorithm takes elements from the end and put them at the start till the first element in the list meets the condition. If the first element in the input meets the condition no changes are made. But still a shallow copy is returned.
|
||
Full Usage:
rotateUpTillLast condition resizeArray
Parameters:
'T -> bool
-
The condition to meet.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The new result ResizeArray.
Modifiers: inline Type parameters: 'T |
Considers List circular and move elements up till condition is met for the last item. The algorithm takes elements from the end and put them at the start till the last element in the list meets the condition. If the last element in the input meets the condition no changes are made. But still a shallow copy is returned.
|
||
Full Usage:
scan folder stateInit resizeArray
Parameters:
'State -> 'T -> 'State
-
The function to update the state given the input elements.
stateInit : 'State
-
The initial state.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'State>
The ResizeArray of state values. This ResizeArray has the initial state and the state for all elements in the input ResizeArray,
so one more item than the input.
|
Like
|
||
Full Usage:
scanBack folder resizeArray stateInit
Parameters:
'T -> 'State -> 'State
-
The function to update the state given the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
stateInit : 'State
-
The initial state.
Returns: ResizeArray<'State>
The ResizeArray of state values. Count = input count + 1
|
Like
|
||
Full Usage:
second arr
Parameters:
ResizeArray<'T>
Returns: 'T
Modifiers: inline Type parameters: 'T |
Gets the second item in the Array. Same as this.[1]
|
||
Full Usage:
secondLast arr
Parameters:
ResizeArray<'T>
Returns: 'T
Modifiers: inline Type parameters: 'T |
Gets the second last item in the Array. Same as this.[this.Count - 2]
|
||
Full Usage:
set arr index value
Parameters:
ResizeArray<'T>
-
The input Array.
index : int
-
The input index.
value : 'T
-
The input value.
Modifiers: inline Type parameters: 'T |
Sets an element of a Array. (use Array.setNeg(i) function if you want to use negative indices too)
|
||
Full Usage:
setLooped index value arr
Parameters:
int
value : 'T
arr : ResizeArray<'T>
Modifiers: inline Type parameters: 'T |
Any index will set a value. Array is treated as an endless loop in positive and negative direction
|
||
Full Usage:
setNeg index value arr
Parameters:
int
value : 'T
arr : ResizeArray<'T>
Modifiers: inline Type parameters: 'T |
Sets an item in the Array by index. Allows for negative index too ( -1 is last item, like Python) (a negative index can also be done with '^' prefix. E.g. ^0 for the last item)
|
||
Full Usage:
singleton value
Parameters:
'a
-
The input item.
Returns: ResizeArray<'a>
The result ResizeArray of one item.
Modifiers: inline Type parameters: 'a |
Returns a ResizeArray that contains one item only.
|
||
Full Usage:
skip count resizeArray
Parameters:
int
-
The number of elements to skip.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
A copy of the input ResizeArray, after removing the first N elements.
|
Builds a new ResizeArray that contains the elements of the given ResizeArray, excluding the first N elements.
|
||
Full Usage:
skipWhile predicate resizeArray
Parameters:
'T -> bool
-
A function that evaluates an element of the ResizeArray to a boolean value.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The created sub ResizeArray.
|
Bypasses elements in a ResizeArray while the given predicate returns
|
||
Full Usage:
slice startIdx endIdx arr
Parameters:
int
endIdx : int
arr : ResizeArray<'T>
Returns: ResizeArray<'T>
|
Slice the Array given start and end index. Allows for negative indices too. ( -1 is last item, like Python) The resulting Array includes the end index. Raises an IndexOutOfRangeException if indices are out of range. If you don't want an exception to be raised for index overflow or overlap use Array.trim. (A negative index can also be done with '^' prefix. E.g. ^0 for the last item, when F# Language preview features are enabled.)
|
||
Full Usage:
sort resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
A new sorted ResizeArray.
|
Sorts the elements of a ResizeArray, returning a new ResizeArray. Elements are compared using Operators.compare. This means "Z" is before "a". This is different from Collections.Generic.Sort() where "a" is before "Z" using IComparable interface. This is NOT a stable sort, i.e. the original order of equal elements is not necessarily preserved. For a stable sort, consider using Seq.Sort
|
||
Full Usage:
sortBy projection resizeArray
Parameters:
'T -> 'Key
-
The function to transform ResizeArray elements into the type that is compared.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The sorted ResizeArray.
|
Sorts the elements of a ResizeArray, using the given projection for the keys and returning a new ResizeArray. Elements are compared using Operators.compare. This means "Z" is before "a". This is different from Collections.Generic.Sort() where "a" is before "Z" using IComparable interface. This is NOT a stable sort, i.e. the original order of equal elements is not necessarily preserved. For a stable sort, consider using Seq.sort.
|
||
Full Usage:
sortByDescending projection resizeArray
Parameters:
'T -> 'Key
-
The function to transform ResizeArray elements into the type that is compared.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The sorted ResizeArray.
Modifiers: inline Type parameters: 'T, 'Key |
Sorts the elements of a ResizeArray, in descending order, using the given projection for the keys and returning a new ResizeArray. Elements are compared using Operators.compare. This means in ascending sorting "Z" is before "a". This is different from Collections.Generic.Sort() where "a" is before "Z" using IComparable interface. This is NOT a stable sort, i.e. the original order of equal elements is not necessarily preserved. For a stable sort, consider using Seq.sort.
|
||
Full Usage:
sortDescending resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The sorted ResizeArray.
|
Sorts the elements of a ResizeArray, in descending order, returning a new ResizeArray. Elements are compared using Operators.compare. This means in ascending sorting "Z" is before "a". This is different from Collections.Generic.Sort() where "a" is before "Z" using IComparable interface. This is NOT a stable sort, i.e. the original order of equal elements is not necessarily preserved. For a stable sort, consider using Seq.sort.
|
||
Full Usage:
sortInPlace resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
|
Sorts the elements of a ResizeArray by mutating the ResizeArray in-place, using the given comparison function. Elements are compared using Operators.compare. This means in ascending sorting "Z" is before "a". This is different from Collections.Generic.Sort() where "a" is before "Z" using IComparable interface. This is NOT a stable sort, i.e. the original order of equal elements is not necessarily preserved. For a stable sort, consider using Seq.sort.
|
||
Full Usage:
sortInPlaceBy projection resizeArray
Parameters:
'T -> 'Key
-
The function to transform ResizeArray elements into the type that is compared.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
|
Sorts the elements of a ResizeArray by mutating the ResizeArray in-place, using the given projection for the keys. Elements are compared using Operators.compare. This means in ascending sorting "Z" is before "a". This is different from Collections.Generic.Sort() where "a" is before "Z" using IComparable interface. This is NOT a stable sort, i.e. the original order of equal elements is not necessarily preserved. For a stable sort, consider using Seq.sort.
|
||
Full Usage:
sortInPlaceWith comparer resizeArray
Parameters:
'T -> 'T -> int
-
The function to compare pairs of ResizeArray elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
|
Sorts the elements of a ResizeArray by mutating the ResizeArray in-place, using the given comparison function as the order. This is NOT a stable sort, i.e. the original order of equal elements is not necessarily preserved. For a stable sort, consider using Seq.sort.
|
||
Full Usage:
sortWith comparer resizeArray
Parameters:
'T -> 'T -> int
-
The function to compare pairs of ResizeArray elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The sorted ResizeArray.
|
Sorts the elements of a ResizeArray, using the given comparison function as the order, returning a new ResizeArray. This is NOT a stable sort, i.e. the original order of equal elements is not necessarily preserved. For a stable sort, consider using Seq.sort.
|
||
|
Splits a ResizeArray into two ResizeArrays, at the given index.
|
||
Full Usage:
splitInto chunkCount resizeArray
Parameters:
int
-
The maximum number of chunks.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<ResizeArray<'T>>
The ResizeArray split into chunks.
|
Splits the input ResizeArray into at most
|
||
Full Usage:
sub startIndex count resizeArray
Parameters:
int
-
The index of the first element of the sub ResizeArray.
count : int
-
The length of the sub ResizeArray.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: List<'T>
The created sub ResizeArray.
|
Builds a new ResizeArray that contains the given sub-range specified by starting index and length.
|
||
Full Usage:
sum resizeArray
Parameters:
ResizeArray<^T>
-
The input ResizeArray.
Returns: ^T
The resulting sum.
Modifiers: inline Type parameters: ^T |
Returns the sum of the elements in the ResizeArray.
|
||
Full Usage:
sumBy projection resizeArray
Parameters:
'T -> ^Key
-
The function to transform the ResizeArray elements into the type to be summed.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ^Key
The resulting sum.
Modifiers: inline Type parameters: 'T, ^Key |
Returns the sum of the results generated by applying the function to each element of the ResizeArray.
|
||
Full Usage:
swap i j resizeArray
Parameters:
int
j : int
resizeArray : ResizeArray<'T>
Modifiers: inline Type parameters: 'T |
Swap the values of two given indices in ResizeArray
|
||
Full Usage:
tail resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: List<'T>
A new ResizeArray containing the elements of the original except the first element.
|
Returns a new ResizeArray containing the elements of the original except the first element.
|
||
Full Usage:
take count resizeArray
Parameters:
int
-
The number of items to take.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The result ResizeArray.
|
Returns the first N elements of the ResizeArray.
Throws
|
||
Full Usage:
takeWhile predicate resizeArray
Parameters:
'T -> bool
-
A function that evaluates to false when no more items should be returned.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The result ResizeArray.
|
Returns a ResizeArray that contains all elements of the original ResizeArray while the
given predicate returns
|
||
Full Usage:
third arr
Parameters:
ResizeArray<'T>
Returns: 'T
Modifiers: inline Type parameters: 'T |
Gets the third item in the Array. Same as this.[2]
|
||
Full Usage:
thirdLast arr
Parameters:
ResizeArray<'T>
Returns: 'T
Modifiers: inline Type parameters: 'T |
Gets the third last item in the Array. Same as this.[this.Count - 3]
|
||
Full Usage:
thisNext resizeArray
Parameters:
ResizeArray<'T>
Returns: ('T * 'T) seq
|
Yields looped Seq from (first, second) up to (last, first). The resulting seq has the same element count as the input ResizeArray.
|
||
Full Usage:
toArray resizeArray
Parameters:
ResizeArray<'T>
Returns: 'T[]
Modifiers: inline Type parameters: 'T |
Return a fixed-length Array containing the elements of the input ResizeArray as a copy. This function always allocates a new Array and copies the elements. (Use the asArray function if you want to just cast a ResizeArray to an Array in Fable-JavaScript)
|
||
Full Usage:
toList resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T list
The list of ResizeArray elements.
|
Builds a list from the given ResizeArray.
|
||
Full Usage:
toSeq resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T seq
The sequence of ResizeArray elements.
|
Views the given ResizeArray as a sequence. using Seq.readonly
|
||
Full Usage:
transpose resizeArrays
Parameters:
ResizeArray<ResizeArray<'T>>
-
The input sequence of ResizeArrays.
Returns: ResizeArray<ResizeArray<'T>>
The transposed ResizeArray.
|
Returns the transpose of the given sequence of ResizeArrays.
|
||
Full Usage:
trim fromStartCount fromEndCount arr
Parameters:
int
fromEndCount : int
arr : ResizeArray<'T>
Returns: ResizeArray<'T>
|
Trim items from start and end. If the sum of fromStartCount and fromEndCount is bigger than arr.Count it returns an empty Array. If you want an exception to be raised for index overlap (total trimming is bigger than count) use Array.slice with negative end index.
|
||
Full Usage:
truncate count resizeArray
Parameters:
int
-
The maximum number of items to return.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The result ResizeArray.
|
Returns at most N elements in a new ResizeArray. When count is negative return empty ResizeArray.
|
||
Full Usage:
tryExactlyOne resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T option
The only element of the ResizeArray or None .
|
Returns the only element of the ResizeArray or
|
||
Full Usage:
tryFind predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T option
The first element that satisfies the predicate, or None .
|
Returns the first element for which the given function returns
|
||
Full Usage:
tryFindBack predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T option
The last element that satisfies the predicate, or None .
|
Returns the last element for which the given function returns
|
||
Full Usage:
tryFindIndex predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: int option
The index of the first element that satisfies the predicate, or None .
|
Returns the index of the first element in the ResizeArray that satisfies the given predicate.
|
||
Full Usage:
tryFindIndexBack predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: int option
The index of the last element that satisfies the predicate, or None .
|
Returns the index of the last element in the ResizeArray that satisfies the given predicate.
|
||
Full Usage:
tryFindIndexi predicate resizeArray
Parameters:
int -> 'T -> bool
-
The function to test each indexed element against.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: int option
The index of the first element that satisfies the predicate, or None if not found.
Modifiers: inline Type parameters: 'T |
Returns the index of the first element in the ResizeArray that satisfies the given indexed predicate.
|
||
Full Usage:
tryHead resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T option
The first element of the ResizeArray or None .
|
Returns the first element of the ResizeArray, or
|
||
Full Usage:
tryItem index resizeArray
Parameters:
int
-
The index of element to retrieve.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T option
The nth element of the ResizeArray or None .
|
Tries to find the nth element in the ResizeArray.
Returns
|
||
Full Usage:
tryLast resizeArray
Parameters:
ResizeArray<'T>
-
The input ResizeArray.
Returns: 'T option
The last element of the ResizeArray or None .
|
Returns the last element of the ResizeArray.
Return
|
||
Full Usage:
tryPick chooser resizeArray
Parameters:
'T -> 'a option
-
The function to transform the ResizeArray elements into options.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: 'a option
The first transformed element that is Some(x) .
|
Applies the given function to successive elements, returning the first
result where function returns
|
||
Full Usage:
unfold generator state
Parameters:
'State -> ('T * 'State) option
-
A function that takes in the current state and returns an option tuple of the next
element of the ResizeArray and the next state value.
state : 'State
-
The initial state value.
Returns: ResizeArray<'T>
The result ResizeArray.
|
Returns a ResizeArray that contains the elements generated by the given computation.
The given initial
|
||
Full Usage:
unzip resizeArray
Parameters:
ResizeArray<'T * 'U>
-
The input ResizeArray.
Returns: ResizeArray<'T> * ResizeArray<'U>
The two ResizeArrays.
|
Splits a ResizeArray of pairs into two ResizeArrays.
|
||
Full Usage:
unzip3 resizeArray
Parameters:
ResizeArray<'T * 'U * 'V>
-
The input ResizeArray.
Returns: ResizeArray<'T> * ResizeArray<'U> * ResizeArray<'V>
The tuple of three ResizeArrays.
|
Splits a ResizeArray of triples into three ResizeArrays.
|
||
Full Usage:
updateAt index value resizeArray
Parameters:
int
-
The index of the item to be replaced.
value : 'T
-
The new value.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<'T>
The result ResizeArray.
|
Return a new ResizeArray with the item at a given index set to the new value. (does NOT modify in place !)
|
||
Full Usage:
where predicate resizeArray
Parameters:
'T -> bool
-
The function to test the input elements.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: List<'T>
a ResizeArray containing the elements for which the given predicate returns true.
|
Returns a new ResizeArray containing only the elements of the ResizeArray
for which the given predicate returns
|
||
Full Usage:
windowed windowSize resizeArray
Parameters:
int
-
The number of elements in each window.
resizeArray : ResizeArray<'T>
-
The input ResizeArray.
Returns: ResizeArray<List<'T>>
The result ResizeArray.
|
Returns a ResizeArray of sliding windows containing elements drawn from the input ResizeArray. Each window is returned as a fresh ResizeArray.
|
||
Full Usage:
windowed2 resizeArray
Parameters:
ResizeArray<'T>
Returns: ('T * 'T) seq
|
Yields Seq from (first, second) up to (second-last, last). Not looped. The resulting seq is one element shorter than the input ResizeArray.
|
||
Full Usage:
windowed2i resizeArray
Parameters:
ResizeArray<'T>
Returns: (int * 'T * 'T) seq
|
Yields Seq from (0,first, second) up to (lastIndex-1 , second-last, last). Not looped. The resulting seq is one element shorter than the input ResizeArray.
|
||
Full Usage:
windowed3 resizeArray
Parameters:
ResizeArray<'T>
Returns: ('T * 'T * 'T) seq
|
Yields Seq from (first, second, third) up to (third-last, second-last, last). Not looped. The resulting seq is two elements shorter than the input ResizeArray.
|
||
Full Usage:
windowed3i resizeArray
Parameters:
ResizeArray<'T>
Returns: (int * 'T * 'T * 'T) seq
|
Yields Seq from (1, first, second, third) up to (lastIndex-1 , third-last, second-last, last). Not looped. The resulting seq is two elements shorter than the input ResizeArray.
|
||
Full Usage:
zip resizeArray1 resizeArray2
Parameters:
ResizeArray<'T>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'U>
-
The second input ResizeArray.
Returns: ResizeArray<'T * 'U>
The ResizeArray of tupled elements.
|
Combines the two ResizeArrays into a ResizeArray of pairs. The two ResizeArrays must have equal lengths, otherwise an
|
||
Full Usage:
zip3 resizeArray1 resizeArray2 resizeArray3
Parameters:
ResizeArray<'T>
-
The first input ResizeArray.
resizeArray2 : ResizeArray<'U>
-
The second input ResizeArray.
resizeArray3 : ResizeArray<'V>
-
The third input ResizeArray.
Returns: ResizeArray<'T * 'U * 'V>
The ResizeArray of tupled elements.
|
Combines three ResizeArrays into a ResizeArray of pairs. The three ResizeArrays must have equal lengths, otherwise an
|