Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Factory ¶
type Factory interface { // 处理器示例配置 SampleConfig() string // 处理器描述 Description() string // 处理器示例 Example() Processor // 创建实例 New(config string) (Processor, error) }
func GetFactory ¶
func NewFactory ¶
func NewFactory(sampleConfig interface{}, description string, example interface{}, factoryFunc FactoryFunc) Factory
func NewFactoryWithProcessor ¶
type FactoryFunc ¶
type FactoryTemplate ¶
type FactoryTemplate struct {
// contains filtered or unexported fields
}
func (FactoryTemplate) Description ¶
func (f FactoryTemplate) Description() string
func (FactoryTemplate) Example ¶ added in v1.0.4
func (f FactoryTemplate) Example() Processor
func (FactoryTemplate) SampleConfig ¶
func (f FactoryTemplate) SampleConfig() string
type NamedFactory ¶
func ListFactory ¶
func ListFactory() []NamedFactory
Click to show internal directories.
Click to hide internal directories.