console

package
v0.0.0-...-64a0d4e Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2017 License: BSD-3-Clause Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Register

func Register(registry *objects.Registry)

Types

type Component

type Component struct {
	Log           log.DebugLogger `com:"singleton"`
	Auth          auth.Requestor  `com:"singleton"`
	MenuProviders []MenuProvider  `com:"extpoint"`
	PageHandlers  []PageHandler   `com:"extpoint"`

	Views *jet.Set

	Config
}

func (*Component) InitializeConfig

func (c *Component) InitializeConfig(cfg config.Settings) error

func (*Component) InitializeDaemon

func (c *Component) InitializeDaemon() error

func (*Component) MatchHTTP

func (c *Component) MatchHTTP(r *http.Request) bool

func (*Component) RenderTemplate

func (c *Component) RenderTemplate(w http.ResponseWriter, r *http.Request, tmpl string, vars map[string]interface{}, data interface{})

func (*Component) ServeHTTP

func (c *Component) ServeHTTP(w http.ResponseWriter, r *http.Request)

type Config

type Config struct {
	// base path to use for web endpoints
	BasePath string

	// name of console used in titles
	Name string
}
type MenuItem struct {
	Title string
	Link  string
}
type MenuProvider interface {
	ConsoleMenuItems() []MenuItem
}

type PageHandler

type PageHandler interface {
	MenuProvider
	web.Handler
}

Directories

Path Synopsis
Package init is used to register the console component with the default registry via side effect import.
Package init is used to register the console component with the default registry via side effect import.

Jump to

Keyboard shortcuts

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