Documentation ¶
Index ¶
- type Fn
- type Handler
- func (h *Handler) Get(ctx context.Context, req *connect.Request[orderpb.GetRequest]) (*connect.Response[orderpb.GetResponse], error)
- func (h *Handler) List(ctx context.Context, req *connect.Request[orderpb.ListRequest]) (*connect.Response[orderpb.ListResponse], error)
- func (h *Handler) New(ctx context.Context, req *connect.Request[orderpb.NewRequest]) (*connect.Response[orderpb.NewResponse], error)
- func (h *Handler) Pay(ctx context.Context, req *connect.Request[orderpb.PayRequest]) (*connect.Response[orderpb.PayResponse], error)
- func (h *Handler) Return(ctx context.Context, req *connect.Request[orderpb.ReturnRequest]) (*connect.Response[orderpb.ReturnResponse], error)
- type RepositoryOrder
- type RepositoryOrderDynamo
- func (r RepositoryOrderDynamo) Get(ctx context.Context, order *order) error
- func (r RepositoryOrderDynamo) Insert(ctx context.Context, order *order) error
- func (r RepositoryOrderDynamo) List(ctx context.Context, order *orderlist, pagination db.Pagination) (int32, string, error)
- func (r RepositoryOrderDynamo) Update(ctx context.Context, order *order) error
- type RepositoryOrderLocker
- type RepositoryOrderLockerDynamo
- type RepositoryPayment
- type RepositorySku
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
func NewHandler ¶
func NewHandler( dbRepositoryDynamo *db.DBRepositoryDynamo, lockerDynamo *locker.LockerDynamo, repositoryPayment RepositoryPayment, repositorySku RepositorySku, ) *Handler
type RepositoryOrder ¶
type RepositoryOrderDynamo ¶
type RepositoryOrderDynamo struct {
*db.DBRepositoryDynamo
}
func (RepositoryOrderDynamo) Get ¶
func (r RepositoryOrderDynamo) Get(ctx context.Context, order *order) error
func (RepositoryOrderDynamo) Insert ¶
func (r RepositoryOrderDynamo) Insert(ctx context.Context, order *order) error
func (RepositoryOrderDynamo) List ¶
func (r RepositoryOrderDynamo) List(ctx context.Context, order *orderlist, pagination db.Pagination) (int32, string, error)
type RepositoryOrderLocker ¶
type RepositoryOrderLockerDynamo ¶
type RepositoryOrderLockerDynamo struct {
*locker.LockerDynamo
}
type RepositoryPayment ¶
type RepositoryPayment interface { Charge(context.Context, *paymentpb.NewChargeRequest) (*paymentpb.NewChargeResponse, error) Refund(context.Context, *paymentpb.NewRefundRequest) (*paymentpb.NewRefundResponse, error) }
type RepositorySku ¶
type RepositorySku interface { Get(context.Context, *skupb.GetRequest) (*skupb.GetResponse, error) GetWithLock(context.Context, *skupb.GetRequest) (*skupb.GetResponse, func() error, Fn, error) }
Click to show internal directories.
Click to hide internal directories.