Documentation ¶
Index ¶
- func AddService(collection *dependencyinjection.ServiceCollection, serviceCtor interface{})
- type ApplicationBuilder
- func (builder *ApplicationBuilder) AddGrpcService(configure func(server *grpc.Server, ctx *ServiceContext)) *ApplicationBuilder
- func (builder *ApplicationBuilder) AddServerOption(serverOption grpc.ServerOption) *ApplicationBuilder
- func (builder *ApplicationBuilder) AddStreamServerInterceptor(interceptor ...grpc.StreamServerInterceptor) *ApplicationBuilder
- func (builder *ApplicationBuilder) AddUnaryServerInterceptor(interceptor ...grpc.UnaryServerInterceptor) *ApplicationBuilder
- func (builder *ApplicationBuilder) Build() interface{}
- func (builder *ApplicationBuilder) SetHostBuildContext(context *abstractions.HostBuilderContext)
- type Host
- type HostBuilder
- type HostBuilderDecorator
- func (h HostBuilderDecorator) OverrideConfigure(configureFunc interface{}, builder abstractions.IApplicationBuilder)
- func (h HostBuilderDecorator) OverrideIOCInnerConfigures(serviceCollection *dependencyinjection.ServiceCollection)
- func (h HostBuilderDecorator) OverrideNewApplicationBuilder(context *abstractions.HostBuilderContext) abstractions.IApplicationBuilder
- func (h HostBuilderDecorator) OverrideNewHost(server abstractions.IServer, context *abstractions.HostBuilderContext) abstractions.IServiceHost
- type Server
- type ServerBuilderContext
- type ServiceContext
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddService ¶
func AddService(collection *dependencyinjection.ServiceCollection, serviceCtor interface{})
Types ¶
type ApplicationBuilder ¶
type ApplicationBuilder struct {
// contains filtered or unexported fields
}
func NewApplicationBuilder ¶
func NewApplicationBuilder() *ApplicationBuilder
func (*ApplicationBuilder) AddGrpcService ¶
func (builder *ApplicationBuilder) AddGrpcService(configure func(server *grpc.Server, ctx *ServiceContext)) *ApplicationBuilder
func (*ApplicationBuilder) AddServerOption ¶
func (builder *ApplicationBuilder) AddServerOption(serverOption grpc.ServerOption) *ApplicationBuilder
func (*ApplicationBuilder) AddStreamServerInterceptor ¶
func (builder *ApplicationBuilder) AddStreamServerInterceptor(interceptor ...grpc.StreamServerInterceptor) *ApplicationBuilder
func (*ApplicationBuilder) AddUnaryServerInterceptor ¶
func (builder *ApplicationBuilder) AddUnaryServerInterceptor(interceptor ...grpc.UnaryServerInterceptor) *ApplicationBuilder
func (*ApplicationBuilder) Build ¶
func (builder *ApplicationBuilder) Build() interface{}
func (*ApplicationBuilder) SetHostBuildContext ¶
func (builder *ApplicationBuilder) SetHostBuildContext(context *abstractions.HostBuilderContext)
type Host ¶
type Host struct {
abstractions.ServiceHost
}
func NewHost ¶
func NewHost(server abstractions.IServer, hostContext *abstractions.HostBuilderContext) Host
type HostBuilder ¶
type HostBuilder struct {
abstractions.HostBuilder
}
func NewHostBuilder ¶
func NewHostBuilder() *HostBuilder
func (*HostBuilder) Configure ¶
func (host *HostBuilder) Configure(configure func(*ApplicationBuilder)) *HostBuilder
func (*HostBuilder) UseConfiguration ¶
func (host *HostBuilder) UseConfiguration(configuration abstractions.IConfiguration) *HostBuilder
type HostBuilderDecorator ¶
type HostBuilderDecorator struct { }
func NewHostBuilderDecorator ¶
func NewHostBuilderDecorator() HostBuilderDecorator
func (HostBuilderDecorator) OverrideConfigure ¶
func (h HostBuilderDecorator) OverrideConfigure(configureFunc interface{}, builder abstractions.IApplicationBuilder)
func (HostBuilderDecorator) OverrideIOCInnerConfigures ¶
func (h HostBuilderDecorator) OverrideIOCInnerConfigures(serviceCollection *dependencyinjection.ServiceCollection)
func (HostBuilderDecorator) OverrideNewApplicationBuilder ¶
func (h HostBuilderDecorator) OverrideNewApplicationBuilder(context *abstractions.HostBuilderContext) abstractions.IApplicationBuilder
func (HostBuilderDecorator) OverrideNewHost ¶
func (h HostBuilderDecorator) OverrideNewHost(server abstractions.IServer, context *abstractions.HostBuilderContext) abstractions.IServiceHost
type Server ¶
type Server struct { IsTLS bool Addr string CertFile string `mapstructure:"cert" config:"cert"` KeyFile string `mapstructure:"key" config:"key"` // contains filtered or unexported fields }
func NewGrpcServerConfig ¶
func NewGrpcServerConfig(config hostenv.HttpServerConfig) *Server
func (*Server) Run ¶
func (server *Server) Run(context *abstractions.HostBuilderContext) (e error)
type ServerBuilderContext ¶
type ServerBuilderContext struct {
// contains filtered or unexported fields
}
type ServiceContext ¶
type ServiceContext struct { ApplicationServices dependencyinjection.IServiceProvider Configuration abstractions.IConfiguration }
func NewServiceContext ¶
func NewServiceContext(sp dependencyinjection.IServiceProvider, config abstractions.IConfiguration) *ServiceContext
func (*ServiceContext) Register ¶
func (ctx *ServiceContext) Register(fn interface{})
Source Files ¶
Click to show internal directories.
Click to hide internal directories.