1 // Copyright 2019-2023:
2 // GobySoft, LLC (2013-)
3 // Community contributors (see AUTHORS file)
5 // Toby Schneider <toby@gobysoft.org>
6 // Davide Fenucci <davfen@noc.ac.uk>
9 // This file is part of the Dynamic Compact Control Language Library
12 // DCCL is free software: you can redistribute it and/or modify
13 // it under the terms of the GNU Lesser General Public License as published by
14 // the Free Software Foundation, either version 2.1 of the License, or
15 // (at your option) any later version.
17 // DCCL is distributed in the hope that it will be useful,
18 // but WITHOUT ANY WARRANTY; without even the implied warranty of
19 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 // GNU Lesser General Public License for more details.
22 // You should have received a copy of the GNU Lesser General Public License
23 // along with DCCL. If not, see <http://www.gnu.org/licenses/>.
26 import "dccl/option_extensions.proto";
32 optional double val = 1 [
34 (dccl.field).max = 126,
35 (dccl.field).precision = 3
39 int32 int32_nested_oneof = 116
40 [(dccl.field).min = 0, (dccl.field).max = 31];
41 double double_nested_oneof = 117
42 [(dccl.field).min = -1, (dccl.field).max = 126];
48 option (dccl.msg).id = 2;
49 option (dccl.msg).max_bytes = 32;
50 option (dccl.msg).codec_version = 4;
54 double double_oneof1 = 118 [
55 (dccl.field).min = -100,
56 (dccl.field).max = 126,
57 (dccl.field).precision = 2
60 EmbeddedMsg1 msg_oneof1 = 119;
61 double non_default_double = 122
62 [(dccl.field).codec = "dccl.native_protobuf"];
67 int32 int32_oneof2 = 120
68 [(dccl.field).min = -20, (dccl.field).max = 3000];
69 EmbeddedMsg1 msg_oneof2 = 121;
73 message InvalidTestMsg
75 option (dccl.msg).id = 3;
76 option (dccl.msg).max_bytes = 32;
77 option (dccl.msg).codec_version = 4;
81 double double_oneof1 = 118 [
82 (dccl.field).min = -100,
83 (dccl.field).max = 126,
84 (dccl.field).in_head = true,
85 (dccl.field).precision = 2
88 EmbeddedMsg1 msg_oneof1 = 119;
93 int32 int32_oneof2 = 120
94 [(dccl.field).min = -20, (dccl.field).max = 3000];
95 EmbeddedMsg1 msg_oneof2 = 121;