mirror of
https://gitee.com/openharmony/interface_sdk-js
synced 2024-11-23 07:10:52 +00:00
update container exception information
Signed-off-by: liu-ganlin <liuganlin@huawei.com>
This commit is contained in:
parent
48e67bd8e8
commit
d5a798266f
74
api/@ohos.util.ArrayList.d.ts
vendored
74
api/@ohos.util.ArrayList.d.ts
vendored
@ -16,7 +16,7 @@
|
||||
declare class ArrayList<T> {
|
||||
/**
|
||||
* A constructor used to create a ArrayList object.
|
||||
* @throws {NewTargetIsNullError}: The ArrayList's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 10200012 - The ArrayList's constructor cannot be directly invoked.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -31,7 +31,7 @@ declare class ArrayList<T> {
|
||||
* Appends the specified element to the end of this arraylist.
|
||||
* @param element to be appended to this arraylist
|
||||
* @returns the boolean type, returns true if the addition is successful, and returns false if it fails.
|
||||
* @throws {ContainerBindError}: The add method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The add method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -42,9 +42,9 @@ declare class ArrayList<T> {
|
||||
* any subsequent elements to the right (adds one to their index).
|
||||
* @param index index at which the specified element is to be inserted
|
||||
* @param element element to be inserted
|
||||
* @throws {ContainerBindError}: The insert method cannot be bound.
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length]. Received value is: [index]
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The insert method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length]. Received value is: [index]
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -53,7 +53,7 @@ declare class ArrayList<T> {
|
||||
* Check if arraylist contains the specified element
|
||||
* @param element element to be contained
|
||||
* @return the boolean type,if arraylist contains the specified element,return true,else return false
|
||||
* @throws {ContainerBindError}: The has method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The has method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -63,7 +63,7 @@ declare class ArrayList<T> {
|
||||
* in this arraylist, or -1 if this arraylist does not contain the element.
|
||||
* @param element element to be contained
|
||||
* @return the number type ,returns the lowest index such that or -1 if there is no such index.
|
||||
* @throws {ContainerBindError}: The getIndexOf method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getIndexOf method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -73,9 +73,9 @@ declare class ArrayList<T> {
|
||||
* delete the element, and move the index of all elements to the right of the element forward by one.
|
||||
* @param index the index in the arraylist
|
||||
* @return the T type ,returns undefined if arraylist is empty,If the index is
|
||||
* @throws {ContainerBindError}: The removeByIndex method cannot be bound.
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The removeByIndex method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -86,7 +86,7 @@ declare class ArrayList<T> {
|
||||
* unchanged. More formally, removes the element with the lowest index
|
||||
* @param element element to remove
|
||||
* @return the boolean type ,If there is no such element, return false
|
||||
* @throws {ContainerBindError}: The remove method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The remove method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -96,7 +96,7 @@ declare class ArrayList<T> {
|
||||
* or -1 if the arraylist does not contain the element.
|
||||
* @param element element to find
|
||||
* @return the number type
|
||||
* @throws {ContainerBindError}: The getLastIndexOf method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getLastIndexOf method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -105,11 +105,11 @@ declare class ArrayList<T> {
|
||||
* Removes from this arraylist all of the elements whose index is between fromIndex,inclusive,and toIndex ,exclusive.
|
||||
* @param fromIndex The starting position of the index, containing the value at that index position
|
||||
* @param toIndex the end of the index, excluding the value at that index
|
||||
* @throws {ContainerBindError}: The removeByRange method cannot be bound.
|
||||
* @throws {RangeError}: The value of "fromIndex" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [fromIndex]
|
||||
* @throws {RangeError}: The value of "toIndex" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [toIndex]
|
||||
* @throws {TypeError}: The type of "fromIndex" must be number. Received value is: [fromIndex]
|
||||
* @throws {TypeError}: The type of "toIndex" must be number. Received value is: [toIndex]
|
||||
* @throws { BusinessError } 10200011 - The removeByRange method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "fromIndex" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [fromIndex]
|
||||
* @throws { BusinessError } 10200001 - The value of "toIndex" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [toIndex]
|
||||
* @throws { BusinessError } 401 - The type of "fromIndex" must be number. Received value is: [fromIndex]
|
||||
* @throws { BusinessError } 401 - The type of "toIndex" must be number. Received value is: [toIndex]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -123,8 +123,8 @@ declare class ArrayList<T> {
|
||||
* @param arrlist (Optional) The arraylist object to which the current element belongs.
|
||||
* @param thisArg (Optional) The value passed to the function generally uses the "this" value.
|
||||
* If this parameter is empty, "undefined" will be passed to the "this" value
|
||||
* @throws {ContainerBindError}: The replaceAllElements method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The replaceAllElements method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -139,8 +139,8 @@ declare class ArrayList<T> {
|
||||
* @param arrlist (Optional) The arraylist object to which the current element belongs.
|
||||
* @param thisArg (Optional) The value passed to the function generally uses the "this" value.
|
||||
* If this parameter is empty, "undefined" will be passed to the "this" value
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -155,8 +155,8 @@ declare class ArrayList<T> {
|
||||
* @param firstValue (Optional) previous element
|
||||
* @param secondValue (Optional) next elements
|
||||
* If this parameter is empty, it will default to ASCII sorting
|
||||
* @throws {ContainerBindError}: The sort method cannot be bound.
|
||||
* @throws {TypeError}: The type of "comparator" must be callable. Received value is: [comparator]
|
||||
* @throws { BusinessError } 10200011 - The sort method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "comparator" must be callable. Received value is: [comparator]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -165,11 +165,11 @@ declare class ArrayList<T> {
|
||||
* Returns a view of the portion of this arraylist between the specified fromIndex,inclusize,and toIndex,exclusive
|
||||
* @param fromIndex The starting position of the index, containing the value at that index position
|
||||
* @param toIndex the end of the index, excluding the value at that index
|
||||
* @throws {ContainerBindError}: The subArrayList method cannot be bound.
|
||||
* @throws {RangeError}: The value of "fromIndex" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [fromIndex]
|
||||
* @throws {RangeError}: The value of "toIndex" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [toIndex]
|
||||
* @throws {TypeError}: The type of "fromIndex" must be number. Received value is: [fromIndex]
|
||||
* @throws {TypeError}: The type of "toIndex" must be number. Received value is: [toIndex]
|
||||
* @throws { BusinessError } 10200011 - The subArrayList method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "fromIndex" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [fromIndex]
|
||||
* @throws { BusinessError } 10200001 - The value of "toIndex" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [toIndex]
|
||||
* @throws { BusinessError } 401 - The type of "fromIndex" must be number. Received value is: [fromIndex]
|
||||
* @throws { BusinessError } 401 - The type of "toIndex" must be number. Received value is: [toIndex]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -177,7 +177,7 @@ declare class ArrayList<T> {
|
||||
/**
|
||||
* Removes all of the elements from this arraylist.The arraylist will
|
||||
* be empty after this call returns.length becomes 0
|
||||
* @throws {ContainerBindError}: The clear method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clear method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -185,7 +185,7 @@ declare class ArrayList<T> {
|
||||
/**
|
||||
* Returns a shallow copy of this instance. (The elements themselves are not copied.)
|
||||
* @return this arraylist instance
|
||||
* @throws {ContainerBindError}: The clone method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clone method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -193,7 +193,7 @@ declare class ArrayList<T> {
|
||||
/**
|
||||
* returns the capacity of this arraylist
|
||||
* @return the number type
|
||||
* @throws {ContainerBindError}: The getCapacity method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getCapacity method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -201,7 +201,7 @@ declare class ArrayList<T> {
|
||||
/**
|
||||
* convert arraylist to array
|
||||
* @return the Array type
|
||||
* @throws {ContainerBindError}: The convertToArray method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The convertToArray method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -209,7 +209,7 @@ declare class ArrayList<T> {
|
||||
/**
|
||||
* Determine whether arraylist is empty and whether there is an element
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The isEmpty method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The isEmpty method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -217,22 +217,22 @@ declare class ArrayList<T> {
|
||||
/**
|
||||
* If the newCapacity provided by the user is greater than or equal to length,
|
||||
* change the capacity of the arraylist to newCapacity, otherwise the capacity will not be changed
|
||||
* @throws {ContainerBindError}: The increaseCapacityTo method cannot be bound.
|
||||
* @throws {TypeError}: The type of "newCapacity" must be number. Received value is: [newCapacity]
|
||||
* @throws { BusinessError } 10200011 - The increaseCapacityTo method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "newCapacity" must be number. Received value is: [newCapacity]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
increaseCapacityTo(newCapacity: number): void;
|
||||
/**
|
||||
* Limit the capacity to the current length
|
||||
* @throws {ContainerBindError}: The trimToCurrentLength method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The trimToCurrentLength method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
trimToCurrentLength(): void;
|
||||
/**
|
||||
* returns an iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
22
api/@ohos.util.Deque.d.ts
vendored
22
api/@ohos.util.Deque.d.ts
vendored
@ -16,7 +16,7 @@
|
||||
declare class Deque<T> {
|
||||
/**
|
||||
* A constructor used to create a Deque object.
|
||||
* @throws {NewTargetIsNullError}: The Deque's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 10200012 - The Deque's constructor cannot be directly invoked.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -30,7 +30,7 @@ declare class Deque<T> {
|
||||
/**
|
||||
* Inserts an element into the deque header.
|
||||
* @param element to be appended to this deque
|
||||
* @throws {ContainerBindError}: The insertFront method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The insertFront method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -38,7 +38,7 @@ declare class Deque<T> {
|
||||
/**
|
||||
* Inserting an element at the end of a deque
|
||||
* @param element to be appended to this deque
|
||||
* @throws {ContainerBindError}: The insertEnd method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The insertEnd method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -47,7 +47,7 @@ declare class Deque<T> {
|
||||
* Check if deque contains the specified element
|
||||
* @param element element to be contained
|
||||
* @return the boolean type,if deque contains the specified element,return true,else return false
|
||||
* @throws {ContainerBindError}: The has method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The has method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -55,7 +55,7 @@ declare class Deque<T> {
|
||||
/**
|
||||
* Obtains the header element of a deque.
|
||||
* @return the T type
|
||||
* @throws {ContainerBindError}: The getFirst method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getFirst method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -63,7 +63,7 @@ declare class Deque<T> {
|
||||
/**
|
||||
* Obtains the end element of a deque.
|
||||
* @return the T type
|
||||
* @throws {ContainerBindError}: The getLast method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getLast method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -71,7 +71,7 @@ declare class Deque<T> {
|
||||
/**
|
||||
* Obtains the header element of a deque and delete the element.
|
||||
* @return the T type
|
||||
* @throws {ContainerBindError}: The popFirst method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The popFirst method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -79,7 +79,7 @@ declare class Deque<T> {
|
||||
/**
|
||||
* Obtains the end element of a deque and delete the element.
|
||||
* @return the T type
|
||||
* @throws {ContainerBindError}: The popLast method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The popLast method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -92,8 +92,8 @@ declare class Deque<T> {
|
||||
* @param deque (Optional) The deque object to which the current element belongs.
|
||||
* @param thisArg (Optional) The value passed to the function generally uses the "this" value.
|
||||
* If this parameter is empty, "undefined" will be passed to the "this" value
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -101,7 +101,7 @@ declare class Deque<T> {
|
||||
thisArg?: Object): void;
|
||||
/**
|
||||
* returns an iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
36
api/@ohos.util.HashMap.d.ts
vendored
36
api/@ohos.util.HashMap.d.ts
vendored
@ -16,7 +16,7 @@
|
||||
declare class HashMap<K, V> {
|
||||
/**
|
||||
* A constructor used to create a HashMap object.
|
||||
* @throws {NewTargetIsNullError}: The HashMap's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 10200012 - The HashMap's constructor cannot be directly invoked.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -30,7 +30,7 @@ declare class HashMap<K, V> {
|
||||
/**
|
||||
* Returns whether the Map object contains elements
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The isEmpty method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The isEmpty method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -39,7 +39,7 @@ declare class HashMap<K, V> {
|
||||
* Returns whether a key is contained in this map
|
||||
* @param key need to determine whether to include the key
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The hasKey method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The hasKey method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -48,7 +48,7 @@ declare class HashMap<K, V> {
|
||||
* Returns whether a value is contained in this map
|
||||
* @param value need to determine whether to include the value
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The hasValue method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The hasValue method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -57,7 +57,7 @@ declare class HashMap<K, V> {
|
||||
* Returns a specified element in a Map object, or null if there is no corresponding element
|
||||
* @param key the index in HashMap
|
||||
* @return value or null
|
||||
* @throws {ContainerBindError}: The get method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The get method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -65,8 +65,8 @@ declare class HashMap<K, V> {
|
||||
/**
|
||||
* Adds all element groups in one map to another map
|
||||
* @param map the Map object to add members
|
||||
* @throws {ContainerBindError}: The setAll method cannot be bound.
|
||||
* @throws {TypeError}: The type of "map" must be HashMap. Received value is: [map]
|
||||
* @throws { BusinessError } 10200011 - The setAll method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "map" must be HashMap. Received value is: [map]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -76,8 +76,8 @@ declare class HashMap<K, V> {
|
||||
* @param key Added or updated targets
|
||||
* @param value Added or updated value
|
||||
* @returns the map object after set
|
||||
* @throws {ContainerBindError}: The set method cannot be bound.
|
||||
* @throws {TypeError}: The type of "key" must be not null. Received value is: [key]
|
||||
* @throws { BusinessError } 10200011 - The set method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "key" must be not null. Received value is: [key]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -86,28 +86,28 @@ declare class HashMap<K, V> {
|
||||
* Remove a specified element from a Map object
|
||||
* @param key Target to be deleted
|
||||
* @return Target mapped value
|
||||
* @throws {ContainerBindError}: The remove method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The remove method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
remove(key: K): V;
|
||||
/**
|
||||
* Clear all element groups in the map
|
||||
* @throws {ContainerBindError}: The clear method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clear method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
clear(): void;
|
||||
/**
|
||||
* Returns a new Iterator object that contains the keys contained in this map
|
||||
* @throws {ContainerBindError}: The keys method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The keys method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
keys(): IterableIterator<K>;
|
||||
/**
|
||||
* Returns a new Iterator object that contains the values contained in this map
|
||||
* @throws {ContainerBindError}: The values method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The values method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -117,7 +117,7 @@ declare class HashMap<K, V> {
|
||||
* @param key Updated targets
|
||||
* @param newValue Updated the target mapped value
|
||||
* @returns the boolean type(Is there a target pointed to by the key)
|
||||
* @throws {ContainerBindError}: The replace method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The replace method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -125,8 +125,8 @@ declare class HashMap<K, V> {
|
||||
/**
|
||||
* Executes the given callback function once for each real key in the map.
|
||||
* It does not perform functions on deleted keys
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -134,14 +134,14 @@ declare class HashMap<K, V> {
|
||||
thisArg?: Object): void;
|
||||
/**
|
||||
* Returns a new Iterator object that contains the [key, value] pairs for each element in the Map object in insertion order
|
||||
* @throws {ContainerBindError}: The entries method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The entries method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
entries(): IterableIterator<[K, V]>;
|
||||
/**
|
||||
* returns an iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
28
api/@ohos.util.HashSet.d.ts
vendored
28
api/@ohos.util.HashSet.d.ts
vendored
@ -16,7 +16,7 @@
|
||||
declare class HashSet<T> {
|
||||
/**
|
||||
* A constructor used to create a HashSet object.
|
||||
* @throws {NewTargetIsNullError}: The HashSet's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 10200012 - The HashSet's constructor cannot be directly invoked.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -30,7 +30,7 @@ declare class HashSet<T> {
|
||||
/**
|
||||
* Returns whether the Set object contains elements
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The isEmpty method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The isEmpty method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -39,8 +39,8 @@ declare class HashSet<T> {
|
||||
* Returns whether the Set object contain s the elements
|
||||
* @param value need to determine whether to include the element
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The has method cannot be bound.
|
||||
* @throws {TypeError}: The type of "value" must be not null. Received value is: [value]
|
||||
* @throws { BusinessError } 10200011 - The has method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "value" must be not null. Received value is: [value]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -49,8 +49,8 @@ declare class HashSet<T> {
|
||||
* If the set does not contain the element, the specified element is added
|
||||
* @param value Added element
|
||||
* @returns the boolean type(Is there contain this element)
|
||||
* @throws {ContainerBindError}: The add method cannot be bound.
|
||||
* @throws {TypeError}: The type of "value" must be not null. Received value is: [value]
|
||||
* @throws { BusinessError } 10200011 - The add method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "value" must be not null. Received value is: [value]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -59,23 +59,23 @@ declare class HashSet<T> {
|
||||
* Remove a specified element from a Set object
|
||||
* @param value Target to be deleted
|
||||
* @return the boolean type(Is there contain this element)
|
||||
* @throws {ContainerBindError}: The remove method cannot be bound.
|
||||
* @throws {TypeError}: The type of "value" must be not null. Received value is: [value]
|
||||
* @throws { BusinessError } 10200011 - The remove method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "value" must be not null. Received value is: [value]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
remove(value: T): boolean;
|
||||
/**
|
||||
* Clears all element groups in a set
|
||||
* @throws {ContainerBindError}: The clear method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clear method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
clear(): void;
|
||||
/**
|
||||
* Executes a provided function once for each value in the Set object.
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -83,21 +83,21 @@ declare class HashSet<T> {
|
||||
thisArg?: Object): void;
|
||||
/**
|
||||
* Returns a new Iterator object that contains the values contained in this set
|
||||
* @throws {ContainerBindError}: The values method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The values method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
values(): IterableIterator<T>;
|
||||
/**
|
||||
* Returns a new Iterator object that contains the [key, value] pairs for each element in the Set object in insertion order
|
||||
* @throws {ContainerBindError}: The entries method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The entries method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
entries(): IterableIterator<[T, T]>;
|
||||
/**
|
||||
* returns an iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
68
api/@ohos.util.LightWeightMap.d.ts
vendored
68
api/@ohos.util.LightWeightMap.d.ts
vendored
@ -16,7 +16,7 @@
|
||||
declare class LightWeightMap<K, V> {
|
||||
/**
|
||||
* A constructor used to create a LightWeightMap object.
|
||||
* @throws {NewTargetIsNullError}: The LightWeightMap's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 10200012 - The LightWeightMap's constructor cannot be directly invoked.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -31,8 +31,8 @@ declare class LightWeightMap<K, V> {
|
||||
* Returns whether this map has all the object in a specified map
|
||||
* @param map the Map object to compare
|
||||
* @return the boolean type
|
||||
* @throws {TypeError}: The type of "map" must be LightWeightMap. Received value is: [map]
|
||||
* @throws {ContainerBindError}: The hasAll method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "map" must be LightWeightMap. Received value is: [map]
|
||||
* @throws { BusinessError } 10200011 - The hasAll method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -41,7 +41,7 @@ declare class LightWeightMap<K, V> {
|
||||
* Returns whether a key is contained in this map
|
||||
* @param key need to determine whether to include the key
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The hasKey method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The hasKey method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -50,7 +50,7 @@ declare class LightWeightMap<K, V> {
|
||||
* Returns whether a value is contained in this map
|
||||
* @param value need to determine whether to include the value
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The hasValue method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The hasValue method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -59,15 +59,15 @@ declare class LightWeightMap<K, V> {
|
||||
* Ensures that the capacity of an LightWeightMap container is greater than or equal to a apecified value,
|
||||
* and that the container has all the original objects after capacity expansion
|
||||
* @param minimumCapacity Minimum capacity to be reserved
|
||||
* @throws {ContainerBindError}: The increaseCapacityTo method cannot be bound.
|
||||
* @throws {TypeError}: The type of "minimumCapacity" must be number. Received value is: [minimumCapacity]
|
||||
* @throws { BusinessError } 10200011 - The increaseCapacityTo method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "minimumCapacity" must be number. Received value is: [minimumCapacity]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
increaseCapacityTo(minimumCapacity: number): void;
|
||||
/**
|
||||
* Returns a new Iterator object that contains the [key, value] pairs for each element in the Map object in insertion order
|
||||
* @throws {ContainerBindError}: The entries method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The entries method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -76,7 +76,7 @@ declare class LightWeightMap<K, V> {
|
||||
* Returns the value to which the specified key is mapped, or undefined if this map contains no mapping for the key
|
||||
* @param key the index in LightWeightMap
|
||||
* @return value or undefined
|
||||
* @throws {ContainerBindError}: The get method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The get method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -85,7 +85,7 @@ declare class LightWeightMap<K, V> {
|
||||
* Obtains the index of the key equal to a specified key in an LightWeightMap container
|
||||
* @param key Looking for goals
|
||||
* @return Subscript corresponding to target
|
||||
* @throws {ContainerBindError}: The getIndexOfKey method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getIndexOfKey method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -94,7 +94,7 @@ declare class LightWeightMap<K, V> {
|
||||
* Obtains the index of the value equal to a specified value in an LightWeightMap container
|
||||
* @param value Looking for goals
|
||||
* @return Subscript corresponding to target
|
||||
* @throws {ContainerBindError}: The getIndexOfValue method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getIndexOfValue method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -102,7 +102,7 @@ declare class LightWeightMap<K, V> {
|
||||
/**
|
||||
* Returns whether the Map object contains elements
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The isEmpty method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The isEmpty method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -111,16 +111,16 @@ declare class LightWeightMap<K, V> {
|
||||
* Obtains the key at the loaction identified by index in an LightWeightMap container
|
||||
* @param index Target subscript for search
|
||||
* @return the key of key-value pairs
|
||||
* @throws {ContainerBindError}: The getKeyAt method cannot be bound.
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The getKeyAt method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
getKeyAt(index: number): K;
|
||||
/**
|
||||
* Obtains a ES6 iterator that contains all the keys of an LightWeightMap container
|
||||
* @throws {ContainerBindError}: The keys method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The keys method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -128,8 +128,8 @@ declare class LightWeightMap<K, V> {
|
||||
/**
|
||||
* Adds all element groups in one map to another map
|
||||
* @param map the Map object to add members
|
||||
* @throws {ContainerBindError}: The setAll method cannot be bound.
|
||||
* @throws {TypeError}: The type of "map" must be LightWeightMap. Received value is: [map]
|
||||
* @throws { BusinessError } 10200011 - The setAll method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "map" must be LightWeightMap. Received value is: [map]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -139,7 +139,7 @@ declare class LightWeightMap<K, V> {
|
||||
* @param key Added or updated targets
|
||||
* @param value Added or updated value
|
||||
* @returns the map object after set
|
||||
* @throws {ContainerBindError}: The set method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The set method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -148,7 +148,7 @@ declare class LightWeightMap<K, V> {
|
||||
* Remove the mapping for this key from this map if present
|
||||
* @param key Target to be deleted
|
||||
* @return Target mapped value
|
||||
* @throws {ContainerBindError}: The remove method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The remove method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -157,8 +157,8 @@ declare class LightWeightMap<K, V> {
|
||||
* Deletes a key-value pair at the loaction identified by index from an LightWeightMap container
|
||||
* @param index Target subscript for search
|
||||
* @return the boolean type(Is there a delete value)
|
||||
* @throws {ContainerBindError}: The removeAt method cannot be bound.
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The removeAt method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -166,7 +166,7 @@ declare class LightWeightMap<K, V> {
|
||||
/**
|
||||
* Removes all of the mapping from this map
|
||||
* The map will be empty after this call returns
|
||||
* @throws {ContainerBindError}: The clear method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clear method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -176,9 +176,9 @@ declare class LightWeightMap<K, V> {
|
||||
* @param index Target subscript for search
|
||||
* @param value Updated the target mapped value
|
||||
* @return the boolean type(Is there a value corresponding to the subscript)
|
||||
* @throws {ContainerBindError}: The setValueAt method cannot be bound.
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The setValueAt method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -186,8 +186,8 @@ declare class LightWeightMap<K, V> {
|
||||
/**
|
||||
* Executes the given callback function once for each real key in the map.
|
||||
* It does not perform functions on deleted keys
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -195,14 +195,14 @@ declare class LightWeightMap<K, V> {
|
||||
thisArg?: Object): void;
|
||||
/**
|
||||
* returns an ES6 iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
[Symbol.iterator](): IterableIterator<[K, V]>;
|
||||
/**
|
||||
* Obtains a string that contains all the keys and values in an LightWeightMap container
|
||||
* @throws {ContainerBindError}: The toString method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The toString method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -211,16 +211,16 @@ declare class LightWeightMap<K, V> {
|
||||
* Obtains the value identified by index in an LightWeightMap container
|
||||
* @param index Target subscript for search
|
||||
* @return the value of key-value pairs
|
||||
* @throws {ContainerBindError}: The getValueAt method cannot be bound.
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The getValueAt method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
getValueAt(index: number): V;
|
||||
/**
|
||||
* Returns an iterator of the values contained in this map
|
||||
* @throws {ContainerBindError}: The values method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The values method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
50
api/@ohos.util.LightWeightSet.d.ts
vendored
50
api/@ohos.util.LightWeightSet.d.ts
vendored
@ -16,7 +16,7 @@
|
||||
declare class LightWeightSet<T> {
|
||||
/**
|
||||
* A constructor used to create a LightWeightSet object.
|
||||
* @throws {NewTargetIsNullError}: The LightWeightSet's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 10200012 - The LightWeightSet's constructor cannot be directly invoked.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -31,7 +31,7 @@ declare class LightWeightSet<T> {
|
||||
* If the set does not contain the element, the specified element is added
|
||||
* @param value Added element
|
||||
* @returns the boolean type(Is there contain this element)
|
||||
* @throws {ContainerBindError}: The add method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The add method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -40,8 +40,8 @@ declare class LightWeightSet<T> {
|
||||
* Adds all the objects in a specified LightWeightSet container to the current LightWeightSet container
|
||||
* @param set the Set object to provide the added element
|
||||
* @returns the boolean type(Is there any new data added successfully)
|
||||
* @throws {ContainerBindError}: The addAll method cannot be bound.
|
||||
* @throws {TypeError}: The type of "set" must be LightWeightSet. Received value is: [set]
|
||||
* @throws { BusinessError } 10200011 - The addAll method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "set" must be LightWeightSet. Received value is: [set]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -50,8 +50,8 @@ declare class LightWeightSet<T> {
|
||||
* Returns whether this set has all the object in a specified set
|
||||
* @param set the Set object to compare
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The hasAll method cannot be bound.
|
||||
* @throws {TypeError}: The type of "set" must be LightWeightSet. Received value is: [set]
|
||||
* @throws { BusinessError } 10200011 - The hasAll method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "set" must be LightWeightSet. Received value is: [set]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -60,7 +60,7 @@ declare class LightWeightSet<T> {
|
||||
* Checks whether an LightWeightSet container has a specified key
|
||||
* @param key need to determine whether to include the key
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The has method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The has method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -69,7 +69,7 @@ declare class LightWeightSet<T> {
|
||||
* Checks whether an the objects of an LightWeighSet containeer are of the same type as a specified Object LightWeightSet
|
||||
* @param obj need to determine whether to include the obj
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The equal method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The equal method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -78,9 +78,9 @@ declare class LightWeightSet<T> {
|
||||
* Ensures that the capacity of an LightWeightSet container is greater than or equal to a apecified value,
|
||||
* and that the container has all the original objects after capacity expansion
|
||||
* @param minimumCapacity Minimum capacity to be reserved
|
||||
* @throws {ContainerBindError}: The increaseCapacityTo method cannot be bound.
|
||||
* @throws {TypeError}: The type of "minimumCapacity" must be number. Received value is: [minimumCapacity]
|
||||
* @throws {RangeError}: The value of "minimumCapacity" is out of range. It must be > [currentCapacity]. Received value is: [minimumCapacity]
|
||||
* @throws { BusinessError } 10200011 - The increaseCapacityTo method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "minimumCapacity" must be number. Received value is: [minimumCapacity]
|
||||
* @throws { BusinessError } 10200001 - The value of "minimumCapacity" is out of range. It must be > [currentCapacity]. Received value is: [minimumCapacity]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -89,7 +89,7 @@ declare class LightWeightSet<T> {
|
||||
* Obtains the index of s key of a specified Object type in an LightWeightSet container
|
||||
* @param key Looking for goals
|
||||
* @return Subscript corresponding to target
|
||||
* @throws {ContainerBindError}: The getIndexOf method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getIndexOf method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -98,7 +98,7 @@ declare class LightWeightSet<T> {
|
||||
* Deletes an object of a specified Object type from an LightWeightSet container
|
||||
* @param key Target to be deleted
|
||||
* @return Target element
|
||||
* @throws {ContainerBindError}: The remove method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The remove method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -107,8 +107,8 @@ declare class LightWeightSet<T> {
|
||||
* Deletes an object at the loaction identified by index from an LightWeightSet container
|
||||
* @param index Target subscript for search
|
||||
* @return the boolean type(Is there a delete value)
|
||||
* @throws {ContainerBindError}: The removeAt method cannot be bound.
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The removeAt method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -116,7 +116,7 @@ declare class LightWeightSet<T> {
|
||||
/**
|
||||
* Removes all of the mapping from this map
|
||||
* The map will be empty after this call returns
|
||||
* @throws {ContainerBindError}: The clear method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clear method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -124,8 +124,8 @@ declare class LightWeightSet<T> {
|
||||
/**
|
||||
* Executes the given callback function once for each real key in the map.
|
||||
* It does not perform functions on deleted keys
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -133,7 +133,7 @@ declare class LightWeightSet<T> {
|
||||
thisArg?: Object): void;
|
||||
/**
|
||||
* returns an ES6 iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -146,7 +146,7 @@ declare class LightWeightSet<T> {
|
||||
toString(): String;
|
||||
/**
|
||||
* Obtains an Array that contains all the objects of an LightWeightSet container.
|
||||
* @throws {ContainerBindError}: The toArray method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The toArray method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -155,29 +155,29 @@ declare class LightWeightSet<T> {
|
||||
* Obtains the object at the location identified by index in an LightWeightSet container
|
||||
* @param index Target subscript for search
|
||||
* @return the value of key-value pairs
|
||||
* @throws {ContainerBindError}: The getValueAt method cannot be bound.
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The getValueAt method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
getValueAt(index: number): T;
|
||||
/**
|
||||
* Returns a ES6 iterator of the values contained in this Set
|
||||
* @throws {ContainerBindError}: The values method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The values method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
values(): IterableIterator<T>;
|
||||
/**
|
||||
* Returns a Iterator object that contains the [key, value] pairs for each element in the Set object in insertion order
|
||||
* @throws {ContainerBindError}: The entries method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The entries method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
entries(): IterableIterator<[T, T]>;
|
||||
/**
|
||||
* Returns whether the set object contains elements
|
||||
* @throws {ContainerBindError}: The isEmpty method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The isEmpty method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
68
api/@ohos.util.LinkedList.d.ts
vendored
68
api/@ohos.util.LinkedList.d.ts
vendored
@ -16,7 +16,7 @@
|
||||
declare class LinkedList<T> {
|
||||
/**
|
||||
* A constructor used to create a LinkedList object.
|
||||
* @throws {NewTargetIsNullError}: The LinkedList's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 10200012 - The LinkedList's constructor cannot be directly invoked.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -31,7 +31,7 @@ declare class LinkedList<T> {
|
||||
* Appends the specified element to the end of this linkedlist.
|
||||
* @param element to be appended to this linkedlist
|
||||
* @returns the boolean type, returns true if the addition is successful, and returns false if it fails.
|
||||
* @throws {ContainerBindError}: The add method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The add method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -40,9 +40,9 @@ declare class LinkedList<T> {
|
||||
* Inserts the specified element at the specified position in this linkedlist.
|
||||
* @param index index at which the specified element is to be inserted
|
||||
* @param element element to be inserted
|
||||
* @throws {ContainerBindError}: The insert method cannot be bound.
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length]. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The insert method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length]. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -52,8 +52,8 @@ declare class LinkedList<T> {
|
||||
* or returns undefined if this linkedlist is empty
|
||||
* @param index specified position
|
||||
* @return the T type
|
||||
* @throws {ContainerBindError}: The get method cannot be bound.
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The get method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -61,7 +61,7 @@ declare class LinkedList<T> {
|
||||
/**
|
||||
* Inserts the specified element at the beginning of this LinkedList.
|
||||
* @param element the element to add
|
||||
* @throws {ContainerBindError}: The addFirst method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The addFirst method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -69,8 +69,8 @@ declare class LinkedList<T> {
|
||||
/**
|
||||
* Retrieves and removes the head (first element) of this linkedlist.
|
||||
* @return the head of this list
|
||||
* @throws {ContainerBindError}: The removeFirst method cannot be bound.
|
||||
* @throws {ContainerIsEmptyError} Container is Empty.
|
||||
* @throws { BusinessError } 10200011 - The removeFirst method cannot be bound.
|
||||
* @throws { BusinessError } 10200010 - Container is Empty.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -78,8 +78,8 @@ declare class LinkedList<T> {
|
||||
/**
|
||||
* Removes and returns the last element from this linkedlist.
|
||||
* @return the head of this list
|
||||
* @throws {ContainerBindError}: The removeLast method cannot be bound.
|
||||
* @throws {ContainerIsEmptyError} Container is Empty.
|
||||
* @throws { BusinessError } 10200011 - The removeLast method cannot be bound.
|
||||
* @throws { BusinessError } 10200010 - Container is Empty.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -88,7 +88,7 @@ declare class LinkedList<T> {
|
||||
* Check if linkedlist contains the specified element
|
||||
* @param element element to be contained
|
||||
* @return the boolean type,if linkedList contains the specified element,return true,else return false
|
||||
* @throws {ContainerBindError}: The has method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The has method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -98,7 +98,7 @@ declare class LinkedList<T> {
|
||||
* in this linkedlist, or -1 if this linkedlist does not contain the element.
|
||||
* @param element element to be contained
|
||||
* @return the number type ,returns the lowest index such that or -1 if there is no such index.
|
||||
* @throws {ContainerBindError}: The getIndexOf method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getIndexOf method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -108,9 +108,9 @@ declare class LinkedList<T> {
|
||||
* @param index the index in the linkedlist
|
||||
* @return the T type ,returns undefined if linkedlist is empty,If the index is
|
||||
* out of bounds (greater than or equal to length or less than 0), throw an exception
|
||||
* @throws {ContainerBindError}: The removeByIndex method cannot be bound.
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The removeByIndex method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -121,7 +121,7 @@ declare class LinkedList<T> {
|
||||
* unchanged. More formally, removes the element with the lowest index
|
||||
* @param element element to remove
|
||||
* @return the boolean type ,If there is no such element, return false
|
||||
* @throws {ContainerBindError}: The remove method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The remove method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -132,8 +132,8 @@ declare class LinkedList<T> {
|
||||
* unchanged. More formally, removes the element with the lowest index
|
||||
* @param element element to remove
|
||||
* @return the boolean type ,If there is no such element, return false
|
||||
* @throws {ContainerBindError}: The removeFirstFound method cannot be bound.
|
||||
* @throws {ContainerIsEmptyError} Container is Empty.
|
||||
* @throws { BusinessError } 10200011 - The removeFirstFound method cannot be bound.
|
||||
* @throws { BusinessError } 10200010 - Container is Empty.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -144,8 +144,8 @@ declare class LinkedList<T> {
|
||||
* unchanged. More formally, removes the element with the lowest index
|
||||
* @param element element to remove
|
||||
* @return the boolean type ,If there is no such element, return false
|
||||
* @throws {ContainerBindError}: The removeLastFound method cannot be bound.
|
||||
* @throws {ContainerIsEmptyError} Container is Empty.
|
||||
* @throws { BusinessError } 10200011 - The removeLastFound method cannot be bound.
|
||||
* @throws { BusinessError } 10200010 - Container is Empty.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -155,7 +155,7 @@ declare class LinkedList<T> {
|
||||
* or -1 if the linkedlist does not contain the element.
|
||||
* @param element element to find
|
||||
* @return the number type
|
||||
* @throws {ContainerBindError}: The getLastIndexOf method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getLastIndexOf method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -164,7 +164,7 @@ declare class LinkedList<T> {
|
||||
* Returns the first element (the item at index 0) of this linkedlist.
|
||||
* or returns undefined if linkedlist is empty
|
||||
* @return the T type ,returns undefined if linkedList is empty
|
||||
* @throws {ContainerBindError}: The getFirst method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getFirst method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -173,7 +173,7 @@ declare class LinkedList<T> {
|
||||
* Returns the Last element (the item at index length-1) of this linkedlist.
|
||||
* or returns undefined if linkedlist is empty
|
||||
* @return the T type ,returns undefined if linkedList is empty
|
||||
* @throws {ContainerBindError}: The getLast method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getLast method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -183,9 +183,9 @@ declare class LinkedList<T> {
|
||||
* @param element replaced element
|
||||
* @param index index to find
|
||||
* @return the T type ,returns undefined if linkedList is empty
|
||||
* @throws {ContainerBindError}: The set method cannot be bound.
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The set method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -199,8 +199,8 @@ declare class LinkedList<T> {
|
||||
* @param LinkedList (Optional) The linkedlist object to which the current element belongs.
|
||||
* @param thisArg (Optional) The value passed to the function generally uses the "this" value.
|
||||
* If this parameter is empty, "undefined" will be passed to the "this" value
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -209,7 +209,7 @@ declare class LinkedList<T> {
|
||||
/**
|
||||
* Removes all of the elements from this linkedlist.The linkedlist will
|
||||
* be empty after this call returns.length becomes 0
|
||||
* @throws {ContainerBindError}: The clear method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clear method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -217,7 +217,7 @@ declare class LinkedList<T> {
|
||||
/**
|
||||
* Returns a shallow copy of this instance. (The elements themselves are not copied.)
|
||||
* @return this linkedlist instance
|
||||
* @throws {ContainerBindError}: The clone method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clone method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -225,14 +225,14 @@ declare class LinkedList<T> {
|
||||
/**
|
||||
* convert linkedlist to array
|
||||
* @return the Array type
|
||||
* @throws {ContainerBindError}: The convertToArray method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The convertToArray method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
convertToArray(): Array<T>;
|
||||
/**
|
||||
* returns an iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
70
api/@ohos.util.List.d.ts
vendored
70
api/@ohos.util.List.d.ts
vendored
@ -16,7 +16,7 @@
|
||||
declare class List<T> {
|
||||
/**
|
||||
* A constructor used to create a List object.
|
||||
* @throws {NewTargetIsNullError}: The List's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 10200012 - The List's constructor cannot be directly invoked.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -31,7 +31,7 @@ declare class List<T> {
|
||||
* Appends the specified element to the end of this list.
|
||||
* @param element to be appended to this list
|
||||
* @returns the boolean type, returns true if the addition is successful, and returns false if it fails.
|
||||
* @throws {ContainerBindError}: The add method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The add method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -40,9 +40,9 @@ declare class List<T> {
|
||||
* Inserts the specified element at the specified position in this list.
|
||||
* @param index index at which the specified element is to be inserted
|
||||
* @param element element to be inserted
|
||||
* @throws {ContainerBindError}: The insert method cannot be bound.
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length]. Received value is: [index]
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The insert method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length]. Received value is: [index]
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -52,8 +52,8 @@ declare class List<T> {
|
||||
* or returns undefined if this list is empty
|
||||
* @param index specified position
|
||||
* @return the T type
|
||||
* @throws {ContainerBindError}: The get method cannot be bound.
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The get method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -62,7 +62,7 @@ declare class List<T> {
|
||||
* Check if list contains the specified element
|
||||
* @param element element to be contained
|
||||
* @return the boolean type,if list contains the specified element,return true,else return false
|
||||
* @throws {ContainerBindError}: The has method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The has method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -72,7 +72,7 @@ declare class List<T> {
|
||||
* in this list, or -1 if this list does not contain the element.
|
||||
* @param element element to be contained
|
||||
* @return the number type ,returns the lowest index such that or -1 if there is no such index.
|
||||
* @throws {ContainerBindError}: The getIndexOf method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getIndexOf method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -82,9 +82,9 @@ declare class List<T> {
|
||||
* @param index the index in the list
|
||||
* @return the T type ,returns undefined if list is empty,If the index is
|
||||
* out of bounds (greater than or equal to length or less than 0), throw an exception
|
||||
* @throws {ContainerBindError}: The removeByIndex method cannot be bound.
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The removeByIndex method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -95,7 +95,7 @@ declare class List<T> {
|
||||
* unchanged. More formally, removes the element with the lowest index
|
||||
* @param element element to remove
|
||||
* @return the boolean type ,If there is no such element, return false
|
||||
* @throws {ContainerBindError}: The remove method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The remove method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -105,7 +105,7 @@ declare class List<T> {
|
||||
* or -1 if the list does not contain the element.
|
||||
* @param element element to find
|
||||
* @return the number type
|
||||
* @throws {ContainerBindError}: The getLastIndexOf method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getLastIndexOf method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -114,7 +114,7 @@ declare class List<T> {
|
||||
* Returns the first element (the item at index 0) of this list.
|
||||
* or returns undefined if list is empty
|
||||
* @return the T type ,returns undefined if list is empty
|
||||
* @throws {ContainerBindError}: The getFirst method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getFirst method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -123,7 +123,7 @@ declare class List<T> {
|
||||
* Returns the Last element (the item at index length-1) of this list.
|
||||
* or returns undefined if list is empty
|
||||
* @return the T type ,returns undefined if list is empty
|
||||
* @throws {ContainerBindError}: The getLast method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getLast method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -133,9 +133,9 @@ declare class List<T> {
|
||||
* @param element replaced element
|
||||
* @param index index to find
|
||||
* @return the T type
|
||||
* @throws {ContainerBindError}: The set method cannot be bound.
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The set method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -145,7 +145,7 @@ declare class List<T> {
|
||||
* return true, otherwise return false.
|
||||
* @param obj Compare objects
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The equal method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The equal method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -159,8 +159,8 @@ declare class List<T> {
|
||||
* @param List (Optional) The list object to which the current element belongs.
|
||||
* @param thisArg (Optional) The value passed to the function generally uses the "this" value.
|
||||
* If this parameter is empty, "undefined" will be passed to the "this" value
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -174,8 +174,8 @@ declare class List<T> {
|
||||
* minus firstValue, it returns an list sorted in descending order;
|
||||
* @param firstValue (Optional) previous element
|
||||
* @param secondValue (Optional) next elements
|
||||
* @throws {TypeError}: The type of "comparator" must be callable. Received value is: [comparator]
|
||||
* @throws {ContainerBindError}: The sort method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "comparator" must be callable. Received value is: [comparator]
|
||||
* @throws { BusinessError } 10200011 - The sort method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -183,7 +183,7 @@ declare class List<T> {
|
||||
/**
|
||||
* Removes all of the elements from this list.The list will
|
||||
* be empty after this call returns.length becomes 0
|
||||
* @throws {ContainerBindError}: The clear method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clear method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -192,11 +192,11 @@ declare class List<T> {
|
||||
* Returns a view of the portion of this list between the specified fromIndex,inclusize,and toIndex,exclusive
|
||||
* @param fromIndex The starting position of the index, containing the value at that index position
|
||||
* @param toIndex the end of the index, excluding the value at that index
|
||||
* @throws {ContainerBindError}: The getSubList method cannot be bound.
|
||||
* @throws {RangeError}: The value of "fromIndex" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [fromIndex]
|
||||
* @throws {RangeError}: The value of "toIndex" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [toIndex]
|
||||
* @throws {TypeError}: The type of "fromIndex" must be number. Received value is: [fromIndex]
|
||||
* @throws {TypeError}: The type of "toIndex" must be number. Received value is: [toIndex]
|
||||
* @throws { BusinessError } 10200011 - The getSubList method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "fromIndex" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [fromIndex]
|
||||
* @throws { BusinessError } 10200001 - The value of "toIndex" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [toIndex]
|
||||
* @throws { BusinessError } 401 - The type of "fromIndex" must be number. Received value is: [fromIndex]
|
||||
* @throws { BusinessError } 401 - The type of "toIndex" must be number. Received value is: [toIndex]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -210,8 +210,8 @@ declare class List<T> {
|
||||
* @param list (Optional) The list object to which the current element belongs.
|
||||
* @param thisArg (Optional) The value passed to the function generally uses the "this" value.
|
||||
* If this parameter is empty, "undefined" will be passed to the "this" value
|
||||
* @throws {ContainerBindError}: The replaceAllElements method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The replaceAllElements method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -220,7 +220,7 @@ declare class List<T> {
|
||||
/**
|
||||
* convert list to array
|
||||
* @return the Array type
|
||||
* @throws {ContainerBindError}: The convertToArray method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The convertToArray method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -228,14 +228,14 @@ declare class List<T> {
|
||||
/**
|
||||
* Determine whether list is empty and whether there is an element
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The isEmpty method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The isEmpty method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
isEmpty(): boolean;
|
||||
/**
|
||||
* returns an iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
64
api/@ohos.util.PlainArray.d.ts
vendored
64
api/@ohos.util.PlainArray.d.ts
vendored
@ -16,7 +16,7 @@
|
||||
declare class PlainArray<T> {
|
||||
/**
|
||||
* A constructor used to create a PlainArray object.
|
||||
* @throws {NewTargetIsNullError}: The PlainArray's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 10200012 - The PlainArray's constructor cannot be directly invoked.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -31,22 +31,22 @@ declare class PlainArray<T> {
|
||||
* Appends a key-value pair to PlainArray
|
||||
* @param key Added the key of key-value
|
||||
* @param value Added the value of key-value
|
||||
* @throws {ContainerBindError}: The add method cannot be bound.
|
||||
* @throws {TypeError}: The type of "key" must be number. Received value is: [key]
|
||||
* @throws { BusinessError } 10200011 - The add method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "key" must be number. Received value is: [key]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
add(key: number, value: T): void;
|
||||
/**
|
||||
* Clears the current PlainArray object
|
||||
* @throws {ContainerBindError}: The clear method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clear method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
clear(): void;
|
||||
/**
|
||||
* Obtains a clone of the current PlainArray object
|
||||
* @throws {ContainerBindError}: The clone method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clone method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -55,8 +55,8 @@ declare class PlainArray<T> {
|
||||
* Checks whether the current PlainArray object contains the specified key
|
||||
* @param key need to determine whether to include the key
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The has method cannot be bound.
|
||||
* @throws {TypeError}: The type of "key" must be number. Received value is: [key]
|
||||
* @throws { BusinessError } 10200011 - The has method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "key" must be number. Received value is: [key]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -65,8 +65,8 @@ declare class PlainArray<T> {
|
||||
* Queries the value associated with the specified key
|
||||
* @param key Looking for goals
|
||||
* @return the value of key-value pairs
|
||||
* @throws {ContainerBindError}: The get method cannot be bound.
|
||||
* @throws {TypeError}: The type of "key" must be number. Received value is: [key]
|
||||
* @throws { BusinessError } 10200011 - The get method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "key" must be number. Received value is: [key]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -75,8 +75,8 @@ declare class PlainArray<T> {
|
||||
* Queries the index for a specified key
|
||||
* @param key Looking for goals
|
||||
* @return Subscript corresponding to target
|
||||
* @throws {ContainerBindError}: The getIndexOfKey method cannot be bound.
|
||||
* @throws {TypeError}: The type of "key" must be number. Received value is: [key]
|
||||
* @throws { BusinessError } 10200011 - The getIndexOfKey method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "key" must be number. Received value is: [key]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -85,7 +85,7 @@ declare class PlainArray<T> {
|
||||
* Queries the index for a specified value
|
||||
* @param value Looking for goals
|
||||
* @return Subscript corresponding to target
|
||||
* @throws {ContainerBindError}: The getIndexOfValue method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getIndexOfValue method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -93,7 +93,7 @@ declare class PlainArray<T> {
|
||||
/**
|
||||
* Checks whether the current PlainArray object is empty
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The isEmpty method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The isEmpty method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -102,8 +102,8 @@ declare class PlainArray<T> {
|
||||
* Queries the key at a specified index
|
||||
* @param index Target subscript for search
|
||||
* @return the key of key-value pairs
|
||||
* @throws {ContainerBindError}: The getKeyAt method cannot be bound.
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The getKeyAt method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -112,8 +112,8 @@ declare class PlainArray<T> {
|
||||
* Remove the key-value pair based on a specified key if it exists and return the value
|
||||
* @param key Target to be deleted
|
||||
* @return Target mapped value
|
||||
* @throws {ContainerBindError}: The remove method cannot be bound.
|
||||
* @throws {TypeError}: The type of "key" must be number. Received value is: [key]
|
||||
* @throws { BusinessError } 10200011 - The remove method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "key" must be number. Received value is: [key]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -122,8 +122,8 @@ declare class PlainArray<T> {
|
||||
* Remove the key-value pair at a specified index if it exists and return the value
|
||||
* @param index Target subscript for search
|
||||
* @return the T type
|
||||
* @throws {ContainerBindError}: The removeAt method cannot be bound.
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The removeAt method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -133,9 +133,9 @@ declare class PlainArray<T> {
|
||||
* @param index remove start index
|
||||
* @param size Expected deletion quantity
|
||||
* @return Actual deleted quantity
|
||||
* @throws {ContainerBindError}: The removeRangeFrom method cannot be bound.
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The removeRangeFrom method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -144,16 +144,16 @@ declare class PlainArray<T> {
|
||||
* Update value on specified index
|
||||
* @param index Target subscript for search
|
||||
* @param value Updated the target mapped value
|
||||
* @throws {ContainerBindError}: The setValueAt method cannot be bound.
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The setValueAt method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
setValueAt(index: number, value: T): void;
|
||||
/**
|
||||
* Obtains the string representation of the PlainArray object
|
||||
* @throws {ContainerBindError}: The toString method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The toString method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -162,17 +162,17 @@ declare class PlainArray<T> {
|
||||
* Queries the value at a specified index
|
||||
* @param index Target subscript for search
|
||||
* @return the value of key-value pairs
|
||||
* @throws {ContainerBindError}: The getValueAt method cannot be bound.
|
||||
* @throws {RangeError}: The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws {TypeError}: The type of "index" must be number. Received value is: [index]
|
||||
* @throws { BusinessError } 10200011 - The getValueAt method cannot be bound.
|
||||
* @throws { BusinessError } 10200001 - The value of "index" is out of range. It must be >= 0 && <= [this.length - 1]. Received value is: [index]
|
||||
* @throws { BusinessError } 401 - The type of "index" must be number. Received value is: [index]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
getValueAt(index: number): T;
|
||||
/**
|
||||
* Executes a provided function once for each value in the PlainArray object.
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -180,7 +180,7 @@ declare class PlainArray<T> {
|
||||
thisArg?: Object): void;
|
||||
/**
|
||||
* returns an iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
14
api/@ohos.util.Queue.d.ts
vendored
14
api/@ohos.util.Queue.d.ts
vendored
@ -16,7 +16,7 @@
|
||||
declare class Queue<T> {
|
||||
/**
|
||||
* A constructor used to create a Queue object.
|
||||
* @throws {NewTargetIsNullError}: The Queue's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 10200012 - The Queue's constructor cannot be directly invoked.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -32,7 +32,7 @@ declare class Queue<T> {
|
||||
* so immediately without violating capacity restrictions.
|
||||
* @param element to be appended to this queue
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The add method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The add method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -40,7 +40,7 @@ declare class Queue<T> {
|
||||
/**
|
||||
* Obtains the header element of a queue.
|
||||
* @return the T type
|
||||
* @throws {ContainerBindError}: The getFirst method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getFirst method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -48,7 +48,7 @@ declare class Queue<T> {
|
||||
/**
|
||||
* Retrieves and removes the head of this queue
|
||||
* @return the T type
|
||||
* @throws {ContainerBindError}: The pop method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The pop method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -62,8 +62,8 @@ declare class Queue<T> {
|
||||
* @param Queue (Optional) The queue object to which the current element belongs.
|
||||
* @param thisArg (Optional) The value passed to the function generally uses the "this" value.
|
||||
* If this parameter is empty, "undefined" will be passed to the "this" value
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -71,7 +71,7 @@ declare class Queue<T> {
|
||||
thisArg?: Object): void;
|
||||
/**
|
||||
* returns an iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
18
api/@ohos.util.Stack.d.ts
vendored
18
api/@ohos.util.Stack.d.ts
vendored
@ -16,7 +16,7 @@
|
||||
declare class Stack<T> {
|
||||
/**
|
||||
* A constructor used to create a Stack object.
|
||||
* @throws {NewTargetIsNullError}: The Stack's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 10200012 - The Stack's constructor cannot be directly invoked.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -30,7 +30,7 @@ declare class Stack<T> {
|
||||
/**
|
||||
* Tests if this stack is empty
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The isEmpty method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The isEmpty method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -39,7 +39,7 @@ declare class Stack<T> {
|
||||
* Looks at the object at the top of this stack without removing it from the stack
|
||||
* Return undfined if this stack is empty
|
||||
* @return the top value or undefined
|
||||
* @throws {ContainerBindError}: The peek method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The peek method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -48,7 +48,7 @@ declare class Stack<T> {
|
||||
* Removes the object at the top of this stack and returns that object as the value of this function
|
||||
* an exception if the stack is empty
|
||||
* @returns Stack top value or undefined
|
||||
* @throws {ContainerBindError}: The pop method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The pop method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -57,7 +57,7 @@ declare class Stack<T> {
|
||||
* Pushes an item onto the top of this stack
|
||||
* @param item to be appended to this Stack
|
||||
* @returns the T type
|
||||
* @throws {ContainerBindError}: The push method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The push method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -66,7 +66,7 @@ declare class Stack<T> {
|
||||
* Returns the 1-based position where an object is on this stack
|
||||
* @param element Target to be deleted
|
||||
* @returns the T type,If there is no such element, return -1
|
||||
* @throws {ContainerBindError}: The locate method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The locate method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -80,8 +80,8 @@ declare class Stack<T> {
|
||||
* @param stack (Optional) The Stack object to which the current element belongs.
|
||||
* @param thisArg (Optional) The value passed to the function generally uses the "this" value.
|
||||
* If this parameter is empty, "undefined" will be passed to the "this" value
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -89,7 +89,7 @@ declare class Stack<T> {
|
||||
thisArg?: Object): void;
|
||||
/**
|
||||
* returns an ES6 iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
46
api/@ohos.util.TreeMap.d.ts
vendored
46
api/@ohos.util.TreeMap.d.ts
vendored
@ -20,8 +20,8 @@ declare class TreeMap<K, V> {
|
||||
* @param comparator (Optional) User-defined comparison functions
|
||||
* @param firstValue (Optional) previous element
|
||||
* @param secondValue (Optional) next element
|
||||
* @throws {NewTargetIsNullError}: The TreeMap's constructor cannot be directly invoked.
|
||||
* @throws {TypeError}: The type of "comparator" must be callable. Received value is: [comparator]
|
||||
* @throws { BusinessError } 10200012 - The TreeMap's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 401 - The type of "comparator" must be callable. Received value is: [comparator]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -35,7 +35,7 @@ declare class TreeMap<K, V> {
|
||||
/**
|
||||
* Returns whether the Map object contains elements
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The isEmpty method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The isEmpty method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -44,7 +44,7 @@ declare class TreeMap<K, V> {
|
||||
* Returns whether a key is contained in this map
|
||||
* @param key need to determine whether to include the key
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The hasKey method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The hasKey method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -53,7 +53,7 @@ declare class TreeMap<K, V> {
|
||||
* Returns whether a value is contained in this map
|
||||
* @param value need to determine whether to include the value
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The hasValue method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The hasValue method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -62,7 +62,7 @@ declare class TreeMap<K, V> {
|
||||
* Returns a specified element in a Map object, or null if there is no corresponding element
|
||||
* @param key the index in TreeMap
|
||||
* @return value or null
|
||||
* @throws {ContainerBindError}: The get method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The get method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -71,7 +71,7 @@ declare class TreeMap<K, V> {
|
||||
* Obtains the first sorted key in the treemap.
|
||||
* Or returns undefined if tree map is empty
|
||||
* @return value or undefined
|
||||
* @throws {ContainerBindError}: The getFirstKey method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getFirstKey method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -80,7 +80,7 @@ declare class TreeMap<K, V> {
|
||||
* Obtains the last sorted key in the treemap.
|
||||
* Or returns undefined if tree map is empty
|
||||
* @return value or undefined
|
||||
* @throws {ContainerBindError}: The getLastKey method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getLastKey method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -88,8 +88,8 @@ declare class TreeMap<K, V> {
|
||||
/**
|
||||
* Adds all element groups in one map to another map
|
||||
* @param map the Map object to add members
|
||||
* @throws {ContainerBindError}: The setAll method cannot be bound.
|
||||
* @throws {TypeError}: The type of "map" must be TreeMap. Received value is: [map]
|
||||
* @throws { BusinessError } 10200011 - The setAll method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "map" must be TreeMap. Received value is: [map]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -99,8 +99,8 @@ declare class TreeMap<K, V> {
|
||||
* @param key Added or updated targets
|
||||
* @param value Added or updated value
|
||||
* @returns the map object after set
|
||||
* @throws {ContainerBindError}: The set method cannot be bound.
|
||||
* @throws {TypeError}: The type of "key" must be not null. Received value is: [key]
|
||||
* @throws { BusinessError } 10200011 - The set method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "key" must be not null. Received value is: [key]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -108,7 +108,7 @@ declare class TreeMap<K, V> {
|
||||
/**
|
||||
* Remove a specified element from a Map object
|
||||
* @param key Target to be deleted
|
||||
* @throws {ContainerBindError}: The remove method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The remove method cannot be bound.
|
||||
* @return Target mapped value
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
@ -116,7 +116,7 @@ declare class TreeMap<K, V> {
|
||||
remove(key: K): V;
|
||||
/**
|
||||
* Clear all element groups in the map
|
||||
* @throws {ContainerBindError}: The clear method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clear method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -125,7 +125,7 @@ declare class TreeMap<K, V> {
|
||||
* Returns the greatest element smaller than or equal to the specified key
|
||||
* if the key does not exist, undefied is returned
|
||||
* @param key Objective of comparison
|
||||
* @throws {ContainerBindError}: The getLowerKey method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getLowerKey method cannot be bound.
|
||||
* @return key or undefined
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
@ -136,21 +136,21 @@ declare class TreeMap<K, V> {
|
||||
* if the key does not exist, undefied is returned
|
||||
* @param key Objective of comparison
|
||||
* @return key or undefined
|
||||
* @throws {ContainerBindError}: The getHigherKey method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getHigherKey method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
getHigherKey(key: K): K;
|
||||
/**
|
||||
* Returns a new Iterator object that contains the keys contained in this map
|
||||
* @throws {ContainerBindError}: The keys method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The keys method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
keys(): IterableIterator<K>;
|
||||
/**
|
||||
* Returns a new Iterator object that contains the values contained in this map
|
||||
* @throws {ContainerBindError}: The values method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The values method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -160,7 +160,7 @@ declare class TreeMap<K, V> {
|
||||
* @param key Updated targets
|
||||
* @param value Updated the target mapped value
|
||||
* @returns the boolean type(Is there a target pointed to by the key)
|
||||
* @throws {ContainerBindError}: The replace method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The replace method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -168,8 +168,8 @@ declare class TreeMap<K, V> {
|
||||
/**
|
||||
* Executes the given callback function once for each real key in the map.
|
||||
* It does not perform functions on deleted keys
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -177,14 +177,14 @@ declare class TreeMap<K, V> {
|
||||
thisArg?: Object): void;
|
||||
/**
|
||||
* Returns a new Iterator object that contains the [key, value] pairs for each element in the Map object in insertion order
|
||||
* @throws {ContainerBindError}: The entries method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The entries method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
entries(): IterableIterator<[K, V]>;
|
||||
/**
|
||||
* returns an ES6 iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
42
api/@ohos.util.TreeSet.d.ts
vendored
42
api/@ohos.util.TreeSet.d.ts
vendored
@ -19,8 +19,8 @@ declare class TreeSet<T> {
|
||||
* @param comparator (Optional) User-defined comparison functions
|
||||
* @param firstValue (Optional) previous element
|
||||
* @param secondValue (Optional) next element
|
||||
* @throws {NewTargetIsNullError}: The TreeSet's constructor cannot be directly invoked.
|
||||
* @throws {TypeError}: The type of "comparator" must be callable. Received value is: [comparator]
|
||||
* @throws { BusinessError } 10200012 - The TreeSet's constructor cannot be directly invoked.
|
||||
* @throws { BusinessError } 401 - The type of "comparator" must be callable. Received value is: [comparator]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -34,7 +34,7 @@ declare class TreeSet<T> {
|
||||
/**
|
||||
* Returns whether the Set object contains elements
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The isEmpty method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The isEmpty method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -43,7 +43,7 @@ declare class TreeSet<T> {
|
||||
* Returns whether the Set object contain s the elements
|
||||
* @param value need to determine whether to include the element
|
||||
* @return the boolean type
|
||||
* @throws {ContainerBindError}: The has method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The has method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -52,8 +52,8 @@ declare class TreeSet<T> {
|
||||
* If the set does not contain the element, the specified element is added
|
||||
* @param value Added element
|
||||
* @returns the boolean type(Is there contain this element)
|
||||
* @throws {TypeError}: The type of "value" must be not null. Received value is: [value]
|
||||
* @throws {ContainerBindError}: The add method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "value" must be not null. Received value is: [value]
|
||||
* @throws { BusinessError } 10200011 - The add method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -62,14 +62,14 @@ declare class TreeSet<T> {
|
||||
* Remove a specified element from a Set object
|
||||
* @param value Target to be deleted
|
||||
* @return the boolean type(Is there contain this element)
|
||||
* @throws {ContainerBindError}: The remove method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The remove method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
remove(value: T): boolean;
|
||||
/**
|
||||
* Clears all element groups in a set
|
||||
* @throws {ContainerBindError}: The clear method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The clear method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -77,7 +77,7 @@ declare class TreeSet<T> {
|
||||
/**
|
||||
* Gets the first elements in a set
|
||||
* @return value or undefined
|
||||
* @throws {ContainerBindError}: The getFirstValue method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getFirstValue method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -85,7 +85,7 @@ declare class TreeSet<T> {
|
||||
/**
|
||||
* Gets the last elements in a set
|
||||
* @return value or undefined
|
||||
* @throws {ContainerBindError}: The getLastValue method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The getLastValue method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -95,8 +95,8 @@ declare class TreeSet<T> {
|
||||
* if the key does not exist, undefied is returned
|
||||
* @param key Objective of comparison
|
||||
* @return key or undefined
|
||||
* @throws {ContainerBindError}: The getLowerValue method cannot be bound.
|
||||
* @throws {TypeError}: The type of "key" must be not null. Received value is: [key]
|
||||
* @throws { BusinessError } 10200011 - The getLowerValue method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "key" must be not null. Received value is: [key]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -106,8 +106,8 @@ declare class TreeSet<T> {
|
||||
* if the key does not exist, undefied is returned
|
||||
* @param key Objective of comparison
|
||||
* @return key or undefined
|
||||
* @throws {ContainerBindError}: The getHigherValue method cannot be bound.
|
||||
* @throws {TypeError}: The type of "key" must be not null. Received value is: [key]
|
||||
* @throws { BusinessError } 10200011 - The getHigherValue method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "key" must be not null. Received value is: [key]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -115,7 +115,7 @@ declare class TreeSet<T> {
|
||||
/**
|
||||
* Return and delete the first element, returns undefined if tree set is empty
|
||||
* @return first value or undefined
|
||||
* @throws {ContainerBindError}: The popFirst method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The popFirst method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -123,15 +123,15 @@ declare class TreeSet<T> {
|
||||
/**
|
||||
* Return and delete the last element, returns undefined if tree set is empty
|
||||
* @return last value or undefined
|
||||
* @throws {ContainerBindError}: The popLast method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The popLast method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
popLast(): T;
|
||||
/**
|
||||
* Executes a provided function once for each value in the Set object.
|
||||
* @throws {ContainerBindError}: The forEach method cannot be bound.
|
||||
* @throws {TypeError}: The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @throws { BusinessError } 10200011 - The forEach method cannot be bound.
|
||||
* @throws { BusinessError } 401 - The type of "callbackfn" must be callable. Received value is: [callbackfn]
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
@ -139,21 +139,21 @@ declare class TreeSet<T> {
|
||||
thisArg?: Object): void;
|
||||
/**
|
||||
* Returns a new Iterator object that contains the values contained in this set
|
||||
* @throws {ContainerBindError}: The values method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The values method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
values(): IterableIterator<T>;
|
||||
/**
|
||||
* Returns a new Iterator object that contains the [key, value] pairs for each element in the Set object in insertion order
|
||||
* @throws {ContainerBindError}: The entries method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The entries method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
entries(): IterableIterator<[T, T]>;
|
||||
/**
|
||||
* returns an ES6 iterator.Each item of the iterator is a Javascript Object
|
||||
* @throws {ContainerBindError}: The Symbol.iterator method cannot be bound.
|
||||
* @throws { BusinessError } 10200011 - The Symbol.iterator method cannot be bound.
|
||||
* @since 8
|
||||
* @syscap SystemCapability.Utils.Lang
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user