registry

package
v0.8.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 18, 2023 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// Extractors is a factory for extractors
	Extractors = NewExtractorFactory()
	// Sinks is a factory for sinks
	Sinks = NewSinkFactory()
	// Processors is a factory for processors
	Processors = NewProcessorFactory()
)

Functions

This section is empty.

Types

type ExtractorFactory

type ExtractorFactory struct {
	// contains filtered or unexported fields
}

ExtractorFactory is a factory for Extractors.

func NewExtractorFactory

func NewExtractorFactory() *ExtractorFactory

NewExtractorFactory returns a new ExtractorFactory

func (*ExtractorFactory) Get

func (f *ExtractorFactory) Get(name string) (plugins.Extractor, error)

Get returns an Extractor by name.

func (*ExtractorFactory) Info

func (f *ExtractorFactory) Info(name string) (plugins.Info, error)

Info returns information about an Extractor.

func (*ExtractorFactory) List

func (f *ExtractorFactory) List() map[string]plugins.Info

List returns a list of registered Extractors.

func (*ExtractorFactory) Register

func (f *ExtractorFactory) Register(name string, extractorFn func() plugins.Extractor) (err error)

Register registers an Extractor.

type ProcessorFactory

type ProcessorFactory struct {
	// contains filtered or unexported fields
}

ProcessorFactory is a factory for Processors.

func NewProcessorFactory

func NewProcessorFactory() *ProcessorFactory

NewProcessorFactory returns a new ProcessorFactory

func (*ProcessorFactory) Get

func (f *ProcessorFactory) Get(name string) (plugins.Processor, error)

Get returns a Processor by name.

func (*ProcessorFactory) Info

func (f *ProcessorFactory) Info(name string) (info plugins.Info, err error)

Info returns information about a Processor.

func (*ProcessorFactory) List

func (f *ProcessorFactory) List() map[string]plugins.Info

List returns a list of registered processors.

func (*ProcessorFactory) Register

func (f *ProcessorFactory) Register(name string, fn func() plugins.Processor) (err error)

Register registers a Processor.

type SinkFactory

type SinkFactory struct {
	// contains filtered or unexported fields
}

SinkFactory is a factory for Sinks.

func NewSinkFactory

func NewSinkFactory() *SinkFactory

NewSinkFactory returns a new SinkFactory

func (*SinkFactory) Get

func (f *SinkFactory) Get(name string) (plugins.Syncer, error)

Get returns a Sink by name.

func (*SinkFactory) Info

func (f *SinkFactory) Info(name string) (plugins.Info, error)

Info returns information about a Sink.

func (*SinkFactory) List

func (f *SinkFactory) List() map[string]plugins.Info

List returns a list of registered Sinks.

func (*SinkFactory) Register

func (f *SinkFactory) Register(name string, fn func() plugins.Syncer) error

Register registers a Sink.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL