Skip to main content

bsv.Address

scrypt-ts / bsv / Address

Class: Address

bsv.Address

Table of contents

Constructors

Properties

Methods

Constructors

constructor

new Address(data, network?, type?)

Parameters

NameType
datastring | object | Uint8Array | Buffer
network?string | Network
type?string

Defined in

node_modules/bsv/index.d.ts:1401

Properties

hashBuffer

Readonly hashBuffer: Buffer

Defined in

node_modules/bsv/index.d.ts:1397


network

Readonly network: Network

Defined in

node_modules/bsv/index.d.ts:1398


type

Readonly type: string

Defined in

node_modules/bsv/index.d.ts:1399

Methods

isValid

isValid(data, network?, type?): boolean

Parameters

NameType
datastring | object | Uint8Array | Buffer
network?string | Network
type?string

Returns

boolean

Defined in

node_modules/bsv/index.d.ts:1421


toBuffer

toBuffer(): Buffer

Returns

Buffer

Defined in

node_modules/bsv/index.d.ts:1426


toByteString

toByteString(): ByteString

Returns

ByteString

Defined in

dist/smart-contract/bsv/address.d.ts:5


toHex

toHex(): string

Returns

string

Defined in

node_modules/bsv/index.d.ts:1427


toObject

toObject(): Object

Returns

Object

NameType
hashstring
networkstring
typestring

Defined in

node_modules/bsv/index.d.ts:1429


toString

toString(): string

Returns

string

Defined in

node_modules/bsv/index.d.ts:1428


fromHex

Static fromHex(hex, network?): Address

Parameters

NameType
hexstring
network?Type

Returns

Address

Defined in

node_modules/bsv/index.d.ts:1407


fromPrivateKey

Static fromPrivateKey(privateKey, network?): Address

Parameters

NameType
privateKeyPrivateKey
network?Type

Returns

Address

Defined in

node_modules/bsv/index.d.ts:1409


fromPublicKey

Static fromPublicKey(data, network?): Address

Parameters

NameType
dataPublicKey
network?Type

Returns

Address

Defined in

node_modules/bsv/index.d.ts:1408


fromPublicKeyHash

Static fromPublicKeyHash(hash, network?): Address

Parameters

NameType
hashUint8Array | Buffer
network?Type

Returns

Address

Defined in

node_modules/bsv/index.d.ts:1413


fromScriptHash

Static fromScriptHash(hash, network?): Address

Parameters

NameType
hashUint8Array | Buffer
network?Type

Returns

Address

Defined in

node_modules/bsv/index.d.ts:1417


fromString

Static fromString(address, network?): Address

Parameters

NameType
addressstring
network?Type

Returns

Address

Defined in

node_modules/bsv/index.d.ts:1406