pub trait OptStrings: MaybeStrings + PropertiesBackend {
// Required methods
fn message(&self) -> PropertiesResult<'_, &[u8], Self>;
fn message_offset(
&self,
node: NodeId,
) -> PropertiesResult<'_, Option<u64>, Self>;
fn tag_name(&self) -> PropertiesResult<'_, &[u8], Self>;
fn tag_name_offset(
&self,
node: NodeId,
) -> PropertiesResult<'_, Option<u64>, Self>;
}
Expand description
Trait implemented by all implementors of MaybeStrings
but NoStrings
Required Methods§
Sourcefn message(&self) -> PropertiesResult<'_, &[u8], Self>
fn message(&self) -> PropertiesResult<'_, &[u8], Self>
Returns an array with all messages, separated by b'\n'
Sourcefn message_offset(
&self,
node: NodeId,
) -> PropertiesResult<'_, Option<u64>, Self>
fn message_offset( &self, node: NodeId, ) -> PropertiesResult<'_, Option<u64>, Self>
Returns the position of the first character of node
’s message in Self::message
,
or None
if it is out of bound, or Some(u64::MAX)
if the node has no message
Sourcefn tag_name(&self) -> PropertiesResult<'_, &[u8], Self>
fn tag_name(&self) -> PropertiesResult<'_, &[u8], Self>
Returns an array with all messages, separated by b'\n'
Sourcefn tag_name_offset(
&self,
node: NodeId,
) -> PropertiesResult<'_, Option<u64>, Self>
fn tag_name_offset( &self, node: NodeId, ) -> PropertiesResult<'_, Option<u64>, Self>
Returns the position of the first character of node
’s tag_name in Self::tag_name
,
or None
if it is out of bound, or Some(u64::MAX)
if the node has no tag_name
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.