pub trait VnodeBitmapExt {
// Required methods
fn iter_vnodes(&self) -> impl Iterator<Item = VirtualNode> + '_;
fn iter_vnodes_scalar(&self) -> impl Iterator<Item = i16> + '_;
fn vnode_ranges(
&self,
) -> impl Iterator<Item = RangeInclusive<VirtualNode>> + '_;
fn is_singleton(&self) -> bool;
fn singleton() -> &'static Self;
fn singleton_arc() -> &'static Arc<Self>;
}
Expand description
An extension trait for Bitmap
to support virtual node operations.
Required Methods§
sourcefn iter_vnodes(&self) -> impl Iterator<Item = VirtualNode> + '_
fn iter_vnodes(&self) -> impl Iterator<Item = VirtualNode> + '_
Enumerates the virtual nodes set to 1 in the bitmap.
sourcefn iter_vnodes_scalar(&self) -> impl Iterator<Item = i16> + '_
fn iter_vnodes_scalar(&self) -> impl Iterator<Item = i16> + '_
Enumerates the virtual nodes set to 1 in the bitmap.
sourcefn vnode_ranges(&self) -> impl Iterator<Item = RangeInclusive<VirtualNode>> + '_
fn vnode_ranges(&self) -> impl Iterator<Item = RangeInclusive<VirtualNode>> + '_
Returns an iterator which yields the position ranges of continuous virtual nodes set to 1 in the bitmap.
sourcefn is_singleton(&self) -> bool
fn is_singleton(&self) -> bool
Returns whether only the SINGLETON_VNODE
is set in the bitmap.
sourcefn singleton() -> &'static Self
fn singleton() -> &'static Self
Get the reference to a vnode bitmap for singleton actor or table, i.e., with length
1 and the only SINGLETON_VNODE
set to true.
sourcefn singleton_arc() -> &'static Arc<Self>
fn singleton_arc() -> &'static Arc<Self>
Get the reference to a vnode bitmap for singleton actor or table, i.e., with length
1 and the only SINGLETON_VNODE
set to true.
Object Safety§
This trait is not object safe.