srv

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2017 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewServer

func NewServer(addr, templateDir, staticDir, uuid, webpackDevServer string, reload bool, apiClient pb.ApiClient) *http.Server

Types

type MockApiClient

type MockApiClient struct{}

func (MockApiClient) ListPods

func (m MockApiClient) ListPods(ctx context.Context, in *pb.Empty, opts ...grpc.CallOption) (*pb.ListPodsResponse, error)

func (MockApiClient) Stat

func (MockApiClient) Tap

func (MockApiClient) Version

func (m MockApiClient) Version(ctx context.Context, in *pb.Empty, opts ...grpc.CallOption) (*pb.VersionInfo, error)

type Server

type Server struct {
	// contains filtered or unexported fields
}

func FakeServer

func FakeServer() Server

func (*Server) RenderTemplate

func (s *Server) RenderTemplate(w http.ResponseWriter, templateFile, templateName string, args interface{}) error

func (*Server) ServeHTTP

func (s *Server) ServeHTTP(w http.ResponseWriter, req *http.Request)

this is called by the HTTP server to actually respond to a request

Jump to

Keyboard shortcuts

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