pub struct PolicyTable { /* private fields */ }Expand description
Dense policy table indexed by PolicyId.
Implementations§
Source§impl PolicyTable
impl PolicyTable
Sourcepub fn set(&mut self, policy: CompiledSyncPolicy)
pub fn set(&mut self, policy: CompiledSyncPolicy)
Inserts or replaces a compiled policy.
Sourcepub fn get(&self, id: PolicyId) -> Option<&CompiledSyncPolicy>
pub fn get(&self, id: PolicyId) -> Option<&CompiledSyncPolicy>
Gets a policy by id.
Sourcepub fn slot_count(&self) -> usize
pub fn slot_count(&self) -> usize
Number of slots in the dense policy table.
Trait Implementations§
Source§impl Clone for PolicyTable
impl Clone for PolicyTable
Source§fn clone(&self) -> PolicyTable
fn clone(&self) -> PolicyTable
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 PolicyTable
impl Debug for PolicyTable
Source§impl Default for PolicyTable
impl Default for PolicyTable
Source§fn default() -> PolicyTable
fn default() -> PolicyTable
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for PolicyTable
impl RefUnwindSafe for PolicyTable
impl Send for PolicyTable
impl Sync for PolicyTable
impl Unpin for PolicyTable
impl UnsafeUnpin for PolicyTable
impl UnwindSafe for PolicyTable
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