Documentation
¶
Index ¶
- func GetURIParams(api *API, rawURL url.URL) url.Values
- func IsWildCardBackendPath(api *API) bool
- type API
- type Node
- type Route
- func (rt *Route) ClearAPI() error
- func (rt *Route) DeleteAPI(fullPath string, httpverb string) bool
- func (rt *Route) DeleteNode(fullPath string) bool
- func (rt *Route) FindAPI(fullPath string, httpverb string) (*API, bool)
- func (rt *Route) MatchAPI(fullPath string, httpverb string) (*API, bool)
- func (rt *Route) PutAPI(api API) error
- func (rt *Route) PutOrUpdateAPI(api API) error
- func (rt *Route) RemoveAPI(api API)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetURIParams ¶
GetURIParams returns the values retrieved from the rawURL
func IsWildCardBackendPath ¶
IsWildCardBackendPath checks whether the configured path of the upstream restful service contains parameters
Types ¶
type API ¶ added in v1.1.0
type API struct {
URLPattern string `json:"urlPattern" yaml:"urlPattern"`
config.Method `json:"method,inline" yaml:"method,inline"`
Headers map[string]string `json:"headers,omitempty" yaml:"headers,omitempty"`
}
API describes the minimum configuration of an RESTful api configure in gateway
type Node ¶
type Node struct {
// contains filtered or unexported fields
}
Node defines the single method of the router configured API
type Route ¶
type Route struct {
// contains filtered or unexported fields
}
Route defines the tree of router APIs
func (*Route) DeleteNode ¶ added in v1.1.0
DeleteNode delete node by fullPath
func (*Route) PutOrUpdateAPI ¶ added in v1.1.0
PutOrUpdateAPI puts or updates an api into the resource
Click to show internal directories.
Click to hide internal directories.