/* * Copyright (C) 2017 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #ifndef INCLUDE_PERFETTO_PROTOZERO_MESSAGE_H_ #define INCLUDE_PERFETTO_PROTOZERO_MESSAGE_H_ #include <assert.h> #include <stdint.h> #include <string.h> #include <string> #include <type_traits> #include "perfetto/base/export.h" #include "perfetto/base/logging.h" #include "perfetto/protozero/contiguous_memory_range.h" #include "perfetto/protozero/proto_utils.h" #include "perfetto/protozero/scattered_stream_writer.h" namespace perfetto { namespace shm_fuzz { class FakeProducer; } // namespace shm_fuzz } // namespace perfetto namespace protozero { class MessageArena; class MessageHandleBase; // Base class extended by the proto C++ stubs generated by the ProtoZero // compiler. This class provides the minimal runtime required to support // append-only operations and is designed for performance. None of the methods // require any dynamic memory allocation, unless more than 16 nested messages // are created via BeginNestedMessage() calls. class PERFETTO_EXPORT_COMPONENT Message { … }; } // namespace protozero #endif // INCLUDE_PERFETTO_PROTOZERO_MESSAGE_H_