Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecodeRPC ¶
Decode extracts the request encoded by Encode(). It returns the name of the RPC and the raw bytes of the request. The raw bytes can be used by the caller to unmarshal the bytes with the correct struct.
Types ¶
type RPC ¶
type RPC interface { Subcommand Name() string }
RPC extends subcommands.Subcommand, but it also includes the Name() method used to identify the RPC on decoding.
type Subcommand ¶
type Subcommand interface {
Execute(ctx *appcontext.AppContext, repo *repository.Repository) (int, error)
}
func Parse ¶
func Parse(ctx *appcontext.AppContext, repo *repository.Repository, command string, args []string) (Subcommand, error)
Click to show internal directories.
Click to hide internal directories.