Documentation
¶
Index ¶
- type Backend
- func (b *Backend) FindConfirmedEvents() ([]eventlog.Event, error)
- func (b *Backend) FindPendingEvents() ([]eventlog.Event, error)
- func (b *Backend) PublishEvent(publishRequest PublishRequest) (eventlog.Event, error)
- func (b *Backend) SubscribeToEvents(ctx context.Context) error
- func (b *Backend) SynchroniseAllTopics(ctx context.Context) error
- type EthShell
- type EventLog
- type IpfsShell
- type PublishRequest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Backend ¶
type Backend struct {
// contains filtered or unexported fields
}
func NewBackend ¶
func (*Backend) FindConfirmedEvents ¶
func (*Backend) PublishEvent ¶
func (b *Backend) PublishEvent(publishRequest PublishRequest) (eventlog.Event, error)
type EthShell ¶
type EthShell interface {
PublishEvent(ctx context.Context, topic string, id uuid.UUID, cid string, newAccounts []string) (*types.Transaction, common.Address, error)
GetTopics(ctx context.Context) ([]string, error)
GetEvents(topic string, fromBlock uint64) ([]ethshell.EventLogEvent, error)
SubscribeToEvents(ctx context.Context) (ethereum.Subscription, chan types.Log, error)
UnpackLog(ctx context.Context, log types.Log) (ethshell.EventLogEvent, error)
}
type EventLog ¶
type EventLog interface {
Insert(event eventlog.Event) (eventlog.Event, error)
ResetFromBlockAndInsert(topic string, lastBlockNumber uint64, events []eventlog.Event) error
FindLastSynchronisedBlockNumber(topic string) (uint64, error)
FindPendingEvents() ([]eventlog.Event, error)
FindConfirmedEvents() ([]eventlog.Event, error)
Confirm(id uuid.UUID, blockNumber uint64, timestamp uint64) (eventlog.Event, error)
ClearPendingEvents(topic string) error
}
type IpfsShell ¶
type IpfsShell interface {
PublishBusinessEvent(businessEvent ipfsshell.BusinessEvent) (string, error)
GetBusinessEvent(cid string) (ipfsshell.BusinessEvent, error)
}
Click to show internal directories.
Click to hide internal directories.