pub struct DetectorBundlePool { /* private fields */ }Expand description
Append-only, clone-cheap bundle storage.
Implementations§
Source§impl DetectorBundlePool
impl DetectorBundlePool
Sourcepub fn insert(&mut self, bundle: DetectorBundle) -> DetectorBundleId
pub fn insert(&mut self, bundle: DetectorBundle) -> DetectorBundleId
Insert an owned bundle and return its append-only id.
§Panics
Panics before insertion if the next id exceeds u32.
Insert an immutable shared bundle, preserving its cached analysis.
§Panics
Panics before insertion if the next id exceeds u32.
Sourcepub fn get(&self, id: DetectorBundleId) -> Option<&DetectorBundle>
pub fn get(&self, id: DetectorBundleId) -> Option<&DetectorBundle>
Look up a bundle by id.
Sourcepub fn iter(&self) -> impl Iterator<Item = (DetectorBundleId, &DetectorBundle)>
pub fn iter(&self) -> impl Iterator<Item = (DetectorBundleId, &DetectorBundle)>
Iterate over bundles in id order.
Borrow shared handles in id order.
Trait Implementations§
Source§impl Clone for DetectorBundlePool
impl Clone for DetectorBundlePool
Source§fn clone(&self) -> DetectorBundlePool
fn clone(&self) -> DetectorBundlePool
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 DetectorBundlePool
impl Debug for DetectorBundlePool
Source§impl Default for DetectorBundlePool
impl Default for DetectorBundlePool
Source§fn default() -> DetectorBundlePool
fn default() -> DetectorBundlePool
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for DetectorBundlePool
impl<'de> Deserialize<'de> for DetectorBundlePool
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for DetectorBundlePool
impl RefUnwindSafe for DetectorBundlePool
impl Send for DetectorBundlePool
impl Sync for DetectorBundlePool
impl Unpin for DetectorBundlePool
impl UnsafeUnpin for DetectorBundlePool
impl UnwindSafe for DetectorBundlePool
Blanket Implementations§
§impl<T, BorrowedSelf> BitwiseMutViaBorrow<BorrowedSelf> for T
impl<T, BorrowedSelf> BitwiseMutViaBorrow<BorrowedSelf> for T
fn assign_index(&mut self, index: usize, to: bool)
fn negate_index(&mut self, index: usize)
fn clear_bits(&mut self)
fn assign_random(
&mut self,
bit_count: usize,
random_number_generator: &mut impl RngExt,
)where
BorrowedSelf: BitLength,
§impl<Bits, Other, BorrowedSelf, BorrowedOther> BitwisePairMutViaBorrow<Other, BorrowedSelf, BorrowedOther> for Bits
impl<Bits, Other, BorrowedSelf, BorrowedOther> BitwisePairMutViaBorrow<Other, BorrowedSelf, BorrowedOther> for Bits
fn assign(&mut self, other: &Other)
fn bitxor_assign(&mut self, other: &Other)
fn bitand_assign(&mut self, other: &Other)
fn bitor_assign(&mut self, other: &Other)
§impl<T, Other, BorrowedSelf, BorrowedOther> BitwisePairViaBorrow<Other, BorrowedSelf, BorrowedOther> for T
impl<T, Other, BorrowedSelf, BorrowedOther> BitwisePairViaBorrow<Other, BorrowedSelf, BorrowedOther> for T
§impl<T, BorrowedSelf> BitwiseViaBorrow<BorrowedSelf> for T
impl<T, BorrowedSelf> BitwiseViaBorrow<BorrowedSelf> for T
fn index(&self, index: usize) -> bool
fn weight(&self) -> usize
fn parity(&self) -> bool
fn is_zero(&self) -> bool
fn is_unit(&self, index: usize) -> bool
fn support<'a>(&'a self) -> impl SortedIteratorwhere
BorrowedSelf: 'a,
fn max_support(&self) -> Option<usize>
fn min_support(&self) -> Option<usize>
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