client

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 14, 2020 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConfigCmd added in v0.25.0

func ConfigCmd(defaultCLIHome string) *cobra.Command

ConfigCmd returns a CLI command to interactively create an application CLI config file.

func Paginate added in v1.0.0

func Paginate(numObjs, page, limit, defLimit int) (start, end int)

Paginate returns the correct starting and ending index for a paginated query, given that client provides a desired page and limit of objects and the handler provides the total number of objects. The start page is assumed to be 1-indexed. If the start page is invalid, non-positive values are returned signaling the request is invalid; it returns non-positive values if limit is non-positive and defLimit is negative.

func RegisterRoutes added in v1.0.0

func RegisterRoutes(cliCtx context.CLIContext, r *mux.Router)

Register routes

func ValidateCmd added in v1.0.0

func ValidateCmd(cmd *cobra.Command, args []string) error

ValidateCmd returns unknown command error or Help display if help flag set

Types

This section is empty.

Directories

Path Synopsis
lcd
statik
Package statik contains static assets.
Package statik contains static assets.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL