providers

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Provider

type Provider interface {
	// Metadata
	Language() string
	Extensions() []string
	SupportedQueryTypes() []string

	// Core operations
	Query(source string, query core.AgentQuery) core.QueryResult
	Transform(source string, op core.TransformOp) core.TransformResult
	Validate(source string) ValidationResult

	// Observability
	Stats() Stats
}

Provider interface for language-specific implementations

type Registry

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

Registry manages all providers

func NewRegistry

func NewRegistry() *Registry

NewRegistry creates provider registry

func (*Registry) Get

func (r *Registry) Get(language string) (Provider, bool)

Get retrieves provider by language

func (*Registry) Languages added in v1.5.0

func (r *Registry) Languages() []string

Languages returns all registered language identifiers

func (*Registry) List added in v1.5.0

func (r *Registry) List() []Provider

List returns all providers

func (*Registry) Register

func (r *Registry) Register(provider Provider)

Register adds a provider

type Stats added in v1.5.0

type Stats struct {
	BorrowCount int64 `json:"borrow_count"`
	ReturnCount int64 `json:"return_count"`
	Active      int64 `json:"active"`
}

Stats captures parser-pool level metrics exposed by providers.

type ValidationResult

type ValidationResult struct {
	Valid  bool     `json:"valid"`
	Errors []string `json:"errors,omitempty"`
}

ValidationResult from syntax check

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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