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 OHOS_ABILITY_RUNTIME_INSIGHT_INTENT_INFO_FOR_QUERY_H 17 #define OHOS_ABILITY_RUNTIME_INSIGHT_INTENT_INFO_FOR_QUERY_H 18 19 #include <string> 20 #include <vector> 21 22 #include "parcel.h" 23 #include "insight_intent_constant.h" 24 #include "insight_intent_execute_param.h" 25 26 namespace OHOS { 27 namespace AbilityRuntime { 28 struct LinkInfoForQuery { 29 std::string uri; 30 }; 31 32 struct PageInfoForQuery { 33 std::string uiAbility; 34 std::string pagePath; 35 std::string navigationId; 36 std::string navDestinationName; 37 }; 38 39 struct EntryInfoForQuery { 40 std::string abilityName; 41 std::vector<AppExecFwk::ExecuteMode> executeMode; 42 }; 43 44 struct FunctionInfoForQuery {}; 45 46 struct FormInfoForQuery { 47 std::string abilityName; 48 std::string formName; 49 }; 50 51 struct EntityInfoForQuery { 52 std::string className; 53 std::string entityId; 54 std::string entityCategory; 55 std::string parameters; 56 std::string parentClassName; 57 }; 58 59 struct InsightIntentInfoForQuery : public Parcelable { 60 std::string bundleName; 61 std::string moduleName; 62 std::string intentName; 63 std::string domain; 64 std::string intentVersion; 65 std::string displayName; 66 std::string displayDescription; 67 std::string schema; 68 std::string icon; 69 std::string llmDescription; 70 std::string intentType; 71 std::string parameters; 72 std::string result; 73 std::vector<std::string> keywords; 74 LinkInfoForQuery linkInfo; 75 PageInfoForQuery pageInfo; 76 EntryInfoForQuery entryInfo; 77 FunctionInfoForQuery functionInfo; 78 FormInfoForQuery formInfo; 79 std::vector<EntityInfoForQuery> entities {}; 80 81 bool ReadFromParcel(Parcel &parcel); 82 virtual bool Marshalling(Parcel &parcel) const override; 83 static InsightIntentInfoForQuery *Unmarshalling(Parcel &parcel); 84 }; 85 } // namespace AbilityRuntime 86 } // namespace OHOS 87 #endif // OHOS_ABILITY_RUNTIME_INSIGHT_INTENT_INFO_FOR_QUERY_H 88