MCPcopy Create free account
hub / github.com/kataras/iris / WeatherController

Struct WeatherController

_examples/routing/party-controller/main.go:32–34  ·  view source on GitHub ↗

Just like the MVC controllers, route group(aka Party) controller's fields are injected by the parent or current party's RegisterDependency method. This controller structure could be live to another sub-package of our application as well.

Source from the content-addressed store, hash-verified

30//
31// This controller structure could be live to another sub-package of our application as well.
32type WeatherController struct {
33 Client *weatherapi.Client // This is automatically injected by .RegisterDependency.
34}
35
36func (api *WeatherController) Configure(r iris.Party) {
37 // Register routes under /api/weather.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected