Documentation
¶
Index ¶
- Constants
- type App
- func (a *App) CheckPassword(ctx context.Context, args ...string)
- func (a *App) CheckPasswordHash(ctx context.Context, args ...string)
- func (a *App) CookieKey(args ...string)
- func (a *App) CreateUser(ctx context.Context, args ...string)
- func (a *App) HashPassword(ctx context.Context, args ...string)
- func (a *App) Login(ctx context.Context, args ...string)
- func (a *App) Route(ctx context.Context, subCommand string, args ...string)
- func (a *App) Size(ctx context.Context, args ...string)
- func (a *App) Upload(ctx context.Context, args ...string)
- type Display
- type Stdout
Constants ¶
View Source
const Help = "TODO..."
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type App ¶
type App struct {
// contains filtered or unexported fields
}
App represents the command line interface.
func NewApp ¶
func NewApp(userService *service.User, fileService *service.File, display Display, logger *log.Logger) *App
NewApp creates a new App instance.
func (*App) CheckPassword ¶
CheckPassword checks if a password matches the password hash stored for a user.
func (*App) CheckPasswordHash ¶
CheckPasswordHash checks if a password matches a password hash.
func (*App) CreateUser ¶
CreateUser creates a user.
func (*App) HashPassword ¶
HashPassword hashes a password.
type Display ¶
type Display interface {
Println(args ...interface{})
ExitWithHelp(msg, help string)
Exit(msg string, err error)
}
Display is an interface for displaying output.
Click to show internal directories.
Click to hide internal directories.