pub struct GeneratedAnnotation { /* private fields */ }Expand description
One generated service annotation with an explicit string value.
Implementations§
Source§impl GeneratedAnnotation
impl GeneratedAnnotation
Sourcepub fn new(
name: impl Into<String>,
value: GeneratedString,
) -> Result<Self, GenerationError>
pub fn new( name: impl Into<String>, value: GeneratedString, ) -> Result<Self, GenerationError>
Creates one resolved mapping-form annotation.
§Errors
Rejects empty/deferred/multiline/NUL-bearing names and deferred/multiline/NUL-bearing values. Empty explicit values remain representable.
Sourcepub const fn value(&self) -> &GeneratedString
pub const fn value(&self) -> &GeneratedString
Returns the explicit annotation value through its sensitivity boundary.
Trait Implementations§
Source§impl Clone for GeneratedAnnotation
impl Clone for GeneratedAnnotation
Source§fn clone(&self) -> GeneratedAnnotation
fn clone(&self) -> GeneratedAnnotation
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for GeneratedAnnotation
impl Debug for GeneratedAnnotation
impl Eq for GeneratedAnnotation
Source§impl PartialEq for GeneratedAnnotation
impl PartialEq for GeneratedAnnotation
impl StructuralPartialEq for GeneratedAnnotation
Auto Trait Implementations§
impl Freeze for GeneratedAnnotation
impl RefUnwindSafe for GeneratedAnnotation
impl Send for GeneratedAnnotation
impl Sync for GeneratedAnnotation
impl Unpin for GeneratedAnnotation
impl UnsafeUnpin for GeneratedAnnotation
impl UnwindSafe for GeneratedAnnotation
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