modify distirbutedData js api d.ts

Signed-off-by: zhangxinlogo <zhangxin360@huawei.com>
This commit is contained in:
zhangxinlogo 2021-12-27 15:18:55 +08:00
parent b12f979f03
commit 82d3baab2e

View File

@ -639,6 +639,39 @@ declare namespace distributedData {
securityLevel?: SecurityLevel;
}
/**
* Represents the database schema.
*
* You can create Schema objects and put them in Options when creating or opening the database.
*
* @since 8
* @Syscap SystemCapability.Data.DATA_DISTRIBUTEDDATAMGR
* @devices phone, tablet, tv, wearable, car
* @import N/A
* @permission N/A
*/
class Schema {
/**
* A constructor used to create a Schema instance.
*
* @note N/A
* @since 8
* @Syscap SystemCapability.Data.DATA_DISTRIBUTEDDATAMGR
* @devices phone, tablet, tv, wearable, car
*/
constructor()
/**
* Obtains the schema in json format.
*
* @note N/A
* @since 8
* @Syscap SystemCapability.Data.DATA_DISTRIBUTEDDATAMGR
* @devices phone, tablet, tv, wearable, car
* @returns Returns the schema in json format.
*/
toJsonString():string;
}
/**
* Represents a node of a {@link Schema} instance.
*
@ -654,7 +687,17 @@ declare namespace distributedData {
* @import N/A
* @permission N/A
*/
interface FieldNode {
class FieldNode {
/**
* A constructor used to create a FieldNode instance with the specified field.
* name Indicates the field node name.
*
* @note N/A
* @since 8
* @Syscap SystemCapability.Data.DATA_DISTRIBUTEDDATAMGR
* @devices phone, tablet, tv, wearable, car
*/
constructor(name: string)
/**
* Adds a child node to this {@code FieldNode}.
*
@ -845,7 +888,16 @@ declare namespace distributedData {
* @import N/A
* @permission N/A
*/
interface Query {
class Query {
/**
* A constructor used to create a Query instance.
*
* @note N/A
* @since 8
* @Syscap SystemCapability.Data.DATA_DISTRIBUTEDDATAMGR
* @devices phone, tablet, tv, wearable, car
*/
constructor()
/**
* Resets this {@code Query} object.
*