v1

package
v0.0.97 Latest Latest
Warning

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

Go to latest
Published: Sep 17, 2021 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Overview

Package v1 (api/v1) is the first versioned implementation of the API

Package v1 (api/v1) is the first versioned implementation of the API

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Route added in v0.0.80

func Route(r *mux.Router, s Server) *mux.Router

Route applies all the v1 API functions provided by the Server to the Router given. If the router is nil, a new one is instantiated.

Types

type Server

type Server struct {
	Client         gcs.Client
	Host           string
	DefaultBucket  string
	GridPathPrefix string
	Timeout        time.Duration
}

Server contains the necessary settings and i/o objects needed to serve this api

func (Server) GetDashboard added in v0.0.91

func (s Server) GetDashboard(w http.ResponseWriter, r *http.Request)

GetDashboard returns a given dashboard Response json: GetDashboardResponse

func (Server) GetDashboardGroup added in v0.0.80

func (s Server) GetDashboardGroup(w http.ResponseWriter, r *http.Request)

GetDashboardGroup returns a given dashboard group Response json: GetDashboardGroupResponse

func (Server) Grid added in v0.0.92

func (s Server) Grid(r *http.Request, cfg *configpb.Configuration, dashboardKey string, tabKey string) (*statepb.Grid, error)

Grid fetch tab and grid info (columns, rows, ..etc)

func (Server) GroupGrid added in v0.0.92

func (s Server) GroupGrid(configPath *gcs.Path, groupName string) (*statepb.Grid, error)

GroupGrid fetch tab group name grid info (columns, rows, ..etc)

func (Server) ListDashboardGroups

func (s Server) ListDashboardGroups(w http.ResponseWriter, r *http.Request)

ListDashboardGroups returns every dashboard group in TestGrid Response json: ListDashboardGroupResponse

func (Server) ListDashboardTabs added in v0.0.91

func (s Server) ListDashboardTabs(w http.ResponseWriter, r *http.Request)

ListDashboardTabs returns a given dashboard tabs Response json: ListDashboardTabsResponse

func (Server) ListDashboards added in v0.0.91

func (s Server) ListDashboards(w http.ResponseWriter, r *http.Request)

ListDashboards returns every dashboard in TestGrid Response json: ListDashboardResponse

func (Server) ListHeaders added in v0.0.92

func (s Server) ListHeaders(w http.ResponseWriter, r *http.Request)

ListHeaders returns dashboard tab headers Response json: ListHeadersResponse

func (Server) ListRows added in v0.0.92

func (s Server) ListRows(w http.ResponseWriter, r *http.Request)

ListRows returns dashboard tab rows Response json: ListRowsResponse

Jump to

Keyboard shortcuts

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