Record Class ValidatorStakeInfo
java.lang.Object
java.lang.Record
software.sava.solana.programs.stake.ValidatorStakeInfo
- All Implemented Interfaces:
software.sava.core.borsh.Borsh,software.sava.core.serial.Serializable
public record ValidatorStakeInfo(long activeStakeLamports, long transientStakeLamports, long lastUpdateEpoch, long transientSeedSuffix, int unused, int validatorSeedSuffix, StakeStatus podStakeStatus, software.sava.core.accounts.PublicKey voteAccountAddress)
extends Record
implements software.sava.core.borsh.Borsh
-
Nested Class Summary
Nested classes/interfaces inherited from interface software.sava.core.borsh.Borsh
software.sava.core.borsh.Borsh.Enum, software.sava.core.borsh.Borsh.Factory<T> -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionValidatorStakeInfo(long activeStakeLamports, long transientStakeLamports, long lastUpdateEpoch, long transientSeedSuffix, int unused, int validatorSeedSuffix, StakeStatus podStakeStatus, software.sava.core.accounts.PublicKey voteAccountAddress) Creates an instance of aValidatorStakeInforecord class. -
Method Summary
Modifier and TypeMethodDescriptionlongReturns the value of theactiveStakeLamportsrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intl()longReturns the value of thelastUpdateEpochrecord component.Returns the value of thepodStakeStatusrecord component.static ValidatorStakeInforead(byte[] data, int offset) final StringtoString()Returns a string representation of this record class.longReturns the value of thetransientSeedSuffixrecord component.longReturns the value of thetransientStakeLamportsrecord component.intunused()Returns the value of theunusedrecord component.intReturns the value of thevalidatorSeedSuffixrecord component.software.sava.core.accounts.PublicKeyReturns the value of thevoteAccountAddressrecord component.intwrite(byte[] data, int offset) Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface software.sava.core.borsh.Borsh
writeOptionalMethods inherited from interface software.sava.core.serial.Serializable
reusable, write, write
-
Field Details
-
BYTES
public static int BYTES
-
-
Constructor Details
-
ValidatorStakeInfo
public ValidatorStakeInfo(long activeStakeLamports, long transientStakeLamports, long lastUpdateEpoch, long transientSeedSuffix, int unused, int validatorSeedSuffix, StakeStatus podStakeStatus, software.sava.core.accounts.PublicKey voteAccountAddress) Creates an instance of aValidatorStakeInforecord class.- Parameters:
activeStakeLamports- the value for theactiveStakeLamportsrecord componenttransientStakeLamports- the value for thetransientStakeLamportsrecord componentlastUpdateEpoch- the value for thelastUpdateEpochrecord componenttransientSeedSuffix- the value for thetransientSeedSuffixrecord componentunused- the value for theunusedrecord componentvalidatorSeedSuffix- the value for thevalidatorSeedSuffixrecord componentpodStakeStatus- the value for thepodStakeStatusrecord componentvoteAccountAddress- the value for thevoteAccountAddressrecord component
-
-
Method Details
-
read
-
write
public int write(byte[] data, int offset) - Specified by:
writein interfacesoftware.sava.core.serial.Serializable
-
l
public int l()- Specified by:
lin interfacesoftware.sava.core.serial.Serializable
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
activeStakeLamports
public long activeStakeLamports()Returns the value of theactiveStakeLamportsrecord component.- Returns:
- the value of the
activeStakeLamportsrecord component
-
transientStakeLamports
public long transientStakeLamports()Returns the value of thetransientStakeLamportsrecord component.- Returns:
- the value of the
transientStakeLamportsrecord component
-
lastUpdateEpoch
public long lastUpdateEpoch()Returns the value of thelastUpdateEpochrecord component.- Returns:
- the value of the
lastUpdateEpochrecord component
-
transientSeedSuffix
public long transientSeedSuffix()Returns the value of thetransientSeedSuffixrecord component.- Returns:
- the value of the
transientSeedSuffixrecord component
-
unused
public int unused()Returns the value of theunusedrecord component.- Returns:
- the value of the
unusedrecord component
-
validatorSeedSuffix
public int validatorSeedSuffix()Returns the value of thevalidatorSeedSuffixrecord component.- Returns:
- the value of the
validatorSeedSuffixrecord component
-
podStakeStatus
Returns the value of thepodStakeStatusrecord component.- Returns:
- the value of the
podStakeStatusrecord component
-
voteAccountAddress
public software.sava.core.accounts.PublicKey voteAccountAddress()Returns the value of thevoteAccountAddressrecord component.- Returns:
- the value of the
voteAccountAddressrecord component
-