[−][src]Struct tokio_trace_core::field::FieldSet
Describes the fields present on a span.
Methods
impl FieldSet
[src]
pub fn field<Q: ?Sized>(&self, name: &Q) -> Option<Field> where
Q: Borrow<str>,
[src]
Q: Borrow<str>,
Returns the Field
named name
, or None
if no such field exists.
pub fn contains(&self, field: &Field) -> bool
[src]
Returns true
if self
contains the given field
.
Note: If field
shares a name with a field in this FieldSet
, but
was created by a FieldSet
with a different callsite, this FieldSet
does not contain it. This is so that if two separate span callsites
define a field named "foo", the Field
corresponding to "foo" for each
of those callsites are not equivalent.
ⓘImportant traits for Iterpub fn iter(&self) -> Iter
[src]
Returns an iterator over the Field
s in this FieldSet
.
pub fn len(&self) -> usize
[src]
Returns the number of fields in this FieldSet
.
Trait Implementations
impl<'a> IntoIterator for &'a FieldSet
[src]
type IntoIter = Iter
Which kind of iterator are we turning this into?
type Item = Field
The type of the elements being iterated over.
fn into_iter(self) -> Self::IntoIter
[src]
impl Debug for FieldSet
[src]
Auto Trait Implementations
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,