From 025d37d7ce1c379002878e7832087869c7adc12e Mon Sep 17 00:00:00 2001 From: qimeng Date: Tue, 11 Oct 2022 18:09:38 +0800 Subject: [PATCH 1/3] Signed-off-by: qimeng Changes to be committed: modified: api/@ohos.pasteboard.d.ts --- api/@ohos.pasteboard.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/@ohos.pasteboard.d.ts b/api/@ohos.pasteboard.d.ts index a24ac81708..6c982fc43c 100644 --- a/api/@ohos.pasteboard.d.ts +++ b/api/@ohos.pasteboard.d.ts @@ -568,7 +568,7 @@ declare namespace pasteboard { /** * Gets pastedata from the system pasteboard. * @returns { Promise } the promise returned by the getData. - * @throws { BusinessError } 1290003 - if another getData is being processed. + * @throws { BusinessError } 12900003 - if another getData is being processed. * @since 9 */ getData(): Promise; -- Gitee From b00572c0e8f658892d1c019be644246152362f2d Mon Sep 17 00:00:00 2001 From: qimeng Date: Tue, 11 Oct 2022 22:58:31 +0800 Subject: [PATCH 2/3] Signed-off-by: qimeng Changes to be committed: modified: api/@ohos.pasteboard.d.ts --- api/@ohos.pasteboard.d.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/api/@ohos.pasteboard.d.ts b/api/@ohos.pasteboard.d.ts index 6c982fc43c..9ae1491e58 100644 --- a/api/@ohos.pasteboard.d.ts +++ b/api/@ohos.pasteboard.d.ts @@ -425,7 +425,7 @@ declare namespace pasteboard { * Gets record by index in PasteData. * @param { number } index - indicates the record index in PasteData. * @returns { PasteDataRecord } the record in PasteData with index. - * @throws { BusinessError } 12900001 - if type of index is not number. + * @throws { BusinessError } 401 - if type of index is not number. * @throws { BusinessError } 12900002 - if index is out of the record count of PasteData. * @since 9 */ @@ -613,7 +613,8 @@ declare namespace pasteboard { * @param { PasteData } data - PasteData will be written to the clipboard * @param { AsyncCallback } callback - the callback of setData. * @throws { BusinessError } 401 - if type of data is not PasteData or type of callback is not AsyncCallback. - * @throws { BusinessError } 12900003 - if another setData is being processed or the system prohibits copying. + * @throws { BusinessError } 12900003 - if another setData is being processed. + * @throws { BusinessError } 12900004 - if the system prohibits copying. * @since 9 */ setData(data: PasteData, callback: AsyncCallback): void; @@ -623,7 +624,8 @@ declare namespace pasteboard { * @param { PasteData } data - PasteData will be written to the clipboard. * @returns { Promise } the promise returned by the function. * @throws { BusinessError } 401 - if type of data is not PasteData. - * @throws { BusinessError } 12900003 - if another setData is being processed or the system prohibits copying. + * @throws { BusinessError } 12900003 - if another setData is being processed. + * @throws { BusinessError } 12900004 - if the system prohibits copying. * @since 9 */ setData(data: PasteData): Promise; -- Gitee From 27101c083f0db5839cc60b27b2604026d54643bb Mon Sep 17 00:00:00 2001 From: qimeng Date: Tue, 11 Oct 2022 23:10:32 +0800 Subject: [PATCH 3/3] Signed-off-by: qimeng Changes to be committed: modified: api/@ohos.pasteboard.d.ts --- api/@ohos.pasteboard.d.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/api/@ohos.pasteboard.d.ts b/api/@ohos.pasteboard.d.ts index 9ae1491e58..722c99abcf 100644 --- a/api/@ohos.pasteboard.d.ts +++ b/api/@ohos.pasteboard.d.ts @@ -426,7 +426,7 @@ declare namespace pasteboard { * @param { number } index - indicates the record index in PasteData. * @returns { PasteDataRecord } the record in PasteData with index. * @throws { BusinessError } 401 - if type of index is not number. - * @throws { BusinessError } 12900002 - if index is out of the record count of PasteData. + * @throws { BusinessError } 12900001 - if index is out of the record count of PasteData. * @since 9 */ getRecord(index: number): PasteDataRecord; @@ -478,7 +478,7 @@ declare namespace pasteboard { * Removes a Record based on a specified index. * @param { number } index - indicates the record index in PasteData. * @throws { BusinessError } 401 - if type of index is not number. - * @throws { BusinessError } 12900002 - if index is out of the record count of PasteData. + * @throws { BusinessError } 12900001 - if index is out of the record count of PasteData. * @since 9 */ removeRecord(index: number): void; @@ -498,7 +498,7 @@ declare namespace pasteboard { * @param { number } index - indicates the record index in PasteData. * @param { PasteDataRecord } record - the content of a new record. * @throws { BusinessError } 401 - if type of index is not number or type of record is not PasteDataRecord. - * @throws { BusinessError } 12900002 - if index is out of the record count of PasteData. + * @throws { BusinessError } 12900001 - if index is out of the record count of PasteData. * @since 9 */ replaceRecord(index: number, record: PasteDataRecord): void; -- Gitee