未验证 提交 7225cf24 编写于 作者: O openharmony_ci 提交者: Gitee

!6974 3.1Release分支:示例代码中拼写错误修改:无需翻译

Merge pull request !6974 from 葛亚芳/OpenHarmony-3.1-Release
......@@ -774,7 +774,7 @@ let kvStore;
try {
let resultSet;
kvStore.getResultSet('batch_test_string_key').then((result) => {
console.log('getResultSet succeeed.');
console.log('getResultSet succeeded.');
resultSet = result;
}).catch((err) => {
console.log('getResultSet failed:' + err);
......@@ -2341,10 +2341,10 @@ try {
console.log('entries: ' + JSON.stringify(entries));
kvStore.putBatch(entries, async function (err,data) {
console.log('putBatch success');
kvStore.getEntries('batch_test_string_key', function (err,entrys) {
kvStore.getEntries('batch_test_string_key', function (err,entries) {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
});
});
}catch(e) {
......@@ -2393,7 +2393,7 @@ try {
console.log('entries: ' + JSON.stringify(entries));
kvStore.putBatch(entries).then(async (err) => {
console.log('putBatch success');
kvStore.getEntries('batch_test_string_key').then((entrys) => {
kvStore.getEntries('batch_test_string_key').then((entries) => {
console.log('getEntries success');
console.log('PutBatch ' + JSON.stringify(entries));
}).catch((err) => {
......@@ -3049,10 +3049,10 @@ try {
}
kvStore.putBatch(entries, async function (err,data) {
console.log('putBatch success');
kvStore.getEntries('batch_test_number_key', function (err,entrys) {
kvStore.getEntries('batch_test_number_key', function (err,entries) {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
});
});
}catch(e) {
......@@ -3101,12 +3101,12 @@ try {
console.log('entries: ' + entries);
kvStore.putBatch(entries).then(async (err) => {
console.log('putBatch success');
kvStore.getEntries('batch_test_string_key').then((entrys) => {
kvStore.getEntries('batch_test_string_key').then((entries) => {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entrys[0].value: ' + JSON.stringify(entrys[0].value));
console.log('entrys[0].value.value: ' + entrys[0].value.value);
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
console.log('entries[0].value: ' + JSON.stringify(entries[0].value));
console.log('entries[0].value.value: ' + entries[0].value.value);
}).catch((err) => {
console.log('getEntries fail ' + JSON.stringify(err));
});
......@@ -3157,10 +3157,10 @@ try {
console.log('putBatch success');
const query = new distributedData.Query();
query.prefixKey("batch_test");
kvStore.getEntries(query, function (err,entrys) {
kvStore.getEntries(query, function (err,entries) {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
});
});
console.log('GetEntries success');
......@@ -3213,7 +3213,7 @@ try {
console.log('putBatch success');
const query = new distributedData.Query();
query.prefixKey("batch_test");
kvStore.getEntries(query).then((entrys) => {
kvStore.getEntries(query).then((entries) => {
console.log('getEntries success');
}).catch((err) => {
console.log('getEntries fail ' + JSON.stringify(err));
......@@ -4047,10 +4047,10 @@ try {
console.log('entries: ' + entries);
kvStore.putBatch(entries, async function (err,data) {
console.log('putBatch success');
kvStore.getEntries('localDeviceId', 'batch_test_string_key', function (err,entrys) {
kvStore.getEntries('localDeviceId', 'batch_test_string_key', function (err,entries) {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
});
});
}catch(e) {
......@@ -4100,12 +4100,12 @@ try {
console.log('entries: ' + entries);
kvStore.putBatch(entries).then(async (err) => {
console.log('putBatch success');
kvStore.getEntries('localDeviceId', 'batch_test_string_key').then((entrys) => {
kvStore.getEntries('localDeviceId', 'batch_test_string_key').then((entries) => {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entrys[0].value: ' + JSON.stringify(entrys[0].value));
console.log('entrys[0].value.value: ' + entrys[0].value.value);
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
console.log('entries[0].value: ' + JSON.stringify(entries[0].value));
console.log('entries[0].value.value: ' + entries[0].value.value);
}).catch((err) => {
console.log('getEntries fail ' + JSON.stringify(err));
});
......@@ -4157,10 +4157,10 @@ try {
const query = new distributedData.Query();
query.prefixKey("batch_test");
query.deviceId('localDeviceId');
kvStore.getEntries(query, function (err,entrys) {
kvStore.getEntries(query, function (err,entries) {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
});
});
console.log('GetEntries success');
......@@ -4213,7 +4213,7 @@ try {
console.log('putBatch success');
const query = new distributedData.Query();
query.prefixKey("batch_test");
kvStore.getEntries(query).then((entrys) => {
kvStore.getEntries(query).then((entries) => {
console.log('getEntries success');
}).catch((err) => {
console.log('getEntries fail ' + JSON.stringify(err));
......@@ -4268,10 +4268,10 @@ try {
var query = new distributedData.Query();
query.deviceId('localDeviceId');
query.prefixKey("batch_test");
kvStore.getEntries('localDeviceId', query, function (err,entrys) {
kvStore.getEntries('localDeviceId', query, function (err,entries) {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
})
});
console.log('GetEntries success');
......@@ -4326,7 +4326,7 @@ try {
var query = new distributedData.Query();
query.deviceId('localDeviceId');
query.prefixKey("batch_test");
kvStore.getEntries('localDeviceId', query).then((entrys) => {
kvStore.getEntries('localDeviceId', query).then((entries) => {
console.log('getEntries success');
}).catch((err) => {
console.log('getEntries fail ' + JSON.stringify(err));
......
......@@ -774,7 +774,7 @@ let kvStore;
try {
let resultSet;
kvStore.getResultSet('batch_test_string_key').then((result) => {
console.log('getResultSet succeeed.');
console.log('getResultSet succeeded.');
resultSet = result;
}).catch((err) => {
console.log('getResultSet failed: ' + err);
......@@ -2341,10 +2341,10 @@ try {
console.log('entries: ' + JSON.stringify(entries));
kvStore.putBatch(entries, async function (err,data) {
console.log('putBatch success');
kvStore.getEntries('batch_test_string_key', function (err,entrys) {
kvStore.getEntries('batch_test_string_key', function (err,entries) {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
});
});
}catch(e) {
......@@ -2393,7 +2393,7 @@ try {
console.log('entries: ' + JSON.stringify(entries));
kvStore.putBatch(entries).then(async (err) => {
console.log('putBatch success');
kvStore.getEntries('batch_test_string_key').then((entrys) => {
kvStore.getEntries('batch_test_string_key').then((entries) => {
console.log('getEntries success');
console.log('PutBatch ' + JSON.stringify(entries));
}).catch((err) => {
......@@ -3049,10 +3049,10 @@ try {
}
kvStore.putBatch(entries, async function (err,data) {
console.log('putBatch success');
kvStore.getEntries('batch_test_number_key', function (err,entrys) {
kvStore.getEntries('batch_test_number_key', function (err,entries) {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
});
});
}catch(e) {
......@@ -3101,12 +3101,12 @@ try {
console.log('entries: ' + entries);
kvStore.putBatch(entries).then(async (err) => {
console.log('putBatch success');
kvStore.getEntries('batch_test_string_key').then((entrys) => {
kvStore.getEntries('batch_test_string_key').then((entries) => {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entrys[0].value: ' + JSON.stringify(entrys[0].value));
console.log('entrys[0].value.value: ' + entrys[0].value.value);
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
console.log('entries[0].value: ' + JSON.stringify(entries[0].value));
console.log('entries[0].value.value: ' + entries[0].value.value);
}).catch((err) => {
console.log('getEntries fail ' + JSON.stringify(err));
});
......@@ -3157,10 +3157,10 @@ try {
console.log('putBatch success');
const query = new distributedData.Query();
query.prefixKey("batch_test");
kvStore.getEntries(query, function (err,entrys) {
kvStore.getEntries(query, function (err,entries) {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
});
});
console.log('GetEntries success');
......@@ -3213,7 +3213,7 @@ try {
console.log('putBatch success');
const query = new distributedData.Query();
query.prefixKey("batch_test");
kvStore.getEntries(query).then((entrys) => {
kvStore.getEntries(query).then((entries) => {
console.log('getEntries success');
}).catch((err) => {
console.log('getEntries fail ' + JSON.stringify(err));
......@@ -4047,10 +4047,10 @@ try {
console.log('entries: ' + entries);
kvStore.putBatch(entries, async function (err,data) {
console.log('putBatch success');
kvStore.getEntries('localDeviceId', 'batch_test_string_key', function (err,entrys) {
kvStore.getEntries('localDeviceId', 'batch_test_string_key', function (err,entries) {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
});
});
}catch(e) {
......@@ -4100,12 +4100,12 @@ try {
console.log('entries: ' + entries);
kvStore.putBatch(entries).then(async (err) => {
console.log('putBatch success');
kvStore.getEntries('localDeviceId', 'batch_test_string_key').then((entrys) => {
kvStore.getEntries('localDeviceId', 'batch_test_string_key').then((entries) => {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entrys[0].value: ' + JSON.stringify(entrys[0].value));
console.log('entrys[0].value.value: ' + entrys[0].value.value);
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
console.log('entries[0].value: ' + JSON.stringify(entries[0].value));
console.log('entries[0].value.value: ' + entries[0].value.value);
}).catch((err) => {
console.log('getEntries fail ' + JSON.stringify(err));
});
......@@ -4157,10 +4157,10 @@ try {
const query = new distributedData.Query();
query.prefixKey("batch_test");
query.deviceId('localDeviceId');
kvStore.getEntries(query, function (err,entrys) {
kvStore.getEntries(query, function (err,entries) {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
});
});
console.log('GetEntries success');
......@@ -4213,7 +4213,7 @@ try {
console.log('putBatch success');
const query = new distributedData.Query();
query.prefixKey("batch_test");
kvStore.getEntries(query).then((entrys) => {
kvStore.getEntries(query).then((entries) => {
console.log('getEntries success');
}).catch((err) => {
console.log('getEntries fail ' + JSON.stringify(err));
......@@ -4268,10 +4268,10 @@ try {
var query = new distributedData.Query();
query.deviceId('localDeviceId');
query.prefixKey("batch_test");
kvStore.getEntries('localDeviceId', query, function (err,entrys) {
kvStore.getEntries('localDeviceId', query, function (err,entries) {
console.log('getEntries success');
console.log('entrys.length: ' + entrys.length);
console.log('entrys[0]: ' + JSON.stringify(entrys[0]));
console.log('entries.length: ' + entries.length);
console.log('entries[0]: ' + JSON.stringify(entries[0]));
})
});
console.log('GetEntries success');
......@@ -4326,7 +4326,7 @@ try {
var query = new distributedData.Query();
query.deviceId('localDeviceId');
query.prefixKey("batch_test");
kvStore.getEntries('localDeviceId', query).then((entrys) => {
kvStore.getEntries('localDeviceId', query).then((entries) => {
console.log('getEntries success');
}).catch((err) => {
console.log('getEntries fail ' + JSON.stringify(err));
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册