1 /* 2 * Copyright (c) 2025 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 16 #ifndef MOCK_OHOS_ABILITY_BASE_ELEMENT_NAME_H 17 #define MOCK_OHOS_ABILITY_BASE_ELEMENT_NAME_H 18 19 #include <string> 20 #include "parcel.h" 21 22 namespace OHOS { 23 namespace AppExecFwk { 24 class ElementName : public Parcelable { 25 public: GetURI()26 std::string GetURI() const 27 { 28 return ""; 29 } 30 ParseURI(const std::string & uri)31 bool ParseURI(const std::string &uri) 32 { 33 return false; 34 } 35 36 bool operator==(const ElementName &element) const 37 { 38 return false; 39 } 40 SetDeviceID(const std::string & id)41 void SetDeviceID(const std::string &id) {} 42 GetDeviceID()43 std::string GetDeviceID() const 44 { 45 return ""; 46 } 47 SetBundleName(const std::string & name)48 void SetBundleName(const std::string &name) {} 49 GetBundleName()50 std::string GetBundleName() const 51 { 52 return ""; 53 } 54 SetAbilityName(const std::string & name)55 void SetAbilityName(const std::string &name) {} 56 GetAbilityName()57 std::string GetAbilityName() const 58 { 59 return ""; 60 } 61 SetModuleName(const std::string & moduleName)62 void SetModuleName(const std::string &moduleName) {} 63 GetModuleName()64 std::string GetModuleName() const 65 { 66 return ""; 67 } 68 ReadFromParcel(Parcel & parcel)69 bool ReadFromParcel(Parcel &parcel) 70 { 71 return false; 72 } Marshalling(Parcel & parcel)73 virtual bool Marshalling(Parcel &parcel) const override 74 { 75 return false; 76 } Unmarshalling(Parcel & parcel)77 static ElementName *Unmarshalling(Parcel &parcel) 78 { 79 return nullptr; 80 } 81 }; 82 } // namespace AppExecFwk 83 } // namespace OHOS 84 #endif