every((value: Annotation, index: number, array: Annotation[]) => unknown, any)

确定数组的所有成员是否都满足指定的测试。

every<S>((value: Annotation, index: number, array: Annotation[]) => value, any)

确定数组的所有成员是否都满足指定的测试。

fill(Annotation, number, number)

将所有数组元素从 start 更改为 end 索引,并 value 返回修改后的数组

filter((value: Annotation, index: number, array: Annotation[]) => unknown, any)

返回数组中满足回调函数中指定的条件的元素。

filter<S>((value: Annotation, index: number, array: Annotation[]) => value, any)

返回数组中满足回调函数中指定的条件的元素。

find((value: Annotation, index: number, obj: Annotation[]) => unknown, any) find<S>((this: void, value: Annotation, index: number, obj: Annotation[]) => value, any)

返回数组中谓词为 true 且未定义的第一个元素的值。

find Index((value: Annotation, index: number, obj: Annotation[]) => unknown, any)

返回数组中谓词为 true 的第一个元素的索引,否则返回 -1。

flat<A, D>(A, D)

返回一个新数组,该数组的所有子数组元素都以递归方式连接到该数组,以递归方式连接到指定深度。

flat Map<U, This>((this: This, value: Annotation, index: number, array: Annotation[]) => U | (readonly U[]), This)

对数组的每个元素调用定义的回调函数。 然后,将结果平展为新数组。 这与后接深度为 1 的平面图相同。

for Each((value: Annotation, index: number, array: Annotation[]) => void, any)

为数组中的每个元素执行指定操作。

includes(Annotation, number)

确定数组是包含特定元素,并根据需要返回 true 还是 false。

index Of(Annotation, number)

返回数组中值第一个匹配项的索引;如果不存在值,则返回 -1。

join(string)

将数组的所有元素添加到字符串中,用指定的分隔符字符串分隔。

keys()

返回数组中键的可迭代值

last Index Of(Annotation, number)

返回数组中指定值最后一次出现的索引;如果不存在,则返回 -1。

map<U>((value: Annotation, index: number, array: Annotation[]) => U, any)

对数组的每个元素调用定义的回调函数并返回包含结果的数组。

pop()

从数组中移除最后一个元素并将该元素返回。 如果数组为空,则返回 undefined,并且不修改数组。

push(Annotation[])

将新元素追加到数组的末尾,并返回数组的新长度。

reduce((previous Value: Annotation, current Value: Annotation, current Index: number, array: Annotation[]) => Annotation)

为数组中的所有元素调用指定的回调函数。 回调函数的返回值是累积的结果,并且作为对回调函数的下一个调用中的参数提供。

reduce((previous Value: Annotation, current Value: Annotation, current Index: number, array: Annotation[]) => Annotation, Annotation) reduce<U>((previous Value: U, current Value: Annotation, current Index: number, array: Annotation[]) => U, U)

为数组中的所有元素调用指定的回调函数。 回调函数的返回值是累积的结果,并且作为对回调函数的下一个调用中的参数提供。

reduce Right((previous Value: Annotation, current Value: Annotation, current Index: number, array: Annotation[]) => Annotation)

以降序为数组中的所有元素调用指定的回调函数。 回调函数的返回值是累积的结果,并且作为对回调函数的下一个调用中的参数提供。

reduce Right((previous Value: Annotation, current Value: Annotation, current Index: number, array: Annotation[]) => Annotation, Annotation) reduce Right<U>((previous Value: U, current Value: Annotation, current Index: number, array: Annotation[]) => U, U)

以降序为数组中的所有元素调用指定的回调函数。 回调函数的返回值是累积的结果,并且作为对回调函数的下一个调用中的参数提供。

reverse()

将数组中的元素原位反转。 此方法改变数组并返回对同一数组的引用。

shift()

从数组中移除第一个元素并将返回该元素。 如果数组为空,则返回 undefined,并且不修改数组。

slice(number, number)

返回数组部分的副本。 对于 start 和 end,可以使用负索引来指示与数组末尾的偏移量。 例如,-2 引用数组的第二个到最后一个元素。

some((value: Annotation, index: number, array: Annotation[]) => unknown, any)

确定指定的回调函数是否为数组的任何元素返回 true。

sort((a: Annotation, b: Annotation) => number)

就地对数组进行排序。 此方法改变数组并返回对同一数组的引用。

splice(number, number)

从一个数组中移除元素,如有必要,在所移除元素的位置上插入新元素,并返回所移除的元素。

splice(number, number, Annotation[])

