Documentation
¶
Index ¶
- type App
- type Bag
- type BasePath
- type Bindings
- type BootServiceProvider
- type Bootstrap
- type Collection
- type ConsoleKernel
- type Container
- type Controller
- type Decorator
- type ExceptionHandler
- type HttpKernel
- type HttpMiddleware
- type Instances
- type MapMethodRoutes
- type Model
- type Next
- type Pusher
- type RegisterServiceProvider
- type Request
- type Response
- type Route
- type RouteCollection
- type RouteOptions
- type Rule
- type ToMap
- type Value
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type App ¶
type App interface {
// Get the service container
Container() *Container
// Set the service container
SetContainer(container Container)
// Register a shared binding in the container.
Singleton(abstract interface{}, concrete interface{})
// Resolve the given type from the container.
Make(abstract interface{}) interface{}
// Register an existing instance as shared in the container.
Instance(abstract interface{}, concrete interface{}) interface{}
// Register an existing instance as shared in the container without an abstract
BindStruct(concrete interface{}) interface{}
// Bind all of the application paths in the container.
BindPathsInContainer(path BasePath)
}
type BootServiceProvider ¶
type Collection ¶
type Collection interface {
Source() []Value
First() Value
Push(item interface{}) Collection
Reverse() Collection
Contains(search interface{}) bool
Len() int
}
type ConsoleKernel ¶
type ConsoleKernel interface {
}
type Container ¶
type Container interface {
// Resolve the given type from the container.
Make(abstract interface{}) interface{}
// Register a shared binding in the container.
Singleton(abstract interface{}, concrete interface{})
// Register an existing instance as shared in the container.
Instance(abstract interface{}, concrete interface{}) interface{}
// // Register an existing instance as shared in the container without an abstract
BindStruct(concrete interface{}) interface{}
// Get the container's bindings.
Bindings() Bindings
Copy() Container
// "Extend" an abstract type in the container.
Extend(abstract interface{}, function func(service interface{}) interface{})
}
type Controller ¶
type ExceptionHandler ¶
type ExceptionHandler interface {
}
type HttpKernel ¶
type HttpKernel interface {
Handle(request *http.Request) http.ResponseWriter
}
type HttpMiddleware ¶
type MapMethodRoutes ¶
type Next ¶
type Next = Controller
type RegisterServiceProvider ¶
type Request ¶
type Request interface {
App() App
SetApp(app App) Request
Make(abstract interface{}) interface{}
Content() string
SetContent(content string) Request
Source() http.Request
Method() string
IsMethod(method string) bool
Path() string
Url() string
FullUrl() string
All() Bag
Value(key string) Value
ValueOr(key string, value interface{}) Value
Values(key string) Collection
SetUrlValues(vars map[string]string) Request
Header(key string) string
Headers() http.Header
Route() Route
}
type Route ¶
type Route interface {
Uri() string
SetUri(url string) Route
Method() string
Controller() Controller
SetPrefix(prefix string) Route
SetDestination(destination string) Route
SetStatus(status int) Route
RouteOptions() RouteOptions
Constraint() map[string]string
SetConstraint(parameter string, regex string) Route
Domain() string
SetDomain(domain string) Route
Name() string
SetName(name string) Route
Named(pattern ...string) bool
Middleware() []HttpMiddleware
SetMiddleware(middlewares []HttpMiddleware) Route
SetExcludeMiddleware(middlewares []HttpMiddleware) Route
}
type RouteCollection ¶
type RouteCollection interface {
SetApp(app App)
App() App
Push(route Route) RouteCollection
Merge(routeCollections RouteCollection) RouteCollection
All() []Route
Match(request Request) Route
Where(parameter, regex string) RouteCollection
WhereMulti(constraints map[string]string) RouteCollection
Domain(domain string) RouteCollection
Prefix(prefix string) RouteCollection
Name(name string) RouteCollection
Middleware(...HttpMiddleware) RouteCollection
WithoutMiddleware(...HttpMiddleware) RouteCollection
}
type RouteOptions ¶
type RouteOptions interface {
Prefixes() []string
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.