pub struct ProtocolExtensionBuilder<NAME = LString<'static>, ANNOTATIONS = Array<'static, i16, Annotation<'static>>>where
NAME: EncoderFor<LString<'static>>,
ANNOTATIONS: EncoderFor<Array<'static, i16, Annotation<'static>>>,{
pub name: NAME,
pub annotations: ANNOTATIONS,
}
Fields§
§name: NAME
Extension name.
annotations: ANNOTATIONS
A set of extension annotations.
Trait Implementations§
Source§impl<NAME, ANNOTATIONS> BuilderFor for ProtocolExtensionBuilder<NAME, ANNOTATIONS>where
NAME: EncoderFor<LString<'static>>,
ANNOTATIONS: EncoderFor<Array<'static, i16, Annotation<'static>>>,
impl<NAME, ANNOTATIONS> BuilderFor for ProtocolExtensionBuilder<NAME, ANNOTATIONS>where
NAME: EncoderFor<LString<'static>>,
ANNOTATIONS: EncoderFor<Array<'static, i16, Annotation<'static>>>,
type Message = ProtocolExtension<'static>
Source§impl<NAME, ANNOTATIONS> Debug for ProtocolExtensionBuilder<NAME, ANNOTATIONS>where
NAME: EncoderFor<LString<'static>> + Debug,
ANNOTATIONS: EncoderFor<Array<'static, i16, Annotation<'static>>> + Debug,
impl<NAME, ANNOTATIONS> Debug for ProtocolExtensionBuilder<NAME, ANNOTATIONS>where
NAME: EncoderFor<LString<'static>> + Debug,
ANNOTATIONS: EncoderFor<Array<'static, i16, Annotation<'static>>> + Debug,
Source§impl<NAME, ANNOTATIONS> Default for ProtocolExtensionBuilder<NAME, ANNOTATIONS>where
NAME: EncoderFor<LString<'static>> + Default,
ANNOTATIONS: EncoderFor<Array<'static, i16, Annotation<'static>>> + Default,
impl<NAME, ANNOTATIONS> Default for ProtocolExtensionBuilder<NAME, ANNOTATIONS>where
NAME: EncoderFor<LString<'static>> + Default,
ANNOTATIONS: EncoderFor<Array<'static, i16, Annotation<'static>>> + Default,
Source§fn default() -> ProtocolExtensionBuilder<NAME, ANNOTATIONS>
fn default() -> ProtocolExtensionBuilder<NAME, ANNOTATIONS>
Returns the “default value” for a type. Read more
Source§impl<NAME, ANNOTATIONS> EncoderFor<ProtocolExtension<'static>> for &ProtocolExtensionBuilder<NAME, ANNOTATIONS>where
NAME: EncoderFor<LString<'static>>,
ANNOTATIONS: EncoderFor<Array<'static, i16, Annotation<'static>>>,
impl<NAME, ANNOTATIONS> EncoderFor<ProtocolExtension<'static>> for &ProtocolExtensionBuilder<NAME, ANNOTATIONS>where
NAME: EncoderFor<LString<'static>>,
ANNOTATIONS: EncoderFor<Array<'static, i16, Annotation<'static>>>,
fn encode_for(&self, buf: &mut BufWriter<'_>)
Source§impl<NAME, ANNOTATIONS> EncoderFor<ProtocolExtension<'static>> for ProtocolExtensionBuilder<NAME, ANNOTATIONS>where
NAME: EncoderFor<LString<'static>>,
ANNOTATIONS: EncoderFor<Array<'static, i16, Annotation<'static>>>,
impl<NAME, ANNOTATIONS> EncoderFor<ProtocolExtension<'static>> for ProtocolExtensionBuilder<NAME, ANNOTATIONS>where
NAME: EncoderFor<LString<'static>>,
ANNOTATIONS: EncoderFor<Array<'static, i16, Annotation<'static>>>,
fn encode_for(&self, buf: &mut BufWriter<'_>)
Auto Trait Implementations§
impl<NAME, ANNOTATIONS> Freeze for ProtocolExtensionBuilder<NAME, ANNOTATIONS>
impl<NAME, ANNOTATIONS> RefUnwindSafe for ProtocolExtensionBuilder<NAME, ANNOTATIONS>where
NAME: RefUnwindSafe,
ANNOTATIONS: RefUnwindSafe,
impl<NAME, ANNOTATIONS> Send for ProtocolExtensionBuilder<NAME, ANNOTATIONS>
impl<NAME, ANNOTATIONS> Sync for ProtocolExtensionBuilder<NAME, ANNOTATIONS>
impl<NAME, ANNOTATIONS> Unpin for ProtocolExtensionBuilder<NAME, ANNOTATIONS>
impl<NAME, ANNOTATIONS> UnwindSafe for ProtocolExtensionBuilder<NAME, ANNOTATIONS>where
NAME: UnwindSafe,
ANNOTATIONS: UnwindSafe,
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> EncoderForExt for Twhere
T: ?Sized,
impl<T> EncoderForExt for Twhere
T: ?Sized,
Source§fn to_vec<F>(&self) -> Vec<u8> ⓘwhere
F: 'static,
Self: EncoderFor<F>,
fn to_vec<F>(&self) -> Vec<u8> ⓘwhere
F: 'static,
Self: EncoderFor<F>,
Convert this builder into a vector of bytes. This is generally
not the most efficient way to perform serialization.
Source§fn encode_buffer<F>(&self, buf: &mut [u8]) -> Result<usize, usize>where
F: 'static,
Self: EncoderFor<F>,
fn encode_buffer<F>(&self, buf: &mut [u8]) -> Result<usize, usize>where
F: 'static,
Self: EncoderFor<F>,
Encode this builder into a given buffer. If the buffer is
too small, the function will return the number of bytes
required to encode the builder.
Source§fn encode_buffer_uninit<'a, F>(
&self,
buf: &'a mut [MaybeUninit<u8>],
) -> Result<&'a mut [u8], usize>where
F: 'static,
Self: EncoderFor<F>,
fn encode_buffer_uninit<'a, F>(
&self,
buf: &'a mut [MaybeUninit<u8>],
) -> Result<&'a mut [u8], usize>where
F: 'static,
Self: EncoderFor<F>,
Encode this builder into a given buffer. If the buffer is
too small, the function will return the number of bytes
required to encode the builder.