[−][src]Struct pagecache::PageTable
A simple lock-free radix tree.
Methods
impl<T> PageTable<T> where
T: 'static + Send + Sync,
[src]
T: 'static + Send + Sync,
pub fn swap<'g>(
&self,
pid: u64,
new: Shared<'g, T>,
guard: &'g Guard
) -> Shared<'g, T>
[src]
&self,
pid: u64,
new: Shared<'g, T>,
guard: &'g Guard
) -> Shared<'g, T>
Atomically swap the previous value in a tree with a new one.
pub fn cas<'g>(
&self,
pid: u64,
old: Shared<'g, T>,
new: Shared<'g, T>,
guard: &'g Guard
) -> Result<Shared<'g, T>, Shared<'g, T>>
[src]
&self,
pid: u64,
old: Shared<'g, T>,
new: Shared<'g, T>,
guard: &'g Guard
) -> Result<Shared<'g, T>, Shared<'g, T>>
Compare and swap an old value to a new one.
pub fn get<'g>(&self, pid: u64, guard: &'g Guard) -> Option<Shared<'g, T>>
[src]
Try to get a value from the tree.
pub fn del<'g>(&self, pid: u64, guard: &'g Guard) -> Option<Shared<'g, T>>
[src]
Delete a value from the tree, returning the old value if it was set.
Trait Implementations
impl<T> Default for PageTable<T> where
T: 'static + Send + Sync,
[src]
T: 'static + Send + Sync,
impl<T> Drop for PageTable<T> where
T: 'static + Send + Sync,
[src]
T: 'static + Send + Sync,
Auto Trait Implementations
impl<T> Sync for PageTable<T>
impl<T> Unpin for PageTable<T>
impl<T> Send for PageTable<T>
impl<T> UnwindSafe for PageTable<T> where
T: RefUnwindSafe,
T: RefUnwindSafe,
impl<T> RefUnwindSafe for PageTable<T> where
T: RefUnwindSafe,
T: RefUnwindSafe,
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> 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, U> TryInto<U> 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> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,