subs

package
v0.7.3 Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2022 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BlockHandler added in v0.1.3

type BlockHandler func(block *common.Block) bool

BlockHandler when block == nil is eq EOF and signal for terminate all sub channels

type BlockSubscription added in v0.1.3

type BlockSubscription struct {
	ErrorCloser
	// contains filtered or unexported fields
}

func NewBlockSubscription

func NewBlockSubscription() *BlockSubscription

func (*BlockSubscription) Blocks added in v0.1.3

func (b *BlockSubscription) Blocks() <-chan *common.Block

func (*BlockSubscription) Handler added in v0.1.3

func (b *BlockSubscription) Handler(block *common.Block) bool

func (*BlockSubscription) Serve added in v0.1.3

func (b *BlockSubscription) Serve(base ErrorCloser, readyForHandling ReadyForHandling) *BlockSubscription

type ChaincodeEventWithBlock added in v0.7.0

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

func (*ChaincodeEventWithBlock) Block added in v0.7.0

func (eb *ChaincodeEventWithBlock) Block() uint64

func (*ChaincodeEventWithBlock) Event added in v0.7.0

func (*ChaincodeEventWithBlock) TxTimestamp added in v0.7.0

func (eb *ChaincodeEventWithBlock) TxTimestamp() *timestamp.Timestamp

type ErrorCloser added in v0.1.3

type ErrorCloser interface {
	Done() <-chan struct{}
	Err() <-chan error
	Errors() chan error
	Close() error
}

type EventSubscription added in v0.1.3

type EventSubscription struct {
	ErrorCloser
	// contains filtered or unexported fields
}

func NewEventSubscription

func NewEventSubscription(cid string, fromTx api.ChaincodeTx) *EventSubscription

func (*EventSubscription) Events added in v0.1.3

func (e *EventSubscription) Events() chan *peer.ChaincodeEvent

func (*EventSubscription) EventsExtended added in v0.7.0

func (e *EventSubscription) EventsExtended() chan interface {
	Event() *peer.ChaincodeEvent
	Block() uint64
	TxTimestamp() *timestamp.Timestamp
}

func (*EventSubscription) Handler added in v0.1.3

func (e *EventSubscription) Handler(block *common.Block) bool

func (*EventSubscription) Serve added in v0.1.3

func (e *EventSubscription) Serve(base ErrorCloser, readyForHandling ReadyForHandling) *EventSubscription

type ReadyForHandling added in v0.4.1

type ReadyForHandling func()

type TxSubscription added in v0.1.3

type TxSubscription struct {
	ErrorCloser
	// contains filtered or unexported fields
}

func NewTxSubscription

func NewTxSubscription(txId api.ChaincodeTx) *TxSubscription

func (*TxSubscription) Handler added in v0.1.3

func (ts *TxSubscription) Handler(block *common.Block) bool

func (*TxSubscription) Result added in v0.1.3

func (ts *TxSubscription) Result() (peer.TxValidationCode, error)

func (*TxSubscription) Serve added in v0.1.3

func (ts *TxSubscription) Serve(sub ErrorCloser, readyForHandling ReadyForHandling) *TxSubscription

Jump to

Keyboard shortcuts

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