Helios API/ API Reference/ Classes/
DCert
A DCert
represents a staking action (eg. withdrawing rewards, delegating to another pool).
Hierarchy
-
↳
DCert
Index
Constructors
constructor
• new DCert(certType
)
Parameters
Name | Type |
---|---|
certType | number |
Overrides
Accessors
certType
• get
certType(): number
Get certificate type.
Returns
number
credentialType
• get
credentialType(): number
Get stake credential type.
Returns
number
stakeHash
• get
stakeHash(): PubKeyHash
| StakingValidatorHash
Get stake hash.
Returns
PubKeyHash
| StakingValidatorHash
Methods
dump
▸ dump(): any
Returns
any
toCbor
▸ toCbor(): number
[]
Returns
number
[]
Inherited from
toCborHex
▸ toCborHex(): string
Returns
string
Inherited from
toData
▸ toData(): ConstrData
Returns
typeToCbor
▸ typeToCbor(): number
[]
Returns
number
[]
fromCbor
▸ Static
fromCbor(raw
): DCert
Parameters
Name | Type |
---|---|
raw | string | number [] |
Returns
fromJson
▸ Static
fromJson(json
): DCert
Create a DCert from a given json parameter.
Parameters
Name | Type |
---|---|
json | string | { credential : { hash : string ; type : 0 | 1 } ; poolHash? : string ; type : 0 | 2 | 1 } |
Returns
fromUplcData
▸ Static
fromUplcData(data
): DCert
Parameters
Name | Type |
---|---|
data | UplcData |