Documentation ¶
Overview ¶
Package base contains the base sql implementation
Index ¶
- type Store
- func (s Store) DB() *gorm.DB
- func (s Store) RetrieveExecuted(ctx context.Context, filter model.Executed) ([]model.Executed, error)
- func (s Store) RetrieveLastStoredBlock(ctx context.Context, chainID uint32, address common.Address) (uint64, error)
- func (s Store) RetrieveMessageStatus(ctx context.Context, messageHash string) (graphqlModel.MessageStatus, error)
- func (s Store) RetrieveMessagesByStatus(ctx context.Context, messageStatus graphqlModel.MessageState, page int) ([]*graphqlModel.MessageStatus, error)
- func (s Store) RetrieveOriginSent(ctx context.Context, filter model.OriginSent) ([]model.OriginSent, error)
- func (s Store) StoreExecuted(ctx context.Context, executedEvent *model.Executed) error
- func (s Store) StoreLastIndexed(parentCtx context.Context, contractAddress common.Address, chainID uint32, ...) (err error)
- func (s Store) StoreOrUpdateMessageStatus(ctx context.Context, txHash string, messageHash string, ...) error
- func (s Store) StoreOriginSent(ctx context.Context, originSent *model.OriginSent) error
- func (s Store) UNSAFE_DB() *gorm.DB
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
Store is the sqlite store. It extends the base store for sqlite specific queries.
func (Store) RetrieveExecuted ¶
func (s Store) RetrieveExecuted(ctx context.Context, filter model.Executed) ([]model.Executed, error)
RetrieveExecuted gets a Executed event.
func (Store) RetrieveLastStoredBlock ¶
func (s Store) RetrieveLastStoredBlock(ctx context.Context, chainID uint32, address common.Address) (uint64, error)
RetrieveLastStoredBlock gets the last stored block.
func (Store) RetrieveMessageStatus ¶
func (s Store) RetrieveMessageStatus(ctx context.Context, messageHash string) (graphqlModel.MessageStatus, error)
RetrieveMessageStatus retrieve message status.
func (Store) RetrieveMessagesByStatus ¶ added in v0.0.5
func (s Store) RetrieveMessagesByStatus(ctx context.Context, messageStatus graphqlModel.MessageState, page int) ([]*graphqlModel.MessageStatus, error)
RetrieveMessagesByStatus retrieves pending messages.
func (Store) RetrieveOriginSent ¶
func (s Store) RetrieveOriginSent(ctx context.Context, filter model.OriginSent) ([]model.OriginSent, error)
RetrieveOriginSent gets the Origin Sent event.
func (Store) StoreExecuted ¶
StoreExecuted stores an origin event.
func (Store) StoreLastIndexed ¶
func (s Store) StoreLastIndexed(parentCtx context.Context, contractAddress common.Address, chainID uint32, blockNumber uint64) (err error)
StoreLastIndexed stores the last indexed block number for a contract.
func (Store) StoreOrUpdateMessageStatus ¶
func (s Store) StoreOrUpdateMessageStatus(ctx context.Context, txHash string, messageHash string, messageType types.MessageType) error
StoreOrUpdateMessageStatus stores or updates the message status.
func (Store) StoreOriginSent ¶
StoreOriginSent stores an origin event.
Click to show internal directories.
Click to hide internal directories.