pub struct ProtoOptions {
pub version: Option<ProtoVersion>,
pub reconcile: bool,
}Expand description
How a .proto document is read.
Mirrors the canonical ProtoOptions. The defaults auto-detect the
version from the file’s declaration and refuse an explicit version
that disagrees with it.
Fields§
§version: Option<ProtoVersion>An explicit protobuf version. None auto-detects from the file’s
syntax or edition declaration.
reconcile: boolWhen true (the default), a version that disagrees with the file’s declaration is an error; when false the declaration wins.
Trait Implementations§
Source§impl Clone for ProtoOptions
impl Clone for ProtoOptions
Source§impl Debug for ProtoOptions
impl Debug for ProtoOptions
Source§impl Default for ProtoOptions
impl Default for ProtoOptions
Source§impl<'de> Deserialize<'de> for ProtoOptionswhere
ProtoOptions: Default,
impl<'de> Deserialize<'de> for ProtoOptionswhere
ProtoOptions: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for ProtoOptions
Source§impl PartialEq for ProtoOptions
impl PartialEq for ProtoOptions
impl StructuralPartialEq for ProtoOptions
Auto Trait Implementations§
impl Forget for ProtoOptions
impl Freeze for ProtoOptions
impl RefUnwindSafe for ProtoOptions
impl Send for ProtoOptions
impl Sync for ProtoOptions
impl Unpin for ProtoOptions
impl UnsafeUnpin for ProtoOptions
impl UnwindSafe for ProtoOptions
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.