Documentation ¶
Index ¶
- type Controller
- type Repository
- func (r *Repository) GetTransactionNumberBySender(ctx context.Context, sender *sender) (*int64, error)
- func (r *Repository) GetTransactionsBySender(ctx context.Context, sender *sender, p *pagination.Pagination) ([]*TransactionDocWithVAA, error)
- func (r *Repository) GetVAAById(ctx context.Context, id string) ([]byte, error)
- type Service
- type TransactionDoc
- type TransactionDocWithVAA
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Controller ¶
type Controller struct {
// contains filtered or unexported fields
}
func NewController ¶
func NewController(serv *Service, logger *zap.Logger) *Controller
func (*Controller) GetTransactionNumberBySender ¶
func (c *Controller) GetTransactionNumberBySender(ctx *fiber.Ctx) error
func (*Controller) GetTransactionsBySender ¶
func (c *Controller) GetTransactionsBySender(ctx *fiber.Ctx) error
type Repository ¶
type Repository struct {
// contains filtered or unexported fields
}
func NewRepository ¶
func NewRepository(db *mongo.Database, logger *zap.Logger) *Repository
func (*Repository) GetTransactionNumberBySender ¶
func (r *Repository) GetTransactionNumberBySender(ctx context.Context, sender *sender) (*int64, error)
func (*Repository) GetTransactionsBySender ¶
func (r *Repository) GetTransactionsBySender(ctx context.Context, sender *sender, p *pagination.Pagination) ([]*TransactionDocWithVAA, error)
func (*Repository) GetVAAById ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func NewService ¶
func NewService(r *Repository, logger *zap.Logger) *Service
func (*Service) GetTransactionNumberBySender ¶
func (*Service) GetTransactionsBySender ¶
func (s *Service) GetTransactionsBySender(ctx context.Context, sender *sender, p *pagination.Pagination) ([]*TransactionDocWithVAA, error)
type TransactionDoc ¶
type TransactionDoc struct { ID string `bson:"_id" json:"id"` TxId string `bson:"txId" json:"txId"` Address string `bson:"address" json:"address"` BlockHash string `bson:"blockHash" json:"blockHash"` BlockNumber uint32 `bson:"blockNumber" json:"blockNumber"` Sequence uint64 `bson:"sequence" json:"sequence"` EmitterChain vaa.ChainID `bson:"emitterChain" json:"emitterChain"` TargetChain vaa.ChainID `bson:"targetChain" json:"targetChain"` }
type TransactionDocWithVAA ¶
type TransactionDocWithVAA struct { TransactionDoc Vaa string `json:"vaa"` }
Click to show internal directories.
Click to hide internal directories.