Documentation ¶
Index ¶
- type AccountUseCase
- func (mAccUC AccountUseCase) Create(ctx context.Context, accountInput usecase.AccountCreateInput) (*usecase.AccountCreateOutput, error)
- func (mAccUC AccountUseCase) Fetch(ctx context.Context) ([]usecase.AccountFetchOutput, error)
- func (mAccUC AccountUseCase) GetBalance(ctx context.Context, id model.AccountID) (*usecase.AccountBalanceOutput, error)
- type AuthUseCase
- type TransferUseCase
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccountUseCase ¶
type AccountUseCase struct { OnCreate func(ctx context.Context, accountInput usecase.AccountCreateInput) (*usecase.AccountCreateOutput, error) OnFetch func(ctx context.Context) ([]usecase.AccountFetchOutput, error) OnGetBalance func(ctx context.Context, id model.AccountID) (*usecase.AccountBalanceOutput, error) }
AccountUseCase mocks an usecase.AccountUseCase.
func (AccountUseCase) Create ¶
func (mAccUC AccountUseCase) Create(ctx context.Context, accountInput usecase.AccountCreateInput) (*usecase.AccountCreateOutput, error)
Create returns the result of OnCreate.
func (AccountUseCase) Fetch ¶
func (mAccUC AccountUseCase) Fetch(ctx context.Context) ([]usecase.AccountFetchOutput, error)
Fetch returns the result of OnFetch.
func (AccountUseCase) GetBalance ¶
func (mAccUC AccountUseCase) GetBalance(ctx context.Context, id model.AccountID) (*usecase.AccountBalanceOutput, error)
GetBalance returns the result of OnGetBalance.
type AuthUseCase ¶
type AuthUseCase struct { OnLogin func(ctx context.Context, loginInput usecase.AuthLoginInput) (*usecase.AuthTokenOutput, error) OnAuthorize func(ctx context.Context, accessToken string) (*jwt.RegisteredClaims, error) }
AuthUseCase mocks an usecase.AuthUseCase.
func (AuthUseCase) Authorize ¶
func (mAuthUC AuthUseCase) Authorize(ctx context.Context, accessToken string) (*jwt.RegisteredClaims, error)
Authorize executes Authorize.
func (AuthUseCase) Login ¶
func (mAuthUC AuthUseCase) Login(ctx context.Context, loginInput usecase.AuthLoginInput) (*usecase.AuthTokenOutput, error)
Login executes OnLogin.
type TransferUseCase ¶
type TransferUseCase struct { OnCreate func(ctx context.Context, transferInput usecase.TransferCreateInput) (*usecase.TransferCreateOutput, error) OnFetch func(ctx context.Context, accountID model.AccountID) ([]usecase.TransferFetchOutput, error) }
TransferUseCase mocks an usecase.TransferUseCase.
func (TransferUseCase) Create ¶
func (mTrfUC TransferUseCase) Create(ctx context.Context, transferInput usecase.TransferCreateInput) (*usecase.TransferCreateOutput, error)
Create returns the result of OnCreate.
func (TransferUseCase) Fetch ¶
func (mTrfUC TransferUseCase) Fetch(ctx context.Context, accountID model.AccountID) ([]usecase.TransferFetchOutput, error)
Fetch returns the result of OnFetch.
Click to show internal directories.
Click to hide internal directories.