Documentation
¶
Overview ¶
Package plugin implements the named plugin registry.
Index ¶
Constants ¶
const ( // AliasDataAPI is the anchor policy plugin API name. AliasDataAPI = "alias-data" // ErrorFormatAPI is the error-format plugin API name. ErrorFormatAPI = "error-format" // LoaderLimitsAPI is the loader-limits plugin API name. LoaderLimitsAPI = "loader-limits" // MergeKeyAPI is the Merge-Key plugin API name. MergeKeyAPI = "merge-key" // YAMLParserAPI is the YAML-parser plugin API name. YAMLParserAPI = "yaml-parser" )
Variables ¶
This section is empty.
Functions ¶
func AliasDataDisabled ¶ added in v0.2.0
AliasDataDisabled recognizes the three explicit alias rejection forms.
Types ¶
type Registration ¶
Registration describes one named implementation of a plugin API. Version is empty for an unversioned implementation.
type Registry ¶
Registry stores named plugin implementations.
func NewRegistry ¶
func NewRegistry(registrations ...Registration) *Registry
NewRegistry creates a registry containing the supplied implementations.
func (*Registry) CreateShortForm ¶ added in v0.2.0
CreateShortForm resolves a scalar implementation or empty configuration entry. Registered names take precedence over entries in the default implementation. Versioned selectors always identify registered implementations.
func (*Registry) Register ¶
func (r *Registry) Register(registration Registration) error
Register adds a named implementation to the registry.