pub struct PodStakeStatus(/* private fields */);Expand description
Wrapper struct that can be Pod, containing a byte that should be a valid
StakeStatus underneath.
Implementations§
Source§impl PodStakeStatus
impl PodStakeStatus
Sourcepub fn remove_validator_stake(&mut self) -> Result<(), ProgramError>
pub fn remove_validator_stake(&mut self) -> Result<(), ProgramError>
Downgrade the status towards ready for removal by removing the validator stake
Sourcepub fn remove_transient_stake(&mut self) -> Result<(), ProgramError>
pub fn remove_transient_stake(&mut self) -> Result<(), ProgramError>
Downgrade the status towards ready for removal by removing the transient stake
Trait Implementations§
Source§impl BorshDeserialize for PodStakeStatus
impl BorshDeserialize for PodStakeStatus
fn deserialize_reader<__R: Read>(reader: &mut __R) -> Result<Self, Error>
Source§fn deserialize(buf: &mut &[u8]) -> Result<Self, Error>
fn deserialize(buf: &mut &[u8]) -> Result<Self, Error>
Deserializes this instance from a given slice of bytes.
Updates the buffer to point at the remaining bytes.
Source§fn try_from_slice(v: &[u8]) -> Result<Self, Error>
fn try_from_slice(v: &[u8]) -> Result<Self, Error>
Deserialize this instance from a slice of bytes.
fn try_from_reader<R>(reader: &mut R) -> Result<Self, Error>where
R: Read,
Source§impl BorshSchema for PodStakeStatus
impl BorshSchema for PodStakeStatus
Source§fn declaration() -> Declaration
fn declaration() -> Declaration
Get the name of the type without brackets.
Source§fn add_definitions_recursively(
definitions: &mut BTreeMap<Declaration, Definition>,
)
fn add_definitions_recursively( definitions: &mut BTreeMap<Declaration, Definition>, )
Recursively, using DFS, add type definitions required for this type.
Type definition partially explains how to serialize/deserialize a type.
Source§impl BorshSerialize for PodStakeStatus
impl BorshSerialize for PodStakeStatus
Source§impl Clone for PodStakeStatus
impl Clone for PodStakeStatus
Source§fn clone(&self) -> PodStakeStatus
fn clone(&self) -> PodStakeStatus
Returns a duplicate of the value. Read more
1.0.0 · 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 PodStakeStatus
impl Debug for PodStakeStatus
Source§impl Default for PodStakeStatus
impl Default for PodStakeStatus
Source§fn default() -> PodStakeStatus
fn default() -> PodStakeStatus
Returns the “default value” for a type. Read more
Source§impl From<StakeStatus> for PodStakeStatus
impl From<StakeStatus> for PodStakeStatus
Source§fn from(status: StakeStatus) -> Self
fn from(status: StakeStatus) -> Self
Converts to this type from the input type.
Source§impl PartialEq for PodStakeStatus
impl PartialEq for PodStakeStatus
Source§impl TryFrom<PodStakeStatus> for StakeStatus
impl TryFrom<PodStakeStatus> for StakeStatus
Source§type Error = ProgramError
type Error = ProgramError
The type returned in the event of a conversion error.
impl Copy for PodStakeStatus
impl Pod for PodStakeStatus
impl StructuralPartialEq for PodStakeStatus
Auto Trait Implementations§
impl Freeze for PodStakeStatus
impl RefUnwindSafe for PodStakeStatus
impl Send for PodStakeStatus
impl Sync for PodStakeStatus
impl Unpin for PodStakeStatus
impl UnsafeUnpin for PodStakeStatus
impl UnwindSafe for PodStakeStatus
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
Source§impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
Source§type Bits = T
type Bits = T
Self must have the same layout as the specified Bits except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern.Source§fn is_valid_bit_pattern(_bits: &T) -> bool
fn is_valid_bit_pattern(_bits: &T) -> bool
If this function returns true, then it must be valid to reinterpret
bits
as &Self.Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more