events

package
v0.24.0 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2024 License: AGPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FilterLogsForReceipt added in v0.22.0

func FilterLogsForReceipt(receipt *types.Receipt, account *gethcommon.Address, storage storage.Storage) ([]*types.Log, error)

FilterLogsForReceipt removes the logs that the sender of a transaction is not allowed to view

Types

type SubscriptionManager

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

SubscriptionManager manages the creation/deletion of subscriptions, and the filtering and encryption of logs for active subscriptions.

func NewSubscriptionManager

func NewSubscriptionManager(storage storage.Storage, chainID int64, logger gethlog.Logger) *SubscriptionManager

func (*SubscriptionManager) AddSubscription

func (s *SubscriptionManager) AddSubscription(id gethrpc.ID, encodedSubscription []byte) error

AddSubscription adds a log subscription to the enclave under the given ID, provided the request is authenticated correctly. If there is an existing subscription with the given ID, it is overwritten.

func (*SubscriptionManager) GetSubscribedLogsForBatch

func (s *SubscriptionManager) GetSubscribedLogsForBatch(batch *core.Batch, receipts types.Receipts) (common.EncryptedSubscriptionLogs, error)

GetSubscribedLogsForBatch - Retrieves and encrypts the logs for the batch in live mode. The assumption is that this function is called synchronously after the batch is produced

func (*SubscriptionManager) RemoveSubscription

func (s *SubscriptionManager) RemoveSubscription(id gethrpc.ID)

RemoveSubscription removes the log subscription with the given ID from the enclave. If there is no subscription with the given ID, nothing is deleted.

Jump to

Keyboard shortcuts

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