1/* 2 * Copyright (c) 2021-2023 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16import { AsyncCallback } from './@ohos.base'; 17 18export default document; 19 20/** 21 * document 22 * 23 * @namespace document 24 * @syscap SystemCapability.FileManagement.UserFileService 25 * @since 6 26 * @deprecated since 9 27 */ 28declare namespace document { 29 export { choose }; 30 export { show }; 31} 32 33/** 34 * choose. 35 * 36 * @param { string[] } types - type. 37 * @returns { Promise<string> } return Promise 38 * @throws { TypedError } Parameter check failed 39 * @syscap SystemCapability.FileManagement.UserFileService 40 * @since 6 41 * @deprecated since 9 42 */ 43declare function choose(types?: string[]): Promise<string>; 44 45/** 46 * choose. 47 * 48 * @param { AsyncCallback<string> } [callback] - callback. 49 * @throws { TypedError } Parameter check failed 50 * @syscap SystemCapability.FileManagement.UserFileService 51 * @since 6 52 * @deprecated since 9 53 */ 54declare function choose(callback: AsyncCallback<string>): void; 55 56/** 57 * choose. 58 * 59 * @param { string[] } types - type. 60 * @param { AsyncCallback<string> } [callback] - callback. 61 * @throws { TypedError } Parameter check failed 62 * @syscap SystemCapability.FileManagement.UserFileService 63 * @since 6 64 * @deprecated since 9 65 */ 66declare function choose(types: string[], callback: AsyncCallback<string>): void; 67 68/** 69 * show. 70 * 71 * @param { string } uri - uri. 72 * @param { string } type - type. 73 * @returns { Promise<void> } return Promise 74 * @throws { TypedError } Parameter check failed 75 * @syscap SystemCapability.FileManagement.UserFileService 76 * @since 6 77 * @deprecated since 9 78 */ 79declare function show(uri: string, type: string): Promise<void>; 80 81/** 82 * show. 83 * 84 * @param { string } uri - uri. 85 * @param { string } type - type. 86 * @param { AsyncCallback<void> } [callback] - callback. 87 * @throws { TypedError } Parameter check failed 88 * @syscap SystemCapability.FileManagement.UserFileService 89 * @since 6 90 * @deprecated since 9 91 */ 92declare function show(uri: string, type: string, callback: AsyncCallback<void>): void; 93