Documentation
¶
Index ¶
- Variables
- func BuiltInDefinitions() []interfaces.ShortcodeDefinition
- func NewNoOpService() interfaces.ShortcodeService
- func NewSanitizer() interfaces.ShortcodeSanitizer
- func RegisterBuiltIns(registry interfaces.ShortcodeRegistry, names []string) error
- type DefinitionValidator
- type Registry
- type Renderer
- type RendererOption
- type Service
- type ServiceOption
- func WithDefaultCache(cache interfaces.CacheProvider) ServiceOption
- func WithDefaultSanitizer(s interfaces.ShortcodeSanitizer) ServiceOption
- func WithLogger(logger interfaces.Logger) ServiceOption
- func WithMetrics(metrics interfaces.ShortcodeMetrics) ServiceOption
- func WithWordPressSyntax(enabled bool) ServiceOption
- type Validator
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrDuplicateDefinition = internal.ErrDuplicateDefinition ErrInvalidDefinition = internal.ErrInvalidDefinition ErrUnknownParameter = internal.ErrUnknownParameter ErrMissingParameter = internal.ErrMissingParameter ErrParameterType = internal.ErrParameterType )
Functions ¶
func BuiltInDefinitions ¶
func BuiltInDefinitions() []interfaces.ShortcodeDefinition
func NewNoOpService ¶
func NewNoOpService() interfaces.ShortcodeService
func NewSanitizer ¶
func NewSanitizer() interfaces.ShortcodeSanitizer
func RegisterBuiltIns ¶
func RegisterBuiltIns(registry interfaces.ShortcodeRegistry, names []string) error
Types ¶
type DefinitionValidator ¶
type DefinitionValidator = internal.DefinitionValidator
type Registry ¶
func NewRegistry ¶
func NewRegistry(validator DefinitionValidator) *Registry
type Renderer ¶
func NewRenderer ¶
func NewRenderer(registry interfaces.ShortcodeRegistry, validator *Validator, opts ...RendererOption) *Renderer
type RendererOption ¶
type RendererOption = internal.RendererOption
func WithRendererCache ¶
func WithRendererCache(cache interfaces.CacheProvider) RendererOption
func WithRendererMetrics ¶
func WithRendererMetrics(metrics interfaces.ShortcodeMetrics) RendererOption
func WithRendererSanitizer ¶
func WithRendererSanitizer(s interfaces.ShortcodeSanitizer) RendererOption
type Service ¶
func NewService ¶
func NewService(registry interfaces.ShortcodeRegistry, renderer interfaces.ShortcodeRenderer, opts ...ServiceOption) *Service
type ServiceOption ¶
type ServiceOption = internal.ServiceOption
func WithDefaultCache ¶
func WithDefaultCache(cache interfaces.CacheProvider) ServiceOption
func WithDefaultSanitizer ¶
func WithDefaultSanitizer(s interfaces.ShortcodeSanitizer) ServiceOption
func WithLogger ¶
func WithLogger(logger interfaces.Logger) ServiceOption
func WithMetrics ¶
func WithMetrics(metrics interfaces.ShortcodeMetrics) ServiceOption
func WithWordPressSyntax ¶
func WithWordPressSyntax(enabled bool) ServiceOption
Click to show internal directories.
Click to hide internal directories.