1/* 2 * Copyright (c) 2022 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 16class DataShareExtensionAbility { 17 onCreate(want) { 18 console.log('onCreate, want:' + want.abilityName); 19 } 20 21 getFileTypes(uri, mimeTypeFilter) { 22 console.log('getFileTypes, uri:' + uri); 23 } 24 25 openFile(uri, mode) { 26 console.log('openFile, uri:' + uri); 27 } 28 29 openRawFile(uri, mode) { 30 console.log('openRawFile, uri:' + uri); 31 } 32 33 insert(uri, value) { 34 console.log('insert, uri:' + uri); 35 } 36 37 update(uri, value, predicates) { 38 console.log('update, uri:' + uri); 39 } 40 41 delete(uri, predicates) { 42 console.log('delete, uri:' + uri); 43 } 44 45 query(uri, columns, predicates) { 46 console.log('query, uri:' + uri); 47 } 48 49 getType(uri) { 50 console.log('getType, uri:' + uri); 51 } 52 53 batchInsert(uri, values) { 54 console.log('batchInsert, uri:' + uri); 55 } 56 57 normalizeUri(uri) { 58 console.log('normalizeUri, uri:' + uri); 59 } 60 61 denormalizeUri(uri) { 62 console.log('denormalizeUri, uri:' + uri); 63 } 64} 65 66export default DataShareExtensionAbility