pub trait XmlComment<'de> {
type NamespaceContext<'a>: NamespaceContext + 'a
where Self: 'a;
// Required methods
fn into_bytes(self) -> Cow<'de, [u8]>;
fn as_bytes(&self) -> &[u8] ⓘ;
fn namespace_context(&self) -> Self::NamespaceContext<'_>;
}
Expand description
Trait for XML comments.
Required Associated Types§
Sourcetype NamespaceContext<'a>: NamespaceContext + 'a
where
Self: 'a
type NamespaceContext<'a>: NamespaceContext + 'a where Self: 'a
The type of the namespace context returned by [AttributeAccess::namespace_context
].
Required Methods§
Sourcefn into_bytes(self) -> Cow<'de, [u8]>
fn into_bytes(self) -> Cow<'de, [u8]>
Returns the owned byte representation of the comment.
Sourcefn namespace_context(&self) -> Self::NamespaceContext<'_>
fn namespace_context(&self) -> Self::NamespaceContext<'_>
Returns the namespace context of the comment.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.