Runtime bindings
Technical reference of Bindings del runtime.
Symbols
| Symbol | Class | Description |
|---|---|---|
| ResetRuntimeContext | func | Reboot ResetRuntimeContext. |
| SetRuntimeContextState | func | Sets SetRuntimeContextState. |
| RuntimeContextState | func | It gets the private state of Context. |
| ResetRuntimeBody | func | Reboot ResetRuntimeBody. |
| SetRuntimeRequestIP | func | Sets SetRuntimeRequestIP. |
| SetRuntimeRequestRoute | func | Sets SetRuntimeRequestRoute. |
| ServerInfoBindings | type | ServerInfoBindings defines a public type of API. |
| BindServerInfo | func | Install BindServerInfo. |
| ClusterInfoBindings | type | ClusterInfoBindings defines a public type of API. |
| BindClusterInfo | func | Install BindClusterInfo. |
| SessionRegistryBindings | type | SessionRegistryBindings defines a public type of API. |
| BindSessionRegistry | func | Install BindSessionRegistry. |
ResetRuntimeContext
Declaration:
func ResetRuntimeContext(ctx *Context) Reboot ResetRuntimeContext.
Parameters
| Parameter | Type | Description |
|---|---|---|
ctx | *Context | Context of execution. |
SetRuntimeContextState
Declaration:
func SetRuntimeContextState(ctx *Context, state any) Sets SetRuntimeContextState.
Parameters
| Parameter | Type | Description |
|---|---|---|
ctx | *Context | Context of execution. |
state | any | Type value any required by the operation. |
RuntimeContextState
Declaration:
func RuntimeContextState(ctx *Context) any It gets the private state of Context.
Parameters
| Parameter | Type | Description |
|---|---|---|
ctx | *Context | Context of execution. |
Returns
| Return | Type | Description |
|---|---|---|
value | any | Type value any produced by the operation. |
ResetRuntimeBody
Declaration:
func ResetRuntimeBody(value Body, reader io.ReadCloser, contentType string) bool Reboot ResetRuntimeBody.
Parameters
| Parameter | Type | Description |
|---|---|---|
value | Body | Value to be stored or issued. |
reader | io.ReadCloser | Reading source. |
contentType | string | MIME type of content. |
Returns
| Return | Type | Description |
|---|---|---|
value | bool | It indicates the result of the check. |
SetRuntimeRequestIP
Declaration:
func SetRuntimeRequestIP(request *Request, ip string) Sets SetRuntimeRequestIP.
Parameters
| Parameter | Type | Description |
|---|---|---|
request | *Request | Type value *Request required by the operation. |
ip | string | Type value string required by the operation. |
SetRuntimeRequestRoute
Declaration:
func SetRuntimeRequestRoute(request *Request, route Route) Sets SetRuntimeRequestRoute.
Parameters
| Parameter | Type | Description |
|---|---|---|
request | *Request | Type value *Request required by the operation. |
route | Route | Type value Route required by the operation. |
ServerInfoBindings
Declaration:
type ServerInfoBindings struct {
ProjectName func() string
InstanceID func() string
StartedAt func() time.Time
Host func() string
Port func() int
IsDevelopment func() bool
IsClustered func() bool
} ServerInfoBindings defines a public type of API.
Fields
| Field | Type | Description |
|---|---|---|
ProjectName | func() string | Name of the element. |
InstanceID | func() string | Associated identifier. |
StartedAt | func() time.Time | Time mark. |
Host | func() string | Host, including the port when it exists. |
Port | func() int | Explicit URL port. |
IsDevelopment | func() bool | Public data associated with IsDevelopment. |
IsClustered | func() bool | Public data associated with IsClustered. |
BindServerInfo
Declaration:
func BindServerInfo(bindings ServerInfoBindings) func() Install BindServerInfo.
Parameters
| Parameter | Type | Description |
|---|---|---|
bindings | ServerInfoBindings | Type value ServerInfoBindings required by the operation. |
Returns
| Return | Type | Description |
|---|---|---|
value | func() | Type value func() produced by the operation. |
ClusterInfoBindings
Declaration:
type ClusterInfoBindings struct {
Enabled func() bool
Adapter func() string
} ClusterInfoBindings defines a public type of API.
Fields
| Field | Type | Description |
|---|---|---|
Enabled | func() bool | Activate or disable the function. |
Adapter | func() string | Name of the adapter. |
BindClusterInfo
Declaration:
func BindClusterInfo(bindings ClusterInfoBindings) func() Install BindClusterInfo.
Parameters
| Parameter | Type | Description |
|---|---|---|
bindings | ClusterInfoBindings | Type value ClusterInfoBindings required by the operation. |
Returns
| Return | Type | Description |
|---|---|---|
value | func() | Type value func() produced by the operation. |
SessionRegistryBindings
Declaration:
type SessionRegistryBindings struct {
Get func(sessionID string) (*Session, error)
} SessionRegistryBindings defines a public type of API.
Fields
| Field | Type | Description |
|---|---|---|
Get | func(sessionID string) (*Session, error) | Query callback. |
BindSessionRegistry
Declaration:
func BindSessionRegistry(bindings SessionRegistryBindings) func() Install BindSessionRegistry.
Parameters
| Parameter | Type | Description |
|---|---|---|
bindings | SessionRegistryBindings | Type value SessionRegistryBindings required by the operation. |
Returns
| Return | Type | Description |
|---|---|---|
value | func() | Type value func() produced by the operation. |