从一个数组中移除元素,如有必要,在所移除元素的位置上插入新元素,并返回所移除的元素。

to Locale String()

返回数组的字符串表示形式。 元素使用其 toLocaleString 方法转换为字符串。

to String()

返回数组的字符串表示形式。

unshift(Annotation[])

在数组的开头插入新元素,并返回数组的新长度。

values()

返回数组中值的可迭代值

[iterator]() [unscopables]()

返回一个 对象,其属性在“with”语句中使用时将不存在时其属性的值为“true”。

function copyWithin(target: number, start: number, end?: number): AnnotationsListResult
target

number

如果 target 为负数,则将其视为 length+target,其中 length 是数组的长度。

start

number

如果 start 为负数,则将其视为 length+start。 如果 end 为负值,则将其视为 length+end。

number

如果未指定,则使用此对象的长度作为其默认值。

AnnotationsListResult
function every(predicate: (value: Annotation, index: number, array: Annotation[]) => unknown, thisArg?: any): boolean
predicate

(value: Annotation, index: number, array: Annotation[]) => unknown

最多可以接受三个参数的函数。 每个方法调用数组中每个元素的谓词函数,直到谓词返回一个可强制为布尔值 false 的值,或直到数组的末尾。

thisArg

此关键字 (keyword) 可以在谓词函数中引用的 对象。 如果省略 thisArg,则将 undefined 用作此值。

boolean

function every<S>(predicate: (value: Annotation, index: number, array: Annotation[]) => value, thisArg?: any): this
predicate

(value: Annotation, index: number, array: Annotation[]) => value

最多可以接受三个参数的函数。 每个方法调用数组中每个元素的谓词函数,直到谓词返回一个可强制为布尔值 false 的值,或直到数组的末尾。

thisArg

此关键字 (keyword) 可以在谓词函数中引用的 对象。 如果省略 thisArg,则将 undefined 用作此值。

function filter(predicate: (value: Annotation, index: number, array: Annotation[]) => unknown, thisArg?: any): Annotation[]
predicate

(value: Annotation, index: number, array: Annotation[]) => unknown

最多可以接受三个参数的函数。 filter 方法为数组中的每个元素调用谓词函数一次。

thisArg

此关键字 (keyword) 可以在谓词函数中引用的 对象。 如果省略 thisArg,则将 undefined 用作此值。

Annotation []

function filter<S>(predicate: (value: Annotation, index: number, array: Annotation[]) => value, thisArg?: any): S[]
predicate

(value: Annotation, index: number, array: Annotation[]) => value

最多可以接受三个参数的函数。 filter 方法为数组中的每个元素调用谓词函数一次。

thisArg

此关键字 (keyword) 可以在谓词函数中引用的 对象。 如果省略 thisArg,则将 undefined 用作此值。

function find(predicate: (value: Annotation, index: number, obj: Annotation[]) => unknown, thisArg?: any): undefined | Annotation
predicate

(value: Annotation, index: number, obj: Annotation[]) => unknown

function find<S>(predicate: (this: void, value: Annotation, index: number, obj: Annotation[]) => value, thisArg?: any): undefined | S
predicate

(this: void, value: Annotation, index: number, obj: Annotation[]) => value

find 按升序为数组的每个元素调用一次谓词,直到找到谓词返回 true 的谓词。 如果找到此类元素,find 将立即返回该元素值。 否则,find 返回未定义。

thisArg

如果提供,则它将用作谓词每次调用的此值。 如果未提供,则改用 undefined。

undefined | S

function findIndex(predicate: (value: Annotation, index: number, obj: Annotation[]) => unknown, thisArg?: any): number
predicate

(value: Annotation, index: number, obj: Annotation[]) => unknown

find 按升序为数组的每个元素调用一次谓词,直到找到谓词返回 true 的谓词。 如果找到此类元素,findIndex 将立即返回该元素索引。 否则,findIndex 返回 -1。

thisArg

如果提供,则它将用作谓词每次调用的此值。 如果未提供,则改用 undefined。

number

function flatMap<U, This>(callback: (this: This, value: Annotation, index: number, array: Annotation[]) => U | (readonly U[]), thisArg?: This): U[]
callback

(this: This, value: Annotation, index: number, array: Annotation[]) => U | (readonly U[])

最多可以接受三个参数的函数。 flatMap 方法为数组中的每个元素调用回调函数一次。

thisArg

此关键字 (keyword) 可以在回调函数中引用的 对象。 如果省略 thisArg,则将 undefined 用作此值。

function forEach(callbackfn: (value: Annotation, index: number, array: Annotation[]) => void, thisArg?: any)
callbackfn

