1 /* 2 * Copyright (c) 2023-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 FOUNDATION_BUNDLE_FRAMEWORK_AOT_AOT_ARGS 17 #define FOUNDATION_BUNDLE_FRAMEWORK_AOT_AOT_ARGS 18 19 #include "message_parcel.h" 20 21 namespace OHOS { 22 namespace AppExecFwk { 23 struct HspInfo : public Parcelable { 24 uint32_t versionCode = 0; 25 uint32_t offset = 0; 26 uint32_t length = 0; 27 std::string bundleName; 28 std::string moduleName; 29 std::string hapPath; 30 std::string moduleArkTSMode; 31 32 std::string ToString() const; 33 bool ReadFromParcel(Parcel &parcel); 34 virtual bool Marshalling(Parcel &parcel) const override; 35 static HspInfo *Unmarshalling(Parcel &parcel); 36 }; 37 38 struct AOTArgs : public Parcelable { 39 uint32_t offset = 0; 40 uint32_t length = 0; 41 uint32_t isEncryptedBundle = 0; 42 uint32_t isScreenOff = 0; 43 uint32_t isEnableBaselinePgo = 0; 44 int32_t bundleUid = -1; 45 int32_t bundleGid = -1; 46 std::string bundleName; 47 std::string moduleName; 48 std::string compileMode; 49 std::string hapPath; 50 std::string coreLibPath; 51 std::string outputPath; 52 std::string arkProfilePath; 53 std::string anFileName; 54 std::string appIdentifier; 55 std::string optBCRangeList; 56 std::string moduleArkTSMode; 57 std::vector<HspInfo> hspVector; 58 59 bool isSysComp = false; 60 std::string sysCompPath; 61 62 std::string ToString() const; 63 bool ReadFromParcel(Parcel &parcel); 64 virtual bool Marshalling(Parcel &parcel) const override; 65 static AOTArgs *Unmarshalling(Parcel &parcel); 66 }; 67 } // namespace AppExecFwk 68 } // namespace OHOS 69 #endif // FOUNDATION_BUNDLE_FRAMEWORK_AOT_AOT_ARGS 70