Versions in this module Expand all Collapse all v0 v0.0.2412 Nov 13, 2024 v0.0.2411 Oct 21, 2024 v0.0.2410 Sep 13, 2024 v0.0.2409 Aug 29, 2024 v0.0.2408 Jul 23, 2024 Changes in this version + var ErrNotFound = errors.New("plugin not found") + func DiscoverGoPluginUsing[I IPluggable](o *GoPluginLoader) error + func DiscoverGoPlugin[I IPluggable]() error + func GetGoPluginHandleByAttestationSchemeUsing[I IPluggable](ldr *GoPluginLoader, scheme string) (I, error) + func GetGoPluginHandleByMediaTypeUsing[I IPluggable](ldr *GoPluginLoader, mediaType string) (I, error) + func GetGoPluginHandleByMediaType[I IPluggable](mediaType string) (I, error) + func GetGoPluginHandleByNameUsing[I IPluggable](ldr *GoPluginLoader, name string) (I, error) + func GetGoPluginLoadedAttestationSchemes[I IPluggable](ldr *GoPluginLoader) []string + func GetRPCClient[I IPluggable](name string, impl I, c *rpc.Client) interface + func GetRPCServer[I IPluggable](name string, impl I) interface + func GetTypeName[I IPluggable]() string + func Init(m map[string]interface{}) error + func RegisterGoPluginUsing[I IPluggable](loader *GoPluginLoader, name string, ch *RPCChannel[I]) error + func RegisterGoPlugin[I IPluggable](name string, ch *RPCChannel[I]) error + func RegisterImplementation[I IPluggable](name string, i I, ch *RPCChannel[I]) error + func Serve() + type GoPluginLoader struct + Location string + func CreateGoPluginLoader(cfg map[string]interface{}, logger *zap.SugaredLogger) (*GoPluginLoader, error) + func NewGoPluginLoader(logger *zap.SugaredLogger) *GoPluginLoader + func (o *GoPluginLoader) Close() + func (o *GoPluginLoader) GetRegisteredMediaTypes() []string + func (o *GoPluginLoader) GetRegisteredMediaTypesByPluginType(typeName string) []string + func (o *GoPluginLoader) Init(m map[string]interface{}) error + type GoPluginLoaderConfig struct + Directory string + type GoPluginManager struct + func CreateGoPluginManagerWithLoader[I IPluggable](loader *GoPluginLoader, name string, logger *zap.SugaredLogger, ...) (*GoPluginManager[I], error) + func CreateGoPluginManager[I IPluggable](v *viper.Viper, logger *zap.SugaredLogger, name string, ch *RPCChannel[I]) (*GoPluginManager[I], error) + func NewGoPluginManager[I IPluggable](loader *GoPluginLoader, logger *zap.SugaredLogger) *GoPluginManager[I] + func (o *GoPluginManager[I]) Close() error + func (o *GoPluginManager[I]) GetRegisteredAttestationSchemes() []string + func (o *GoPluginManager[I]) GetRegisteredMediaTypes() []string + func (o *GoPluginManager[I]) Init(name string, ch *RPCChannel[I]) error + func (o *GoPluginManager[I]) IsRegisteredMediaType(mediaType string) bool + func (o *GoPluginManager[I]) LookupByAttestationScheme(name string) (I, error) + func (o *GoPluginManager[I]) LookupByMediaType(mediaType string) (I, error) + func (o *GoPluginManager[I]) LookupByName(name string) (I, error) + type IManager interface + Close func() error + GetRegisteredAttestationSchemes func() []string + GetRegisteredMediaTypes func() []string + Init func(name string, ch *RPCChannel[I]) error + IsRegisteredMediaType func(mediaType string) bool + LookupByAttestationScheme func(name string) (I, error) + LookupByMediaType func(mediaType string) (I, error) + LookupByName func(name string) (I, error) + type IPluggable interface + GetAttestationScheme func() string + GetName func() string + GetSupportedMediaTypes func() []string + type IPluginContext interface + Close func() + GetAttestationScheme func() string + GetHandle func() interface{} + GetName func() string + GetPath func() string + GetTypeName func() string + type Plugin struct + Impl I + Name string + func (p *Plugin[I]) Client(b *plugin.MuxBroker, c *rpc.Client) (interface{}, error) + func (p *Plugin[I]) Server(*plugin.MuxBroker) (interface{}, error) + type PluginContext struct + Handle I + Name string + Path string + Scheme string + SupportedMediaTypes []string + func (o PluginContext[I]) Close() + func (o PluginContext[I]) GetAttestationScheme() string + func (o PluginContext[I]) GetHandle() interface{} + func (o PluginContext[I]) GetName() string + func (o PluginContext[I]) GetPath() string + func (o PluginContext[I]) GetTypeName() string + type RPCChannel struct + GetClient func(c *rpc.Client) interface{} + GetServer func(i I) interface{}