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 16syntax = "proto3"; 17package protoPanda; 18 19message VariantValue { 20 enum VariantValueType { 21 BOOL = 0; 22 U8 = 1; 23 U16 = 2; 24 U32 = 3; 25 U64 = 4; 26 F32 = 5; 27 F64 = 6; 28 STRING = 7; 29 } 30 31 oneof value { 32 uint64 valueInt = 1; 33 float valueFloat = 2; 34 double valueDouble = 3; 35 bytes valueStr = 4; 36 } 37 VariantValueType type = 5; 38} 39 40message Literal { 41 uint32 tag = 1; // LiteralTag 42 VariantValue value = 2; 43} 44 45message LiteralArray { 46 repeated Literal literals = 1; 47} 48