java.lang.Object
com.google.protobuf.AbstractMessageLite<StakingNodeInfo,StakingNodeInfo.Builder>
com.google.protobuf.GeneratedMessageLite<StakingNodeInfo,StakingNodeInfo.Builder>
com.hedera.hashgraph.sdk.proto.StakingNodeInfo
- All Implemented Interfaces:
com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,StakingNodeInfoOrBuilder
@Generated
public final class StakingNodeInfo
extends com.google.protobuf.GeneratedMessageLite<StakingNodeInfo,StakingNodeInfo.Builder>
implements StakingNodeInfoOrBuilder
* An Hedera Token Service staking info entity. Staking info is per node. Shard and Realm are implied based on the network address book entry for this node.Protobuf type
proto.StakingNodeInfo-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class* An Hedera Token Service staking info entity.Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageLite
com.google.protobuf.GeneratedMessageLite.DefaultInstanceBasedParser<T extends com.google.protobuf.GeneratedMessageLite<T,?>>, com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType, BuilderType>, BuilderType extends com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType, BuilderType>>, com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType, BuilderType>, BuilderType extends com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType, BuilderType>>, com.google.protobuf.GeneratedMessageLite.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType, BuilderType>, BuilderType extends com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType, BuilderType>>, com.google.protobuf.GeneratedMessageLite.GeneratedExtension<ContainingType extends com.google.protobuf.MessageLite, Type>, com.google.protobuf.GeneratedMessageLite.MethodToInvoke, com.google.protobuf.GeneratedMessageLite.SerializedForm Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessageLite.InternalOneOfEnum -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intFields inherited from class com.google.protobuf.GeneratedMessageLite
unknownFieldsFields inherited from class com.google.protobuf.AbstractMessageLite
memoizedHashCode -
Method Summary
Modifier and TypeMethodDescriptionprotected final ObjectdynamicMethod(com.google.protobuf.GeneratedMessageLite.MethodToInvoke method, Object arg0, Object arg1) static StakingNodeInfoboolean* A flag indicating that this node has been removed from this network.long* The maximum stake to this node that is considered to calculate its weight in the network consensus.long* The minimum stake, in tinybar, that is required for this node to have a non-zero weight in the network consensus.long* The entity number of this node.<br/> The shard and realm numbers are implied, based on the network address book entry for this node.long* The total staking rewards in tinybars that MAY be collected by all accounts staking to the current node after the end of this staking period.longgetRewardSumHistory(int index) * A running list of reward amounts for the last 365+1 staking periods (typically a year and a day).int* A running list of reward amounts for the last 365+1 staking periods (typically a year and a day).* A running list of reward amounts for the last 365+1 staking periods (typically a year and a day).longgetStake()* The total amount of HBAR staked to this node.long* The snapshot of stake_to_reward value at the beginning of the current staking period.long* The sum of balances of all accounts staked to this node, considering only accounts that decline to receive rewards.long* The sum of balances of all accounts staked to this node, considering only accounts that choose to receive rewards.long* The amount of staked HBAR from `stake_reward_start` that will have unclaimed rewards due to accounts changing their staking metadata in a way that disqualifies them for the current staking period.intDeprecated.proto.StakingNodeInfo.weight is deprecated.static StakingNodeInfo.Builderstatic StakingNodeInfo.BuildernewBuilder(StakingNodeInfo prototype) static StakingNodeInfoparseDelimitedFrom(InputStream input) static StakingNodeInfoparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static StakingNodeInfoparseFrom(byte[] data) static StakingNodeInfoparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static StakingNodeInfoparseFrom(com.google.protobuf.ByteString data) static StakingNodeInfoparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static StakingNodeInfoparseFrom(com.google.protobuf.CodedInputStream input) static StakingNodeInfoparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static StakingNodeInfoparseFrom(InputStream input) static StakingNodeInfoparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static StakingNodeInfoparseFrom(ByteBuffer data) static StakingNodeInfoparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser<StakingNodeInfo> parser()Methods inherited from class com.google.protobuf.GeneratedMessageLite
createBuilder, createBuilder, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, emptyProtobufList, equals, getDefaultInstanceForType, getParserForType, getSerializedSize, hashCode, isInitialized, makeImmutable, mergeLengthDelimitedField, mergeUnknownFields, mergeVarintField, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBuilderForType, newMessageInfo, newRepeatedGeneratedExtension, newSingularGeneratedExtension, parseDelimitedFrom, parseDelimitedFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parsePartialFrom, parseUnknownField, registerDefaultInstance, toBuilder, toString, writeToMethods inherited from class com.google.protobuf.AbstractMessageLite
addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType, isInitialized
-
Field Details
-
NODE_NUMBER_FIELD_NUMBER
public static final int NODE_NUMBER_FIELD_NUMBER- See Also:
-
MIN_STAKE_FIELD_NUMBER
public static final int MIN_STAKE_FIELD_NUMBER- See Also:
-
MAX_STAKE_FIELD_NUMBER
public static final int MAX_STAKE_FIELD_NUMBER- See Also:
-
STAKE_TO_REWARD_FIELD_NUMBER
public static final int STAKE_TO_REWARD_FIELD_NUMBER- See Also:
-
STAKE_TO_NOT_REWARD_FIELD_NUMBER
public static final int STAKE_TO_NOT_REWARD_FIELD_NUMBER- See Also:
-
STAKE_REWARD_START_FIELD_NUMBER
public static final int STAKE_REWARD_START_FIELD_NUMBER- See Also:
-
UNCLAIMED_STAKE_REWARD_START_FIELD_NUMBER
public static final int UNCLAIMED_STAKE_REWARD_START_FIELD_NUMBER- See Also:
-
STAKE_FIELD_NUMBER
public static final int STAKE_FIELD_NUMBER- See Also:
-
REWARD_SUM_HISTORY_FIELD_NUMBER
public static final int REWARD_SUM_HISTORY_FIELD_NUMBER- See Also:
-
WEIGHT_FIELD_NUMBER
public static final int WEIGHT_FIELD_NUMBER- See Also:
-
PENDING_REWARDS_FIELD_NUMBER
public static final int PENDING_REWARDS_FIELD_NUMBER- See Also:
-
DELETED_FIELD_NUMBER
public static final int DELETED_FIELD_NUMBER- See Also:
-
-
Method Details
-
getNodeNumber
public long getNodeNumber()* The entity number of this node.<br/> The shard and realm numbers are implied, based on the network address book entry for this node. <p> This value SHALL be unique within a given shard and realm.<br/> This value MAY be repeated across shards and/or realms.
int64 node_number = 1;- Specified by:
getNodeNumberin interfaceStakingNodeInfoOrBuilder- Returns:
- The nodeNumber.
-
getMinStake
public long getMinStake()* The minimum stake, in tinybar, that is required for this node to have a non-zero weight in the network consensus. <p> If the current value of `stake` is below this value, this node SHALL have a zero weight in network consensus.
int64 min_stake = 2;- Specified by:
getMinStakein interfaceStakingNodeInfoOrBuilder- Returns:
- The minStake.
-
getMaxStake
public long getMaxStake()* The maximum stake to this node that is considered to calculate its weight in the network consensus. <p> If the current `stake` value is above this limit, the excess staked HBAR SHALL NOT be considered when determining consensus weight.
int64 max_stake = 3;- Specified by:
getMaxStakein interfaceStakingNodeInfoOrBuilder- Returns:
- The maxStake.
-
getStakeToReward
public long getStakeToReward()* The sum of balances of all accounts staked to this node, considering only accounts that choose to receive rewards.
int64 stake_to_reward = 4;- Specified by:
getStakeToRewardin interfaceStakingNodeInfoOrBuilder- Returns:
- The stakeToReward.
-
getStakeToNotReward
public long getStakeToNotReward()* The sum of balances of all accounts staked to this node, considering only accounts that decline to receive rewards.
int64 stake_to_not_reward = 5;- Specified by:
getStakeToNotRewardin interfaceStakingNodeInfoOrBuilder- Returns:
- The stakeToNotReward.
-
getStakeRewardStart
public long getStakeRewardStart()* The snapshot of stake_to_reward value at the beginning of the current staking period. <p> This is necessary when calculating rewards for the current staking period without considering changes to `stake_to_reward` _within_ the current staking period.<br/> This value SHALL be reset at the beginning of every staking period.
int64 stake_reward_start = 6;- Specified by:
getStakeRewardStartin interfaceStakingNodeInfoOrBuilder- Returns:
- The stakeRewardStart.
-
getUnclaimedStakeRewardStart
public long getUnclaimedStakeRewardStart()* The amount of staked HBAR from `stake_reward_start` that will have unclaimed rewards due to accounts changing their staking metadata in a way that disqualifies them for the current staking period. <p> This value SHALL be reset at the beginning of every staking period.
int64 unclaimed_stake_reward_start = 7;- Specified by:
getUnclaimedStakeRewardStartin interfaceStakingNodeInfoOrBuilder- Returns:
- The unclaimedStakeRewardStart.
-
getStake
public long getStake()* The total amount of HBAR staked to this node. <p> This is sum of stake_to_reward and stake_to_not_reward.<br/> If the sum is greater than `max_stake`, then the _effective_ stake SHALL be `max_stake`.<br/> If the sum is less than `min_stake`, then the _effective_ stake SHALL be `0`.
int64 stake = 8;- Specified by:
getStakein interfaceStakingNodeInfoOrBuilder- Returns:
- The stake.
-
getRewardSumHistoryList
* A running list of reward amounts for the last 365+1 staking periods (typically a year and a day). <p> The first element SHALL be the reward up to and including the last full period prior to the present reward period.<br/> The second element SHALL be the reward up to and including the period before the last full period prior to the present period.<br/> The list SHALL continue in reverse chronological order until the reward history limit is reached.
repeated int64 reward_sum_history = 9;- Specified by:
getRewardSumHistoryListin interfaceStakingNodeInfoOrBuilder- Returns:
- A list containing the rewardSumHistory.
-
getRewardSumHistoryCount
public int getRewardSumHistoryCount()* A running list of reward amounts for the last 365+1 staking periods (typically a year and a day). <p> The first element SHALL be the reward up to and including the last full period prior to the present reward period.<br/> The second element SHALL be the reward up to and including the period before the last full period prior to the present period.<br/> The list SHALL continue in reverse chronological order until the reward history limit is reached.
repeated int64 reward_sum_history = 9;- Specified by:
getRewardSumHistoryCountin interfaceStakingNodeInfoOrBuilder- Returns:
- The count of rewardSumHistory.
-
getRewardSumHistory
public long getRewardSumHistory(int index) * A running list of reward amounts for the last 365+1 staking periods (typically a year and a day). <p> The first element SHALL be the reward up to and including the last full period prior to the present reward period.<br/> The second element SHALL be the reward up to and including the period before the last full period prior to the present period.<br/> The list SHALL continue in reverse chronological order until the reward history limit is reached.
repeated int64 reward_sum_history = 9;- Specified by:
getRewardSumHistoryin interfaceStakingNodeInfoOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The rewardSumHistory at the given index.
-
getWeight
Deprecated.proto.StakingNodeInfo.weight is deprecated. See staking_node_info.proto;l=133* The consensus weight of this node in the network. <p> This is recomputed based on the `stake` of this node at midnight UTC of each day. If the `stake` of this node at that time is less than `min_stake`, then the weight SHALL be 0.<br/> <p> Given the following: <ul> <li>The `effective stake` of a single node SHALL be `0` if the node `stake` is less than `min_stake`.</li> <li>The `effective stake` SHALL be `max_stake` if the node `stake` is greater than `max_stake`.</li> <li>The `effective stake` SHALL be the actual value of `stake` if `min_stake` < `stake` < `max_stake`.</li> <li>The `effective network stake` SHALL be calculated as ∑(`effective stake` of each node) for all nodes in the network address book.</li> </ul> <p> This field is deprecated and SHALL NOT be used when RosterLifecycle is enabled. The weight SHALL be same as the `effective_stake` described above.
int32 weight = 10 [deprecated = true];- Specified by:
getWeightin interfaceStakingNodeInfoOrBuilder- Returns:
- The weight.
-
getPendingRewards
public long getPendingRewards()* The total staking rewards in tinybars that MAY be collected by all accounts staking to the current node after the end of this staking period. <p> This SHALL be calculated assuming that no account "renounces" its rewards by setting `decline_reward` to true, or is ineligible for some other reason.<br/> When the current node is deleted, this amount SHALL be subtracted from the total pending rewards of all accounts staking to all nodes in the network in NetworkStakingRewards.
int64 pending_rewards = 11;- Specified by:
getPendingRewardsin interfaceStakingNodeInfoOrBuilder- Returns:
- The pendingRewards.
-
getDeleted
public boolean getDeleted()* A flag indicating that this node has been removed from this network.
bool deleted = 12;- Specified by:
getDeletedin interfaceStakingNodeInfoOrBuilder- Returns:
- The deleted.
-
parseFrom
public static StakingNodeInfo parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static StakingNodeInfo parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static StakingNodeInfo parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static StakingNodeInfo parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static StakingNodeInfo parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static StakingNodeInfo parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static StakingNodeInfo parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static StakingNodeInfo parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
public static StakingNodeInfo parseFrom(com.google.protobuf.CodedInputStream input) throws IOException - Throws:
IOException
-
parseFrom
public static StakingNodeInfo parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
newBuilder
-
newBuilder
-
dynamicMethod
protected final Object dynamicMethod(com.google.protobuf.GeneratedMessageLite.MethodToInvoke method, Object arg0, Object arg1) - Specified by:
dynamicMethodin classcom.google.protobuf.GeneratedMessageLite<StakingNodeInfo,StakingNodeInfo.Builder>
-
getDefaultInstance
-
parser
-