pub struct ResolvedVariant<'a> {
pub style: RegistrationVariantStyle,
pub handler_shape: HandlerShape,
pub method_prefix: Option<&'a str>,
}Expand description
Resolved surface attributes for one registration variant in the context of a specific backend.
Produced by RegistrationVariant::resolved_for. Backends read these three fields
instead of accessing variant.style, base_reg.handler_shape, and manually
constructing the method name — the resolver applies per-language overrides consistently.
Fields§
§style: RegistrationVariantStyleThe emission style to use for this backend.
This is the per-language override’s style when an entry exists for the
requested language and it sets a style; otherwise the variant-global style.
handler_shape: HandlerShapeThe handler shape to use for this backend.
This is the per-language override’s handler_shape when an entry exists and it
sets a shape; otherwise the base registration’s handler_shape.
method_prefix: Option<&'a str>Optional language-specific prefix prepended to the verb method name.
Example: "Map" for C# produces MapGet, MapPost, MapPut. None means no
prefix is added and the variant’s own name is used verbatim.
Trait Implementations§
Source§impl<'a> Clone for ResolvedVariant<'a>
impl<'a> Clone for ResolvedVariant<'a>
Source§fn clone(&self) -> ResolvedVariant<'a>
fn clone(&self) -> ResolvedVariant<'a>
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl<'a> Debug for ResolvedVariant<'a>
impl<'a> Debug for ResolvedVariant<'a>
impl<'a> Eq for ResolvedVariant<'a>
Source§impl<'a> PartialEq for ResolvedVariant<'a>
impl<'a> PartialEq for ResolvedVariant<'a>
Source§fn eq(&self, other: &ResolvedVariant<'a>) -> bool
fn eq(&self, other: &ResolvedVariant<'a>) -> bool
self and other values to be equal, and is used by ==.impl<'a> StructuralPartialEq for ResolvedVariant<'a>
Auto Trait Implementations§
impl<'a> Freeze for ResolvedVariant<'a>
impl<'a> RefUnwindSafe for ResolvedVariant<'a>
impl<'a> Send for ResolvedVariant<'a>
impl<'a> Sync for ResolvedVariant<'a>
impl<'a> Unpin for ResolvedVariant<'a>
impl<'a> UnsafeUnpin for ResolvedVariant<'a>
impl<'a> UnwindSafe for ResolvedVariant<'a>
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
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>
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 more