struct PackedAncientStorage<'a> {
accounts: Vec<(Slot, &'a [&'a StoredAccountMeta<'a>])>,
bytes: u64,
}
Expand description
intended contents of a packed ancient storage
Fields§
§accounts: Vec<(Slot, &'a [&'a StoredAccountMeta<'a>])>
accounts to move into this storage, along with the slot the accounts are currently stored in
bytes: u64
total bytes required to hold ‘accounts’
Implementations§
source§impl<'a> PackedAncientStorage<'a>
impl<'a> PackedAncientStorage<'a>
sourcefn pack(
accounts_to_combine: impl Iterator<Item = &'a AliveAccounts<'a>>,
ideal_size: NonZeroU64
) -> Vec<PackedAncientStorage<'a>>
fn pack( accounts_to_combine: impl Iterator<Item = &'a AliveAccounts<'a>>, ideal_size: NonZeroU64 ) -> Vec<PackedAncientStorage<'a>>
return a minimal set of ’PackedAncientStorage’s to contain all ‘accounts_to_combine’ with the new storages having a size guided by ‘ideal_size’
Trait Implementations§
source§impl<'a> Default for PackedAncientStorage<'a>
impl<'a> Default for PackedAncientStorage<'a>
source§fn default() -> PackedAncientStorage<'a>
fn default() -> PackedAncientStorage<'a>
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl<'a> RefUnwindSafe for PackedAncientStorage<'a>
impl<'a> Send for PackedAncientStorage<'a>
impl<'a> Sync for PackedAncientStorage<'a>
impl<'a> Unpin for PackedAncientStorage<'a>
impl<'a> UnwindSafe for PackedAncientStorage<'a>
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