btcindexer

package module
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 31, 2025 License: MPL-2.0 Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(workerUrl string) Client

func (Client) PutBlocks

func (c Client) PutBlocks(putBlocks PutBlocksReq) (*http.Response, error)

type PutBlock

type PutBlock struct {
	Height int64 `msg:"height"`
	// Block is bitcoin core encoding of a Bitcoin block
	Block []byte `msg:"block"`
}

PutBlock wraps serialized Bitcoin block (using Bitcoin core encoding) and the block height.

func (*PutBlock) DecodeMsg

func (z *PutBlock) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable

func (*PutBlock) EncodeMsg

func (z *PutBlock) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (*PutBlock) MarshalMsg

func (z *PutBlock) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (*PutBlock) Msgsize

func (z *PutBlock) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*PutBlock) UnmarshalMsg

func (z *PutBlock) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

type PutBlocksReq

type PutBlocksReq []PutBlock

PutBlocksReq is the type expected by the PUT bitcoin/blocks endpoint

func (*PutBlocksReq) DecodeMsg

func (z *PutBlocksReq) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable

func (PutBlocksReq) EncodeMsg

func (z PutBlocksReq) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (PutBlocksReq) MarshalMsg

func (z PutBlocksReq) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (PutBlocksReq) Msgsize

func (z PutBlocksReq) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*PutBlocksReq) UnmarshalMsg

func (z *PutBlocksReq) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL