httpd

package
v0.0.0-...-550a133 Latest Latest
Warning

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

Go to latest
Published: Dec 7, 2022 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package httpd provides web service

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func API

func API(w http.ResponseWriter, r *http.Request, cfg cli.Config)

API handles API routes

func APIWrapper

func APIWrapper(handler APIHandler, cfg cli.Config) func(w http.ResponseWriter, r *http.Request)

APIWrapper wraps API func including cli arg

func Run

func Run(cfg cli.Config)

Run starts web service

Types

type APIHandler

type APIHandler func(w http.ResponseWriter, r *http.Request, cfg cli.Config)

APIHandler represents API function w/ cli arg

type Route

type Route struct {
	Name        string
	Method      string
	Path        string
	HandlerFunc http.HandlerFunc
}

Route represents a HTTP route

type TTracker

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

Jump to

Keyboard shortcuts

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