Documentation ¶
Index ¶
- Constants
- func IsAllowdedFormatType(formatType FormatType) bool
- func IsAllowedHashType(hashType CodeHashIndex) bool
- func IsAllowedPrefix(prefix string) bool
- func IsFullPayloadFormatType(formatType FormatType) bool
- func PrefixForMode(mode types.Mode) string
- type CodeHashIndex
- type FormatType
- type HashInfo
Constants ¶
View Source
const ( PrefixTestNet = "ckt" PrefixMainNet = "ckb" )
Variables ¶
This section is empty.
Functions ¶
func IsAllowdedFormatType ¶
func IsAllowdedFormatType(formatType FormatType) bool
func IsAllowedHashType ¶
func IsAllowedHashType(hashType CodeHashIndex) bool
func IsAllowedPrefix ¶
func IsFullPayloadFormatType ¶
func IsFullPayloadFormatType(formatType FormatType) bool
func PrefixForMode ¶
Types ¶
type CodeHashIndex ¶
type CodeHashIndex = uint8
const ( CodeHashIndex0 CodeHashIndex = 0 CodeHashIndex1 CodeHashIndex = 1 )
Code hash index doc: https://github.com/nervosnetwork/rfcs/blob/master/rfcs/0021-ckb-address-format/0021-ckb-address-format.md#short-payload-format
type FormatType ¶
type FormatType = uint8
const ( FormatTypeShort FormatType = 1 FormatTypeFullData FormatType = 2 FormatTypeFullType FormatType = 4 )
Format types doc: https://github.com/nervosnetwork/rfcs/blob/master/rfcs/0021-ckb-address-format/0021-ckb-address-format.md#payload-format-types
type HashInfo ¶
type HashInfo struct { HashType CodeHashIndex Data *types.HexStr }
func NewHashInfo ¶
Click to show internal directories.
Click to hide internal directories.