Struct bitcoin_test::TestLockedPageAllocator
source · pub struct TestLockedPageAllocator { /* private fields */ }Expand description
| Mock LockedPageAllocator for testing |
Implementations§
Trait Implementations§
source§impl AllocateLocked for TestLockedPageAllocator
impl AllocateLocked for TestLockedPageAllocator
source§fn allocate_locked(&mut self, len: usize, locking_success: *mut bool)
fn allocate_locked(&mut self, len: usize, locking_success: *mut bool)
| Allocate and lock memory pages.
|
| If len is not a multiple of the system
| page size, it is rounded up.
|
| Returns nullptr in case of allocation
| failure.
|
| If locking the memory pages could not
| be accomplished it will still return
| the memory, however the lockingSuccess
| flag will be false. lockingSuccess
| is undefined if the allocation fails.
|
source§impl FreeLocked for TestLockedPageAllocator
impl FreeLocked for TestLockedPageAllocator
source§impl GetLimit for TestLockedPageAllocator
impl GetLimit for TestLockedPageAllocator
impl LockedPageAllocator for TestLockedPageAllocator
Auto Trait Implementations§
impl RefUnwindSafe for TestLockedPageAllocator
impl Send for TestLockedPageAllocator
impl Sync for TestLockedPageAllocator
impl Unpin for TestLockedPageAllocator
impl UnwindSafe for TestLockedPageAllocator
Blanket Implementations§
§impl<T, U> CastInto<U> for Twhere
U: CastFrom<T>,
impl<T, U> CastInto<U> for Twhere U: CastFrom<T>,
§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> StaticUpcast<T> for T
impl<T> StaticUpcast<T> for T
§unsafe fn static_upcast(ptr: Ptr<T>) -> Ptr<T>
unsafe fn static_upcast(ptr: Ptr<T>) -> Ptr<T>
Convert type of a const pointer. Read more