PoS
Classes
Class contains pos RPC methods For the detail meaning of fields, please refer to the PoS RPC document:
Typedefs
PivotDecision : ObjectPoSStatus : Object
PoS status
VotePowerState : ObjectPoSAccountStatus : ObjectPoSAccount : ObjectPoSTransaction : ObjectSignature : ObjectPoSBlock : ObjectCommitteeNode : ObjectElection : ObjectCurrentCommittee : ObjectPoSCommittee : ObjectPoSReward : ObjectPoSEpochRewards : Object
PoS
Class contains pos RPC methods For the detail meaning of fields, please refer to the PoS RPC document:
Kind: global class
new PoS(conflux)
Create PoS instance
Returns: PoS - The PoS instance
conflux
Conflux
The Conflux object
PivotDecision : Object
ObjectKind: global typedef Properties
height
number
blockHash
string
PoSStatus : Object
ObjectPoS status
Kind: global typedef Properties
VotePowerState : Object
ObjectKind: global typedef Properties
endBlockNumber
number
power
number
PoSAccountStatus : Object
ObjectKind: global typedef Properties
availableVotes
number
forfeited
number
inQueue
outQueue
locked
number
unlocked
number
forceRetired
number | null
PoSAccount : Object
ObjectKind: global typedef Properties
blockNumber
number
status
PoSTransaction : Object
ObjectKind: global typedef Properties
hash
string
blockHash
string
from
string
status
string
type
string
number
number
timestamp
number | null
blockNumber
number | null
payload
*
Signature : Object
ObjectKind: global typedef Properties
votes
number
account
string
PoSBlock : Object
ObjectKind: global typedef Properties
epoch
number
height
number
pivotDecision
round
number
timestamp
number
lastTxNumber
number
signatures
CommitteeNode : Object
ObjectKind: global typedef Properties
votingPower
number
address
string
Election : Object
ObjectKind: global typedef Properties
CurrentCommittee : Object
ObjectKind: global typedef Properties
PoSCommittee : Object
ObjectKind: global typedef Properties
currentCommittee
elections
PoSReward : Object
ObjectKind: global typedef Properties
reward
number
posAddress
string
powAddress
string
PoSEpochRewards : Object
ObjectKind: global typedef Properties
powEpochHash
string
accountRewards
.getStatus ⇒ Promise.<PoSStatus>
Promise.<PoSStatus>Kind: instance member
Returns: Promise.<PoSStatus> - PoS status object
Example
.getAccount ⇒ Promise.<PoSAccount>
Promise.<PoSAccount>Kind: instance member
account
Hash
Account address
[blockNumber]
number | hex
Optional block number
Example
.getBlockByHash ⇒ Promise.<PoSBlock>
Promise.<PoSBlock>Kind: instance member
hash
string
The hash of PoS block
Example
.getBlockByNumber ⇒ Promise.<PoSBlock>
Promise.<PoSBlock>Kind: instance member
blockNumber
number | hex
The number of PoS block
Example
.getCommittee ⇒ Promise.<PoSCommittee>
Promise.<PoSCommittee>Kind: instance member
[blockNumber]
number | hex
Optional block number
Example
.getTransactionByNumber ⇒ Promise.<PoSTransaction>
Promise.<PoSTransaction>Kind: instance member
txNumber
number | string
The number of transaction
Example
.getRewardsByEpoch(epoch) ⇒ Promise.<PoSEpochRewards>
Promise.<PoSEpochRewards>Kind: instance function
epoch
number | string
A PoS epoch number
Example
Last updated
Was this helpful?