mirror of
https://github.com/FlipsideCrypto/dcrd.git
synced 2026-02-06 10:56:47 +00:00
hdkeychain: Add ChildNum and Depth methods.
This commit is contained in:
parent
99d7b179a3
commit
666286f0a7
@ -172,6 +172,16 @@ func (k *ExtendedKey) pubKeyBytes() []byte {
|
||||
return k.pubKey
|
||||
}
|
||||
|
||||
// ChildNum returns the child number of the extended key.
|
||||
func (k *ExtendedKey) ChildNum() uint32 {
|
||||
return k.childNum
|
||||
}
|
||||
|
||||
// Depth returns the depth of the extended key.
|
||||
func (k *ExtendedKey) Depth() uint16 {
|
||||
return k.depth
|
||||
}
|
||||
|
||||
// IsPrivate returns whether or not the extended key is a private extended key.
|
||||
//
|
||||
// A private extended key can be used to derive both hardened and non-hardened
|
||||
|
||||
Loading…
Reference in New Issue
Block a user