Fix stuff
This commit is contained in:
@@ -1,8 +1,21 @@
|
||||
// @generated by protoc-gen-roto — do not edit
|
||||
#![allow(unused_imports)]
|
||||
#[allow(unused_imports)]
|
||||
|
||||
use roto_runtime::{ProtoAccessor, ProtoBuilder, Result, RotoError, read_varint, RepeatedFieldIterator};
|
||||
use std::str;
|
||||
use bytes::{Bytes, BytesMut, Buf, BufMut};
|
||||
use tonic::{Request, Response, Status};
|
||||
use tokio_stream::Stream;
|
||||
use std::pin::Pin;
|
||||
use std::sync::Arc;
|
||||
use std::task::{Context, Poll};
|
||||
use std::future::Future;
|
||||
use tonic::body::BoxBody;
|
||||
use tower::Service;
|
||||
use futures_util::StreamExt;
|
||||
use http_body_util::BodyExt;
|
||||
use http_body::Body;
|
||||
use roto_tonic::{BufferPool, StatusBody};
|
||||
|
||||
|
||||
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
||||
@@ -141,6 +154,27 @@ impl<'b> FileDescriptorSetBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedFileDescriptorSet {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedFileDescriptorSet {
|
||||
type Reader<'a> = FileDescriptorSet<'a>;
|
||||
fn reader(&self) -> FileDescriptorSet<'_> {
|
||||
FileDescriptorSet::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedFileDescriptorSet {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedFileDescriptorSet { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct FileDescriptorProto<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
name_offset: Option<usize>,
|
||||
@@ -542,6 +576,27 @@ impl<'b> FileDescriptorProtoBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedFileDescriptorProto {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedFileDescriptorProto {
|
||||
type Reader<'a> = FileDescriptorProto<'a>;
|
||||
fn reader(&self) -> FileDescriptorProto<'_> {
|
||||
FileDescriptorProto::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedFileDescriptorProto {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedFileDescriptorProto { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct DescriptorProto<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
name_offset: Option<usize>,
|
||||
@@ -868,6 +923,27 @@ impl<'b> DescriptorProtoBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedDescriptorProto {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedDescriptorProto {
|
||||
type Reader<'a> = DescriptorProto<'a>;
|
||||
fn reader(&self) -> DescriptorProto<'_> {
|
||||
DescriptorProto::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedDescriptorProto {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedDescriptorProto { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod descriptor_proto {
|
||||
pub struct ExtensionRange<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
@@ -995,6 +1071,27 @@ impl<'b> ExtensionRangeBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedExtensionRange {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedExtensionRange {
|
||||
type Reader<'a> = ExtensionRange<'a>;
|
||||
fn reader(&self) -> ExtensionRange<'_> {
|
||||
ExtensionRange::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedExtensionRange {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedExtensionRange { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct ReservedRange<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
start_offset: Option<usize>,
|
||||
@@ -1096,6 +1193,27 @@ impl<'b> ReservedRangeBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedReservedRange {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedReservedRange {
|
||||
type Reader<'a> = ReservedRange<'a>;
|
||||
fn reader(&self) -> ReservedRange<'_> {
|
||||
ReservedRange::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedReservedRange {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedReservedRange { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
pub struct ExtensionRangeOptions<'a> {
|
||||
@@ -1249,6 +1367,27 @@ impl<'b> ExtensionRangeOptionsBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedExtensionRangeOptions {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedExtensionRangeOptions {
|
||||
type Reader<'a> = ExtensionRangeOptions<'a>;
|
||||
fn reader(&self) -> ExtensionRangeOptions<'_> {
|
||||
ExtensionRangeOptions::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedExtensionRangeOptions {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedExtensionRangeOptions { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod extension_range_options {
|
||||
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
||||
#[repr(i32)]
|
||||
@@ -1443,6 +1582,27 @@ impl<'b> DeclarationBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedDeclaration {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedDeclaration {
|
||||
type Reader<'a> = Declaration<'a>;
|
||||
fn reader(&self) -> Declaration<'_> {
|
||||
Declaration::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedDeclaration {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedDeclaration { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
pub struct FieldDescriptorProto<'a> {
|
||||
@@ -1771,6 +1931,27 @@ impl<'b> FieldDescriptorProtoBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedFieldDescriptorProto {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedFieldDescriptorProto {
|
||||
type Reader<'a> = FieldDescriptorProto<'a>;
|
||||
fn reader(&self) -> FieldDescriptorProto<'_> {
|
||||
FieldDescriptorProto::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedFieldDescriptorProto {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedFieldDescriptorProto { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod field_descriptor_proto {
|
||||
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
||||
#[repr(i32)]
|
||||
@@ -1945,6 +2126,27 @@ impl<'b> OneofDescriptorProtoBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedOneofDescriptorProto {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedOneofDescriptorProto {
|
||||
type Reader<'a> = OneofDescriptorProto<'a>;
|
||||
fn reader(&self) -> OneofDescriptorProto<'_> {
|
||||
OneofDescriptorProto::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedOneofDescriptorProto {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedOneofDescriptorProto { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct EnumDescriptorProto<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
name_offset: Option<usize>,
|
||||
@@ -2146,6 +2348,27 @@ impl<'b> EnumDescriptorProtoBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedEnumDescriptorProto {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedEnumDescriptorProto {
|
||||
type Reader<'a> = EnumDescriptorProto<'a>;
|
||||
fn reader(&self) -> EnumDescriptorProto<'_> {
|
||||
EnumDescriptorProto::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedEnumDescriptorProto {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedEnumDescriptorProto { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod enum_descriptor_proto {
|
||||
pub struct EnumReservedRange<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
@@ -2248,6 +2471,27 @@ impl<'b> EnumReservedRangeBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedEnumReservedRange {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedEnumReservedRange {
|
||||
type Reader<'a> = EnumReservedRange<'a>;
|
||||
fn reader(&self) -> EnumReservedRange<'_> {
|
||||
EnumReservedRange::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedEnumReservedRange {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedEnumReservedRange { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
pub struct EnumValueDescriptorProto<'a> {
|
||||
@@ -2376,6 +2620,27 @@ impl<'b> EnumValueDescriptorProtoBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedEnumValueDescriptorProto {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedEnumValueDescriptorProto {
|
||||
type Reader<'a> = EnumValueDescriptorProto<'a>;
|
||||
fn reader(&self) -> EnumValueDescriptorProto<'_> {
|
||||
EnumValueDescriptorProto::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedEnumValueDescriptorProto {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedEnumValueDescriptorProto { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct ServiceDescriptorProto<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
name_offset: Option<usize>,
|
||||
@@ -2502,6 +2767,27 @@ impl<'b> ServiceDescriptorProtoBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedServiceDescriptorProto {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedServiceDescriptorProto {
|
||||
type Reader<'a> = ServiceDescriptorProto<'a>;
|
||||
fn reader(&self) -> ServiceDescriptorProto<'_> {
|
||||
ServiceDescriptorProto::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedServiceDescriptorProto {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedServiceDescriptorProto { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct MethodDescriptorProto<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
name_offset: Option<usize>,
|
||||
@@ -2703,6 +2989,27 @@ impl<'b> MethodDescriptorProtoBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedMethodDescriptorProto {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedMethodDescriptorProto {
|
||||
type Reader<'a> = MethodDescriptorProto<'a>;
|
||||
fn reader(&self) -> MethodDescriptorProto<'_> {
|
||||
MethodDescriptorProto::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedMethodDescriptorProto {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedMethodDescriptorProto { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct FileOptions<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
java_package_offset: Option<usize>,
|
||||
@@ -3279,6 +3586,27 @@ impl<'b> FileOptionsBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedFileOptions {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedFileOptions {
|
||||
type Reader<'a> = FileOptions<'a>;
|
||||
fn reader(&self) -> FileOptions<'_> {
|
||||
FileOptions::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedFileOptions {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedFileOptions { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod file_options {
|
||||
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
||||
#[repr(i32)]
|
||||
@@ -3528,6 +3856,27 @@ impl<'b> MessageOptionsBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedMessageOptions {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedMessageOptions {
|
||||
type Reader<'a> = MessageOptions<'a>;
|
||||
fn reader(&self) -> MessageOptions<'_> {
|
||||
MessageOptions::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedMessageOptions {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedMessageOptions { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct FieldOptions<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
ctype_offset: Option<usize>,
|
||||
@@ -3929,6 +4278,27 @@ impl<'b> FieldOptionsBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedFieldOptions {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedFieldOptions {
|
||||
type Reader<'a> = FieldOptions<'a>;
|
||||
fn reader(&self) -> FieldOptions<'_> {
|
||||
FieldOptions::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedFieldOptions {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedFieldOptions { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod field_options {
|
||||
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
||||
#[repr(i32)]
|
||||
@@ -4121,6 +4491,27 @@ impl<'b> EditionDefaultBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedEditionDefault {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedEditionDefault {
|
||||
type Reader<'a> = EditionDefault<'a>;
|
||||
fn reader(&self) -> EditionDefault<'_> {
|
||||
EditionDefault::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedEditionDefault {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedEditionDefault { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct FeatureSupport<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
edition_introduced_offset: Option<usize>,
|
||||
@@ -4297,6 +4688,27 @@ impl<'b> FeatureSupportBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedFeatureSupport {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedFeatureSupport {
|
||||
type Reader<'a> = FeatureSupport<'a>;
|
||||
fn reader(&self) -> FeatureSupport<'_> {
|
||||
FeatureSupport::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedFeatureSupport {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedFeatureSupport { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
pub struct OneofOptions<'a> {
|
||||
@@ -4400,6 +4812,27 @@ impl<'b> OneofOptionsBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedOneofOptions {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedOneofOptions {
|
||||
type Reader<'a> = OneofOptions<'a>;
|
||||
fn reader(&self) -> OneofOptions<'_> {
|
||||
OneofOptions::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedOneofOptions {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedOneofOptions { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct EnumOptions<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
allow_alias_offset: Option<usize>,
|
||||
@@ -4576,6 +5009,27 @@ impl<'b> EnumOptionsBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedEnumOptions {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedEnumOptions {
|
||||
type Reader<'a> = EnumOptions<'a>;
|
||||
fn reader(&self) -> EnumOptions<'_> {
|
||||
EnumOptions::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedEnumOptions {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedEnumOptions { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct EnumValueOptions<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
deprecated_offset: Option<usize>,
|
||||
@@ -4752,6 +5206,27 @@ impl<'b> EnumValueOptionsBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedEnumValueOptions {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedEnumValueOptions {
|
||||
type Reader<'a> = EnumValueOptions<'a>;
|
||||
fn reader(&self) -> EnumValueOptions<'_> {
|
||||
EnumValueOptions::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedEnumValueOptions {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedEnumValueOptions { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct ServiceOptions<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
features_offset: Option<usize>,
|
||||
@@ -4878,6 +5353,27 @@ impl<'b> ServiceOptionsBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedServiceOptions {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedServiceOptions {
|
||||
type Reader<'a> = ServiceOptions<'a>;
|
||||
fn reader(&self) -> ServiceOptions<'_> {
|
||||
ServiceOptions::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedServiceOptions {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedServiceOptions { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub struct MethodOptions<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
deprecated_offset: Option<usize>,
|
||||
@@ -5029,6 +5525,27 @@ impl<'b> MethodOptionsBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedMethodOptions {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedMethodOptions {
|
||||
type Reader<'a> = MethodOptions<'a>;
|
||||
fn reader(&self) -> MethodOptions<'_> {
|
||||
MethodOptions::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedMethodOptions {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedMethodOptions { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod method_options {
|
||||
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
||||
#[repr(i32)]
|
||||
@@ -5277,6 +5794,27 @@ impl<'b> UninterpretedOptionBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedUninterpretedOption {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedUninterpretedOption {
|
||||
type Reader<'a> = UninterpretedOption<'a>;
|
||||
fn reader(&self) -> UninterpretedOption<'_> {
|
||||
UninterpretedOption::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedUninterpretedOption {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedUninterpretedOption { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod uninterpreted_option {
|
||||
pub struct NamePart<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
@@ -5379,6 +5917,27 @@ impl<'b> NamePartBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedNamePart {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedNamePart {
|
||||
type Reader<'a> = NamePart<'a>;
|
||||
fn reader(&self) -> NamePart<'_> {
|
||||
NamePart::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedNamePart {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedNamePart { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
pub struct FeatureSet<'a> {
|
||||
@@ -5657,6 +6216,27 @@ impl<'b> FeatureSetBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedFeatureSet {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedFeatureSet {
|
||||
type Reader<'a> = FeatureSet<'a>;
|
||||
fn reader(&self) -> FeatureSet<'_> {
|
||||
FeatureSet::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedFeatureSet {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedFeatureSet { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod feature_set {
|
||||
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
||||
#[repr(i32)]
|
||||
@@ -5846,6 +6426,27 @@ impl<'b> VisibilityFeatureBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedVisibilityFeature {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedVisibilityFeature {
|
||||
type Reader<'a> = VisibilityFeature<'a>;
|
||||
fn reader(&self) -> VisibilityFeature<'_> {
|
||||
VisibilityFeature::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedVisibilityFeature {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedVisibilityFeature { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod visibility_feature {
|
||||
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
||||
#[repr(i32)]
|
||||
@@ -5923,6 +6524,27 @@ impl<'b> ProtoLimitsFeatureBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedProtoLimitsFeature {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedProtoLimitsFeature {
|
||||
type Reader<'a> = ProtoLimitsFeature<'a>;
|
||||
fn reader(&self) -> ProtoLimitsFeature<'_> {
|
||||
ProtoLimitsFeature::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedProtoLimitsFeature {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedProtoLimitsFeature { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod proto_limits_feature {
|
||||
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
||||
#[repr(i32)]
|
||||
@@ -6073,6 +6695,27 @@ impl<'b> FeatureSetDefaultsBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedFeatureSetDefaults {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedFeatureSetDefaults {
|
||||
type Reader<'a> = FeatureSetDefaults<'a>;
|
||||
fn reader(&self) -> FeatureSetDefaults<'_> {
|
||||
FeatureSetDefaults::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedFeatureSetDefaults {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedFeatureSetDefaults { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod feature_set_defaults {
|
||||
pub struct FeatureSetEditionDefault<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
@@ -6200,6 +6843,27 @@ impl<'b> FeatureSetEditionDefaultBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedFeatureSetEditionDefault {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedFeatureSetEditionDefault {
|
||||
type Reader<'a> = FeatureSetEditionDefault<'a>;
|
||||
fn reader(&self) -> FeatureSetEditionDefault<'_> {
|
||||
FeatureSetEditionDefault::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedFeatureSetEditionDefault {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedFeatureSetEditionDefault { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
pub struct SourceCodeInfo<'a> {
|
||||
@@ -6278,6 +6942,27 @@ impl<'b> SourceCodeInfoBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedSourceCodeInfo {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedSourceCodeInfo {
|
||||
type Reader<'a> = SourceCodeInfo<'a>;
|
||||
fn reader(&self) -> SourceCodeInfo<'_> {
|
||||
SourceCodeInfo::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedSourceCodeInfo {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedSourceCodeInfo { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod source_code_info {
|
||||
pub struct Location<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
@@ -6455,6 +7140,27 @@ impl<'b> LocationBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedLocation {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedLocation {
|
||||
type Reader<'a> = Location<'a>;
|
||||
fn reader(&self) -> Location<'_> {
|
||||
Location::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedLocation {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedLocation { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
pub struct GeneratedCodeInfo<'a> {
|
||||
@@ -6533,6 +7239,27 @@ impl<'b> GeneratedCodeInfoBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedGeneratedCodeInfo {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedGeneratedCodeInfo {
|
||||
type Reader<'a> = GeneratedCodeInfo<'a>;
|
||||
fn reader(&self) -> GeneratedCodeInfo<'_> {
|
||||
GeneratedCodeInfo::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedGeneratedCodeInfo {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedGeneratedCodeInfo { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod generated_code_info {
|
||||
pub struct Annotation<'a> {
|
||||
accessor: roto_runtime::ProtoAccessor<'a>,
|
||||
@@ -6710,6 +7437,27 @@ impl<'b> AnnotationBuilder<'b> {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct OwnedAnnotation {
|
||||
pub data: bytes::Bytes,
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoOwned for OwnedAnnotation {
|
||||
type Reader<'a> = Annotation<'a>;
|
||||
fn reader(&self) -> Annotation<'_> {
|
||||
Annotation::new(&self.data).expect("failed to create reader")
|
||||
}
|
||||
}
|
||||
|
||||
impl roto_runtime::RotoMessage for OwnedAnnotation {
|
||||
fn decode(buf: bytes::Bytes) -> roto_runtime::Result<Self> {
|
||||
Ok(OwnedAnnotation { data: buf })
|
||||
}
|
||||
|
||||
fn bytes(&self) -> bytes::Bytes {
|
||||
self.data.clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub mod annotation {
|
||||
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
||||
#[repr(i32)]
|
||||
|
||||
Reference in New Issue
Block a user