Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
interned_data.pbzero.h
Go to the documentation of this file.
1// Copyright (c) 2023, the Dart project authors. Please see the AUTHORS file
2// for details. All rights reserved. Use of this source code is governed by a
3// BSD-style license that can be found in the LICENSE file.
4
5// IMPORTANT: This file should only ever be modified by modifying the
6// corresponding .proto file and then running
7// `dart runtime/vm/protos/tools/compile_perfetto_protos.dart` from the SDK root
8// directory.
9// Autogenerated by the ProtoZero compiler plugin. DO NOT EDIT.
10
11#ifndef PERFETTO_PROTOS_PROTOS_PERFETTO_TRACE_INTERNED_DATA_INTERNED_DATA_PROTO_H_
12#define PERFETTO_PROTOS_PROTOS_PERFETTO_TRACE_INTERNED_DATA_INTERNED_DATA_PROTO_H_
13
14#include <stddef.h>
15#include <stdint.h>
16
17#include "perfetto/protozero/field_writer.h"
18#include "perfetto/protozero/message.h"
19#include "perfetto/protozero/packed_repeated_fields.h"
20#include "perfetto/protozero/proto_decoder.h"
21#include "perfetto/protozero/proto_utils.h"
22
23namespace perfetto {
24namespace protos {
25namespace pbzero {
26
27class Callstack;
28class Frame;
29class InternedString;
30class Mapping;
31
32class InternedData_Decoder : public ::protozero::TypedProtoDecoder<
33 /*MAX_FIELD_ID=*/19,
34 /*HAS_NONPACKED_REPEATED_FIELDS=*/true> {
35 public:
36 InternedData_Decoder(const uint8_t* data, size_t len)
37 : TypedProtoDecoder(data, len) {}
38 explicit InternedData_Decoder(const std::string& raw)
39 : TypedProtoDecoder(reinterpret_cast<const uint8_t*>(raw.data()),
40 raw.size()) {}
41 explicit InternedData_Decoder(const ::protozero::ConstBytes& raw)
42 : TypedProtoDecoder(raw.data, raw.size) {}
43 bool has_mapping_paths() const { return at<17>().valid(); }
44 ::protozero::RepeatedFieldIterator<::protozero::ConstBytes> mapping_paths()
45 const {
46 return GetRepeated<::protozero::ConstBytes>(17);
47 }
48 bool has_function_names() const { return at<5>().valid(); }
49 ::protozero::RepeatedFieldIterator<::protozero::ConstBytes> function_names()
50 const {
51 return GetRepeated<::protozero::ConstBytes>(5);
52 }
53 bool has_mappings() const { return at<19>().valid(); }
54 ::protozero::RepeatedFieldIterator<::protozero::ConstBytes> mappings() const {
55 return GetRepeated<::protozero::ConstBytes>(19);
56 }
57 bool has_frames() const { return at<6>().valid(); }
58 ::protozero::RepeatedFieldIterator<::protozero::ConstBytes> frames() const {
59 return GetRepeated<::protozero::ConstBytes>(6);
60 }
61 bool has_callstacks() const { return at<7>().valid(); }
62 ::protozero::RepeatedFieldIterator<::protozero::ConstBytes> callstacks()
63 const {
64 return GetRepeated<::protozero::ConstBytes>(7);
65 }
66};
67
68class InternedData : public ::protozero::Message {
69 public:
71 enum : int32_t {
77 };
78 static constexpr const char* GetName() {
79 return ".perfetto.protos.InternedData";
80 }
81
82 using FieldMetadata_MappingPaths = ::protozero::proto_utils::FieldMetadata<
83 17,
84 ::protozero::proto_utils::RepetitionType::kRepeatedNotPacked,
85 ::protozero::proto_utils::ProtoSchemaType::kMessage,
88
89 // Ceci n'est pas une pipe.
90 // This is actually a variable of FieldMetadataHelper<FieldMetadata<...>>
91 // type (and users are expected to use it as such, hence kCamelCase name).
92 // It is declared as a function to keep protozero bindings header-only as
93 // inline constexpr variables are not available until C++17 (while inline
94 // functions are).
95 // TODO(altimin): Use inline variable instead after adopting C++17.
96 static constexpr FieldMetadata_MappingPaths kMappingPaths() { return {}; }
97 template <typename T = InternedString>
99 return BeginNestedMessage<T>(17);
100 }
101
102 using FieldMetadata_FunctionNames = ::protozero::proto_utils::FieldMetadata<
103 5,
104 ::protozero::proto_utils::RepetitionType::kRepeatedNotPacked,
105 ::protozero::proto_utils::ProtoSchemaType::kMessage,
108
109 // Ceci n'est pas une pipe.
110 // This is actually a variable of FieldMetadataHelper<FieldMetadata<...>>
111 // type (and users are expected to use it as such, hence kCamelCase name).
112 // It is declared as a function to keep protozero bindings header-only as
113 // inline constexpr variables are not available until C++17 (while inline
114 // functions are).
115 // TODO(altimin): Use inline variable instead after adopting C++17.
116 static constexpr FieldMetadata_FunctionNames kFunctionNames() { return {}; }
117 template <typename T = InternedString>
119 return BeginNestedMessage<T>(5);
120 }
121
122 using FieldMetadata_Mappings = ::protozero::proto_utils::FieldMetadata<
123 19,
124 ::protozero::proto_utils::RepetitionType::kRepeatedNotPacked,
125 ::protozero::proto_utils::ProtoSchemaType::kMessage,
126 Mapping,
128
129 // Ceci n'est pas une pipe.
130 // This is actually a variable of FieldMetadataHelper<FieldMetadata<...>>
131 // type (and users are expected to use it as such, hence kCamelCase name).
132 // It is declared as a function to keep protozero bindings header-only as
133 // inline constexpr variables are not available until C++17 (while inline
134 // functions are).
135 // TODO(altimin): Use inline variable instead after adopting C++17.
136 static constexpr FieldMetadata_Mappings kMappings() { return {}; }
137 template <typename T = Mapping>
139 return BeginNestedMessage<T>(19);
140 }
141
142 using FieldMetadata_Frames = ::protozero::proto_utils::FieldMetadata<
143 6,
144 ::protozero::proto_utils::RepetitionType::kRepeatedNotPacked,
145 ::protozero::proto_utils::ProtoSchemaType::kMessage,
146 Frame,
148
149 // Ceci n'est pas une pipe.
150 // This is actually a variable of FieldMetadataHelper<FieldMetadata<...>>
151 // type (and users are expected to use it as such, hence kCamelCase name).
152 // It is declared as a function to keep protozero bindings header-only as
153 // inline constexpr variables are not available until C++17 (while inline
154 // functions are).
155 // TODO(altimin): Use inline variable instead after adopting C++17.
156 static constexpr FieldMetadata_Frames kFrames() { return {}; }
157 template <typename T = Frame>
159 return BeginNestedMessage<T>(6);
160 }
161
162 using FieldMetadata_Callstacks = ::protozero::proto_utils::FieldMetadata<
163 7,
164 ::protozero::proto_utils::RepetitionType::kRepeatedNotPacked,
165 ::protozero::proto_utils::ProtoSchemaType::kMessage,
166 Callstack,
168
169 // Ceci n'est pas une pipe.
170 // This is actually a variable of FieldMetadataHelper<FieldMetadata<...>>
171 // type (and users are expected to use it as such, hence kCamelCase name).
172 // It is declared as a function to keep protozero bindings header-only as
173 // inline constexpr variables are not available until C++17 (while inline
174 // functions are).
175 // TODO(altimin): Use inline variable instead after adopting C++17.
176 static constexpr FieldMetadata_Callstacks kCallstacks() { return {}; }
177 template <typename T = Callstack>
179 return BeginNestedMessage<T>(7);
180 }
181};
182
183} // namespace pbzero
184} // namespace protos
185} // namespace perfetto
186#endif // Include guard.
InternedData_Decoder(const ::protozero::ConstBytes &raw)
::protozero::RepeatedFieldIterator<::protozero::ConstBytes > mappings() const
::protozero::RepeatedFieldIterator<::protozero::ConstBytes > frames() const
::protozero::RepeatedFieldIterator<::protozero::ConstBytes > callstacks() const
::protozero::RepeatedFieldIterator<::protozero::ConstBytes > function_names() const
InternedData_Decoder(const uint8_t *data, size_t len)
::protozero::RepeatedFieldIterator<::protozero::ConstBytes > mapping_paths() const
::protozero::proto_utils::FieldMetadata< 7, ::protozero::proto_utils::RepetitionType::kRepeatedNotPacked, ::protozero::proto_utils::ProtoSchemaType::kMessage, Callstack, InternedData > FieldMetadata_Callstacks
static constexpr FieldMetadata_FunctionNames kFunctionNames()
static constexpr const char * GetName()
::protozero::proto_utils::FieldMetadata< 6, ::protozero::proto_utils::RepetitionType::kRepeatedNotPacked, ::protozero::proto_utils::ProtoSchemaType::kMessage, Frame, InternedData > FieldMetadata_Frames
static constexpr FieldMetadata_MappingPaths kMappingPaths()
::protozero::proto_utils::FieldMetadata< 17, ::protozero::proto_utils::RepetitionType::kRepeatedNotPacked, ::protozero::proto_utils::ProtoSchemaType::kMessage, InternedString, InternedData > FieldMetadata_MappingPaths
::protozero::proto_utils::FieldMetadata< 5, ::protozero::proto_utils::RepetitionType::kRepeatedNotPacked, ::protozero::proto_utils::ProtoSchemaType::kMessage, InternedString, InternedData > FieldMetadata_FunctionNames
static constexpr FieldMetadata_Frames kFrames()
static constexpr FieldMetadata_Callstacks kCallstacks()
::protozero::proto_utils::FieldMetadata< 19, ::protozero::proto_utils::RepetitionType::kRepeatedNotPacked, ::protozero::proto_utils::ProtoSchemaType::kMessage, Mapping, InternedData > FieldMetadata_Mappings
static constexpr FieldMetadata_Mappings kMappings()
#define T