pub struct GenerateTraitService<'a, S> {
pub service: &'a S,
pub emit_package: bool,
pub proto_path: &'a str,
pub compile_well_known_types: bool,
pub service_trait: Ident,
pub disable_comments: &'a HashSet<String>,
pub use_arc_self: bool,
pub generate_default_stubs: bool,
}Available on crate feature
prost only.Fields§
§service: &'a S§emit_package: bool§proto_path: &'a str§compile_well_known_types: bool§service_trait: Ident§disable_comments: &'a HashSet<String>§use_arc_self: bool§generate_default_stubs: boolImplementations§
Source§impl<S: Service> GenerateTraitService<'_, S>
impl<S: Service> GenerateTraitService<'_, S>
pub fn generate_methods(&self) -> TokenStream
Trait Implementations§
Source§impl<S: Service> ToTokens for GenerateTraitService<'_, S>
impl<S: Service> ToTokens for GenerateTraitService<'_, S>
Source§fn to_tokens(&self, tokens: &mut TokenStream)
fn to_tokens(&self, tokens: &mut TokenStream)
Source§fn to_token_stream(&self) -> TokenStream
fn to_token_stream(&self) -> TokenStream
Source§fn into_token_stream(self) -> TokenStreamwhere
Self: Sized,
fn into_token_stream(self) -> TokenStreamwhere
Self: Sized,
Auto Trait Implementations§
impl<'a, S> Freeze for GenerateTraitService<'a, S>
impl<'a, S> RefUnwindSafe for GenerateTraitService<'a, S>where
S: RefUnwindSafe,
impl<'a, S> !Send for GenerateTraitService<'a, S>
impl<'a, S> !Sync for GenerateTraitService<'a, S>
impl<'a, S> Unpin for GenerateTraitService<'a, S>
impl<'a, S> UnwindSafe for GenerateTraitService<'a, S>where
S: RefUnwindSafe,
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Spanned for Twhere
T: Spanned + ?Sized,
impl<T> Spanned for Twhere
T: Spanned + ?Sized,
Source§fn span(&self) -> Span
fn span(&self) -> Span
Returns a
Span covering the complete contents of this syntax tree
node, or Span::call_site() if this node is empty.