languagefeatures

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2025 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BuiltInObjectsFeature

type BuiltInObjectsFeature struct {
	*GenericTemplateContextFeature
}

func NewBuiltInObjectsFeature

func NewBuiltInObjectsFeature(genericDocumentUseCase *GenericDocumentUseCase) *BuiltInObjectsFeature

func (*BuiltInObjectsFeature) AppropriateForNode

func (f *BuiltInObjectsFeature) AppropriateForNode() bool

func (*BuiltInObjectsFeature) Definition

func (f *BuiltInObjectsFeature) Definition() (result []lsp.Location, err error)

func (*BuiltInObjectsFeature) Hover

func (f *BuiltInObjectsFeature) Hover() (string, error)

func (*BuiltInObjectsFeature) References

func (f *BuiltInObjectsFeature) References() (result []lsp.Location, err error)

type CompletionUseCase

type CompletionUseCase interface {
	UseCase
	Completion() (result *lsp.CompletionList, err error)
}

type DefinitionUseCase

type DefinitionUseCase interface {
	UseCase
	Definition() (result []lsp.Location, err error)
}

type FunctionCallFeature

type FunctionCallFeature struct {
	*GenericDocumentUseCase
}

func NewFunctionCallFeature

func NewFunctionCallFeature(genericDocumentUseCase *GenericDocumentUseCase) *FunctionCallFeature

func (*FunctionCallFeature) AppropriateForNode

func (f *FunctionCallFeature) AppropriateForNode() bool

func (*FunctionCallFeature) Completion

func (f *FunctionCallFeature) Completion() (result *lsp.CompletionList, err error)

func (*FunctionCallFeature) Hover

func (f *FunctionCallFeature) Hover() (string, error)

type GenericDocumentUseCase

type GenericDocumentUseCase struct {
	Document       *document.TemplateDocument
	DocumentStore  *document.DocumentStore
	Chart          *charts.Chart
	Node           *sitter.Node
	ChartStore     *charts.ChartStore
	NodeType       string
	ParentNode     *sitter.Node
	ParentNodeType string
}

func (*GenericDocumentUseCase) NodeContent

func (u *GenericDocumentUseCase) NodeContent() string

type GenericTemplateContextFeature

type GenericTemplateContextFeature struct {
	*GenericDocumentUseCase
}

type HoverUseCase

type HoverUseCase interface {
	UseCase
	Hover() (result string, err error)
}

type IncludesCallFeature

type IncludesCallFeature struct {
	*IncludesFeature
}

func NewIncludesCallFeature

func NewIncludesCallFeature(genericDocumentUseCase *GenericDocumentUseCase) *IncludesCallFeature

func (*IncludesCallFeature) AppropriateForNode

func (f *IncludesCallFeature) AppropriateForNode() bool

should be called on {{ include "name" . }}

func (*IncludesCallFeature) Completion

func (f *IncludesCallFeature) Completion() (*lsp.CompletionList, error)

func (*IncludesCallFeature) Definition

func (f *IncludesCallFeature) Definition() (result []lsp.Location, err error)

func (*IncludesCallFeature) Hover

func (f *IncludesCallFeature) Hover() (string, error)

func (*IncludesCallFeature) References

func (f *IncludesCallFeature) References() (result []lsp.Location, err error)

type IncludesDefinitionFeature

type IncludesDefinitionFeature struct {
	*IncludesFeature
}

func NewIncludesDefinitionFeature

func NewIncludesDefinitionFeature(genericDocumentUseCase *GenericDocumentUseCase) *IncludesDefinitionFeature

func (*IncludesDefinitionFeature) AppropriateForNode

func (f *IncludesDefinitionFeature) AppropriateForNode() bool

should be called on {{ define "name" }}

func (*IncludesDefinitionFeature) References

func (f *IncludesDefinitionFeature) References() (result []lsp.Location, err error)

type IncludesFeature

type IncludesFeature struct {
	*GenericDocumentUseCase
}

type ReferencesUseCase

type ReferencesUseCase interface {
	UseCase
	References() (result []lsp.Location, err error)
}

type TemplateContextFeature

type TemplateContextFeature struct {
	*GenericTemplateContextFeature
}

func NewTemplateContextFeature

func NewTemplateContextFeature(genericDocumentUseCase *GenericDocumentUseCase) *TemplateContextFeature

func (*TemplateContextFeature) AppropriateForNode

func (f *TemplateContextFeature) AppropriateForNode() bool

func (*TemplateContextFeature) Completion

func (f *TemplateContextFeature) Completion() (*lsp.CompletionList, error)

func (*TemplateContextFeature) Definition

func (f *TemplateContextFeature) Definition() (result []lsp.Location, err error)

func (*TemplateContextFeature) Hover

func (f *TemplateContextFeature) Hover() (string, error)

func (*TemplateContextFeature) References

func (f *TemplateContextFeature) References() (result []lsp.Location, err error)

type TextFeature

type TextFeature struct {
	*GenericDocumentUseCase
	// contains filtered or unexported fields
}

func NewTextFeature

func NewTextFeature(
	ctx context.Context,
	genericDocumentUseCase *GenericDocumentUseCase,
	yamllsConnector *yamlls.Connector,
	textDocumentPosition *lsp.TextDocumentPositionParams,
) *TextFeature

func (*TextFeature) AppropriateForNode

func (f *TextFeature) AppropriateForNode() bool

func (*TextFeature) Completion

func (f *TextFeature) Completion() (result *lsp.CompletionList, err error)

type UseCase

type UseCase interface {
	AppropriateForNode() bool
}

interface for use cases

type VariablesFeature

type VariablesFeature struct {
	*GenericDocumentUseCase
}

func NewVariablesFeature

func NewVariablesFeature(genericDocumentUseCase *GenericDocumentUseCase) *VariablesFeature

func (*VariablesFeature) AppropriateForNode

func (f *VariablesFeature) AppropriateForNode() bool

func (*VariablesFeature) Completion added in v0.3.0

func (f *VariablesFeature) Completion() (result *lsp.CompletionList, err error)

func (*VariablesFeature) Definition

func (f *VariablesFeature) Definition() (result []lsp.Location, err error)

func (*VariablesFeature) References added in v0.0.18

func (f *VariablesFeature) References() (result []lsp.Location, err error)

Jump to

Keyboard shortcuts

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