pub struct SourceSet { /* private fields */ }Expand description
A non-empty collection of emitters in canonical stable-id order.
Implementations§
Source§impl SourceSet
impl SourceSet
Sourcepub fn new(sources: Vec<Emitter>) -> Result<Self, InterferenceError>
pub fn new(sources: Vec<Emitter>) -> Result<Self, InterferenceError>
Validates source identities and sorts the sources by their id bytes.
Sourcepub fn is_empty(&self) -> bool
pub fn is_empty(&self) -> bool
Returns whether the set is empty.
This is always false for a successfully constructed SourceSet.
Sourcepub fn iter(&self) -> impl ExactSizeIterator<Item = &Emitter>
pub fn iter(&self) -> impl ExactSizeIterator<Item = &Emitter>
Iterates over sources in canonical stable-id order.
Trait Implementations§
Source§impl<'a> IntoIterator for &'a SourceSet
impl<'a> IntoIterator for &'a SourceSet
impl StructuralPartialEq for SourceSet
Auto Trait Implementations§
impl Freeze for SourceSet
impl RefUnwindSafe for SourceSet
impl Send for SourceSet
impl Sync for SourceSet
impl Unpin for SourceSet
impl UnsafeUnpin for SourceSet
impl UnwindSafe for SourceSet
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