diff --git a/zh-cn/application-dev/reference/apis/js-apis-data-DataShareResultSet.md b/zh-cn/application-dev/reference/apis/js-apis-data-DataShareResultSet.md index 8f6a8e74a15d7acd70863f92abd8c1adc122b956..4ef30b622cfa68b03ddc4e36c0c17322c4bb73f1 100644 --- a/zh-cn/application-dev/reference/apis/js-apis-data-DataShareResultSet.md +++ b/zh-cn/application-dev/reference/apis/js-apis-data-DataShareResultSet.md @@ -44,7 +44,10 @@ dataShareHelper.query(uri, da, columns).then((data) => { }); ``` -## 属性 +## DataShareResultSet +提供通过查询数据库生成的结果集的相关访问方法。 + +### 属性 **系统能力:** SystemCapability.DistributedDataManager.DataShare.Core @@ -55,7 +58,7 @@ dataShareHelper.query(uri, da, columns).then((data) => { | rowCount | number | 是 | 结果集中的行数。 | | isClosed | boolean | 是 | 标识当前结果集是否关闭。 | -## goToFirstRow +### goToFirstRow goToFirstRow(): boolean @@ -76,7 +79,7 @@ let isGoTOFirstRow = resultSet.goToFirstRow(); console.info('resultSet.goToFirstRow: ' + isGoTOFirstRow); ``` -## goToLastRow +### goToLastRow goToLastRow(): boolean @@ -97,7 +100,7 @@ let isGoToLastRow = resultSet.goToLastRow(); console.info('resultSet.goToLastRow: ' + isGoToLastRow); ``` -## goToNextRow +### goToNextRow goToNextRow(): boolean @@ -118,7 +121,7 @@ let isGoToNextRow = resultSet.goToNextRow(); console.info('resultSet.goToNextRow: ' + isGoToNextRow); ``` -## goToPreviousRow +### goToPreviousRow goToPreviousRow(): boolean @@ -139,7 +142,7 @@ let isGoToPreviousRow = resultSet.goToPreviousRow(); console.info('resultSet.goToPreviousRow: ' + isGoToPreviousRow); ``` -## goTo +### goTo goTo(offset:number): boolean @@ -167,7 +170,7 @@ let isGoTo = resultSet.goTo(goToNum); console.info('resultSet.goTo: ' + isGoTo); ``` -## goToRow +### goToRow goToRow(position: number): boolean @@ -195,7 +198,7 @@ let isGoToRow = resultSet.goToRow(goToRowNum); console.info('resultSet.goToRow: ' + isGoToRow); ``` -## getBlob +### getBlob getBlob(columnIndex: number): Uint8Array @@ -224,7 +227,7 @@ let getBlob = resultSet.getBlob(columnIndex); console.info('resultSet.getBlob: ' + getBlob); ``` -## getString +### getString getString(columnIndex: number): *string* @@ -253,7 +256,7 @@ let getString = resultSet.getString(columnIndex); console.info('resultSet.getString: ' + getString); ``` -## getLong +### getLong getLong(columnIndex: number): number @@ -282,7 +285,7 @@ let getLong = resultSet.getLong(columnIndex); console.info('resultSet.getLong: ' + getLong); ``` -## getDouble +### getDouble getDouble(columnIndex: number): number @@ -311,7 +314,7 @@ let getDouble = resultSet.getDouble(columnIndex); console.info('resultSet.getDouble: ' + getDouble); ``` -## close +### close close(): void @@ -325,7 +328,7 @@ close(): void resultSet.close(); ``` -## getColumnIndex +### getColumnIndex getColumnIndex(columnName: string): number @@ -353,7 +356,7 @@ let getColumnIndex = resultSet.getColumnIndex(ColumnName) console.info('resultSet.getColumnIndex: ' + getColumnIndex); ``` -## getColumnName +### getColumnName getColumnName(columnIndex: number): *string* @@ -381,7 +384,7 @@ let getColumnName = resultSet.getColumnName(columnIndex) console.info('resultSet.getColumnName: ' + getColumnName); ``` -## getDataType +### getDataType getDataType(columnIndex: number): DataType @@ -409,7 +412,7 @@ let getDataType = resultSet.getDataType(columnIndex); console.info('resultSet.getDataType: ' + getDataType); ``` -## DataType +### DataType 数据类型枚举。 diff --git a/zh-cn/application-dev/reference/apis/js-apis-data-dataSharePredicates.md b/zh-cn/application-dev/reference/apis/js-apis-data-dataSharePredicates.md index 7838b092adfab89d49626d67e093d056233841e0..91fcd5fa3bcd519cef639c39bdadfeac7b5b11b8 100644 --- a/zh-cn/application-dev/reference/apis/js-apis-data-dataSharePredicates.md +++ b/zh-cn/application-dev/reference/apis/js-apis-data-dataSharePredicates.md @@ -13,7 +13,10 @@ import dataSharePredicates from '@ohos.data.dataSharePredicates'; ``` -## equalTo +## DataSharePredicates +提供用于不同实现不同查询方法的数据共享谓词。 + +### equalTo equalTo(field: string, value: ValueType): DataSharePredicates @@ -43,7 +46,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.equalTo("NAME", "Rose") ``` -## notEqualTo +### notEqualTo notEqualTo(field: string, value: ValueType): DataSharePredicates @@ -73,7 +76,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.notEqualTo("NAME", "Rose") ``` -## beginWrap +### beginWrap beginWrap(): DataSharePredicates @@ -99,7 +102,7 @@ predicates.equalTo("NAME", "lisi") .endWrap() ``` -## endWrap +### endWrap endWrap(): DataSharePredicates @@ -125,7 +128,7 @@ predicates.equalTo("NAME", "lisi") .endWrap() ``` -## or +### or or(): DataSharePredicates @@ -150,7 +153,7 @@ predicates.equalTo("NAME", "lisi") .equalTo("NAME", "Rose") ``` -## and +### and and(): DataSharePredicates @@ -175,7 +178,7 @@ predicates.equalTo("NAME", "lisi") .equalTo("SALARY", 200.5) ``` -## contains +### contains contains(field: string, value: string): DataSharePredicates @@ -203,7 +206,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.contains("NAME", "os") ``` -## beginsWith +### beginsWith beginsWith(field: string, value: string): DataSharePredicates @@ -231,7 +234,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.beginsWith("NAME", "os") ``` -## endsWith +### endsWith endsWith(field: string, value: string): DataSharePredicates @@ -259,7 +262,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.endsWith("NAME", "os") ``` -## isNull +### isNull isNull(field: string): DataSharePredicates @@ -288,7 +291,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.isNull("NAME") ``` -## isNotNull +### isNotNull isNotNull(field: string): DataSharePredicates @@ -317,7 +320,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.isNotNull("NAME") ``` -## like +### like like(field: string, value: string): DataSharePredicates @@ -347,7 +350,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.like("NAME", "%os%") ``` -## unlike +### unlike unlike(field: string, value: string): DataSharePredicates @@ -377,7 +380,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.unlike("NAME", "%os%") ``` -## glob +### glob glob(field: string, value: string): DataSharePredicates @@ -405,7 +408,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.glob("NAME", "?h*g") ``` -## between +### between between(field: string, low: ValueType, high: ValueType): DataSharePredicates @@ -434,7 +437,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.between("AGE", 10, 50) ``` -## notBetween +### notBetween notBetween(field: string, low: ValueType, high: ValueType): DataSharePredicates @@ -463,7 +466,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.notBetween("AGE", 10, 50) ``` -## greaterThan +### greaterThan greaterThan(field: string, value: ValueType): DataSharePredicates @@ -493,7 +496,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.greaterThan("AGE", 10) ``` -## lessThan +### lessThan lessThan(field: string, value: ValueType): DataSharePredicates @@ -523,7 +526,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.lessThan("AGE", 50) ``` -## greaterThanOrEqualTo +### greaterThanOrEqualTo greaterThanOrEqualTo(field: string, value: ValueType): DataSharePredicates @@ -553,7 +556,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.greaterThanOrEqualTo("AGE", 10) ``` -## lessThanOrEqualTo +### lessThanOrEqualTo lessThanOrEqualTo(field: string, value: ValueType): DataSharePredicates @@ -583,7 +586,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.lessThanOrEqualTo("AGE", 50) ``` -## orderByAsc +### orderByAsc orderByAsc(field: string): DataSharePredicates @@ -612,7 +615,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.orderByAsc("AGE") ``` -## orderByDesc +### orderByDesc orderByDesc(field: string): DataSharePredicates @@ -641,7 +644,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.orderByDesc("AGE") ``` -## distinct +### distinct distinct(): DataSharePredicates @@ -662,7 +665,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.equalTo("NAME", "Rose").distinct() ``` -## limit +### limit limit(total: number, offset: number): DataSharePredicates @@ -692,7 +695,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.equalTo("NAME", "Rose").limit(10, 3) ``` -## groupBy +### groupBy groupBy(fields: Array<string>): DataSharePredicates @@ -719,7 +722,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.groupBy(["AGE", "NAME"]) ``` -## indexedBy +### indexedBy indexedBy(field: string): DataSharePredicates @@ -746,7 +749,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.indexedBy("SALARY_INDEX") ``` -## in +### in in(field: string, value: Array<ValueType>): DataSharePredicates @@ -776,7 +779,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.in("AGE", [18, 20]) ``` -## notIn +### notIn notIn(field: string, value: Array<ValueType>): DataSharePredicates @@ -806,7 +809,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.notIn("NAME", ["Lisa", "Rose"]) ``` -## prefixKey +### prefixKey prefixKey(prefix: string): DataSharePredicates @@ -833,7 +836,7 @@ let predicates = new dataSharePredicates.DataSharePredicates() predicates.prefixKey("NAME") ``` -## inKeys +### inKeys inKeys(keys: Array<string>): DataSharePredicates diff --git a/zh-cn/application-dev/reference/apis/js-apis-distributed-data.md b/zh-cn/application-dev/reference/apis/js-apis-distributed-data.md index bd152440040fafe3f942517a16bc48e5ec87e27b..2891df33086e845fed7519788251641cfe6039ca 100644 --- a/zh-cn/application-dev/reference/apis/js-apis-distributed-data.md +++ b/zh-cn/application-dev/reference/apis/js-apis-distributed-data.md @@ -3718,7 +3718,7 @@ getResultSet(predicates: dataSharePredicates.DataSharePredicates, callback: Asyn | 参数名 | 参数类型 | 必填 | 说明 | | ----- | ------ | ---- | ----------------------- | | predicates | [DataSharePredicates](js-apis-data-DataSharePredicates.md#datasharepredicates) | 是 |指示筛选条件,当此参数为null时,应定义处理逻辑。 | -| callback |AsyncCallback<[KvStoreResultSet](#kvstoreresultsetsup8sup)> | 是 |回调函数,获取与指定Predicates对象匹配的KvStoreResultSet对象。 | +| callback |AsyncCallback<[KvStoreResultSet](#kvstoreresultset8)> | 是 |回调函数,获取与指定Predicates对象匹配的KvStoreResultSet对象。 | **示例:** @@ -4202,7 +4202,7 @@ sync(deviceIds: string[], query: Query, mode: SyncMode, delayMs?: number): void | ----- | ------ | ---- | ----------------------- | | deviceIds |string[] | 是 |同一组网环境下,需要同步的设备的deviceId列表。 | | mode |[SyncMode](#syncmode) | 是 |同步模式。 | -| query |[Query](#querysup8sup) | 是 |表示数据库的查询谓词条件 | +| query |[Query](#query8) | 是 |表示数据库的查询谓词条件 | | delayMs |number | 否 |可选参数,允许延时时间,单位:ms(毫秒)。 | **示例:** diff --git a/zh-cn/application-dev/reference/apis/js-apis-screen.md b/zh-cn/application-dev/reference/apis/js-apis-screen.md index 5c776f930e037764b5db855278d7acdeb6e48fbe..714cfacfe0b4214c68d8d7f739f2fecb3d6f23bd 100644 --- a/zh-cn/application-dev/reference/apis/js-apis-screen.md +++ b/zh-cn/application-dev/reference/apis/js-apis-screen.md @@ -531,7 +531,7 @@ screen.setScreenRotationLocked(isLocked, (err, data) => { | parent | number | 是 | 否 | 屏幕所属群组的id。 | | supportedModeInfo | Array<[ScreenModeInfo](#screenmodeinfo)> | 是 | 否 | 屏幕支持的模式集合。 | | activeModeIndex | number | 是 | 否 | 当前屏幕所处模式索引。 | -| orientation | [Orientation](#rientation) | 是 | 否 | 屏幕方向。 | +| orientation | [Orientation](#orientation) | 是 | 否 | 屏幕方向。 | ### setOrientation setOrientation(orientation: Orientation, callback: AsyncCallback<void>): void