(value: Annotation, index: number, array: Annotation[]) => void

最多可以接受三个参数的函数。 forEach 为数组中的每个元素调用一次 callbackfn 函数。

thisArg

此关键字 (keyword) 可以在 callbackfn 函数中引用的 对象。 如果省略 thisArg,则将 undefined 用作此值。

function map<U>(callbackfn: (value: Annotation, index: number, array: Annotation[]) => U, thisArg?: any): U[]
callbackfn

(value: Annotation, index: number, array: Annotation[]) => U

最多可以接受三个参数的函数。 map 方法为数组中的每个元素调用一次 callbackfn 函数。

thisArg

此关键字 (keyword) 可以在 callbackfn 函数中引用的 对象。 如果省略 thisArg,则将 undefined 用作此值。

function reduce(callbackfn: (previousValue: Annotation, currentValue: Annotation, currentIndex: number, array: Annotation[]) => Annotation): Annotation
callbackfn

(previousValue: Annotation, currentValue: Annotation, currentIndex: number, array: Annotation[]) => Annotation

一个最多接受四个参数的函数。 reduce 方法为数组中的每个元素调用一次 callbackfn 函数。

Annotation
function reduce(callbackfn: (previousValue: Annotation, currentValue: Annotation, currentIndex: number, array: Annotation[]) => Annotation, initialValue: Annotation): Annotation
callbackfn

(previousValue: Annotation, currentValue: Annotation, currentIndex: number, array: Annotation[]) => Annotation

function reduce<U>(callbackfn: (previousValue: U, currentValue: Annotation, currentIndex: number, array: Annotation[]) => U, initialValue: U): U
callbackfn

(previousValue: U, currentValue: Annotation, currentIndex: number, array: Annotation[]) => U

一个最多接受四个参数的函数。 reduce 方法为数组中的每个元素调用一次 callbackfn 函数。

initialValue

如果指定了 initialValue,则将其用作开始累积的初始值。 对 callbackfn 函数的第一次调用将此值作为参数提供,而不是数组值。

function reduceRight(callbackfn: (previousValue: Annotation, currentValue: Annotation, currentIndex: number, array: Annotation[]) => Annotation): Annotation
callbackfn

(previousValue: Annotation, currentValue: Annotation, currentIndex: number, array: Annotation[]) => Annotation

一个最多接受四个参数的函数。 reduceRight 方法为数组中的每个元素调用回调fn 函数一次。

Annotation
function reduceRight(callbackfn: (previousValue: Annotation, currentValue: Annotation, currentIndex: number, array: Annotation[]) => Annotation, initialValue: Annotation): Annotation
callbackfn

(previousValue: Annotation, currentValue: Annotation, currentIndex: number, array: Annotation[]) => Annotation

function reduceRight<U>(callbackfn: (previousValue: U, currentValue: Annotation, currentIndex: number, array: Annotation[]) => U, initialValue: U): U
callbackfn

(previousValue: U, currentValue: Annotation, currentIndex: number, array: Annotation[]) => U

一个最多接受四个参数的函数。 reduceRight 方法为数组中的每个元素调用回调fn 函数一次。

initialValue

如果指定了 initialValue,则将其用作开始累积的初始值。 对 callbackfn 函数的第一次调用将此值作为参数提供,而不是数组值。

function some(predicate: (value: Annotation, index: number, array: Annotation[]) => unknown, thisArg?: any): boolean
predicate

(value: Annotation, index: number, array: Annotation[]) => unknown

最多可以接受三个参数的函数。 一些 方法为数组中的每个元素调用谓词函数,直到谓词返回一个可强制转换为布尔值 true 的值,或直到数组的末尾。

thisArg

此关键字 (keyword) 可以在谓词函数中引用的 对象。 如果省略 thisArg,则将 undefined 用作此值。

boolean

function sort(compareFn?: (a: Annotation, b: Annotation) => number): AnnotationsListResult
compareFn

(a: Annotation, b: Annotation) => number

用于确定元素顺序的函数。 如果第一个参数小于第二个参数,则应返回负值;如果相等,则返回零;否则返回正值。 如果省略,则元素按升序 ASCII 字符顺序排序。

[11,2,22,1].sort((a, b) => a - b)
					AnnotationsListResult
			
function [unscopables](): { copyWithin: boolean, entries: boolean, fill: boolean, find: boolean, findIndex: boolean, keys: boolean, values: boolean }

{ copyWithin: boolean, entries: boolean, fill: boolean, find: boolean, findIndex: boolean, keys: boolean, values: boolean }