api

package
v1.1.0-beta Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2018 License: Apache-2.0 Imports: 28 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewHandler

func NewHandler(svr *server.Server) http.Handler

NewHandler creates a HTTP handler for API.

Types

type RegionHeap

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

RegionHeap implements heap.Interface, used for selecting top n regions.

func (*RegionHeap) Len

func (h *RegionHeap) Len() int

func (*RegionHeap) Less

func (h *RegionHeap) Less(i, j int) bool

func (*RegionHeap) Min

func (h *RegionHeap) Min() *core.RegionInfo

Min returns the minimum region from the heap.

func (*RegionHeap) Pop

func (h *RegionHeap) Pop() interface{}

Pop removes the minimum element (according to Less) from the heap and returns it.

func (*RegionHeap) Push

func (h *RegionHeap) Push(x interface{})

Push pushes an element x onto the heap.

func (*RegionHeap) Swap

func (h *RegionHeap) Swap(i, j int)

type Trend

type Trend struct {
	Stores  []trendStore  `json:"stores"`
	History *trendHistory `json:"history"`
}

Trend describes the cluster's schedule trend.

Jump to

Keyboard shortcuts

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