workspace

package
v0.1.20 Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2026 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Completion

type Completion struct {
	Range common.Range
	Text  string
	Label string
	// contains filtered or unexported fields
}

func (Completion) Kind

func (c Completion) Kind() completion.Kind

type ConvMode

type ConvMode int
const (
	Strict ConvMode = iota
	Edge
	Approximate
)

type Doc

type Doc = *doc

func NewDoc

func NewDoc(file File) Doc

func (Doc) ApproximateTargetPos

func (d Doc) ApproximateTargetPos(enc common.Encoding, sourcePos common.Pos) (common.Pos, bool)

func (Doc) Assemble

func (d Doc) Assemble()

func (Doc) CheckTarget

func (d Doc) CheckTarget() (needsUpdate bool, err error)

func (Doc) Completions

func (d Doc) Completions(enc common.Encoding, pos common.Pos) (completions []Completion, complete bool)

func (Doc) Delete

func (d Doc) Delete()

func (Doc) Err

func (d Doc) Err() error

func (Doc) Format

func (d Doc) Format(enc common.Encoding) (Formatted, error)

func (Doc) GetDiag

func (d Doc) GetDiag() *ast.Node

func (Doc) GoxImportPos

func (d Doc) GoxImportPos(enc common.Encoding) (common.Pos, bool)

func (Doc) Hover

func (d Doc) Hover(enc common.Encoding, pos common.Pos) (message string, ran common.Range, ok bool)

func (Doc) Init

func (d Doc) Init()

func (Doc) Load

func (d Doc) Load() error

func (Doc) Name

func (d Doc) Name() string

func (Doc) Parse

func (d Doc) Parse() error

func (Doc) PrintTarget

func (d Doc) PrintTarget()

func (Doc) Save

func (d Doc) Save() error

func (Doc) SourceClose

func (d Doc) SourceClose()

func (Doc) SourceFile

func (d Doc) SourceFile() File

func (Doc) SourceIsOpened

func (d Doc) SourceIsOpened() bool

func (Doc) SourceOpen

func (d Doc) SourceOpen(version int32)

func (Doc) SourcePatch

func (d Doc) SourcePatch(enc common.Encoding, ran common.Range, content string) (bool, error)

func (Doc) SourcePos

func (d Doc) SourcePos(enc common.Encoding, targetPos common.Pos, mode ConvMode) (common.Pos, bool)

func (Doc) SourceRange

func (d Doc) SourceRange(enc common.Encoding, targetRange common.Range, mode ConvMode) (common.Range, bool)

func (Doc) SourceUpdate

func (d Doc) SourceUpdate(content string) (bool, error)

func (Doc) StoreDiag

func (d Doc) StoreDiag(a *ast.Node)

func (Doc) Symbols

func (d Doc) Symbols(enc common.Encoding) []Symbol

func (Doc) TargetClose

func (d Doc) TargetClose()

func (Doc) TargetContent

func (d Doc) TargetContent() string

func (Doc) TargetFile

func (d Doc) TargetFile() File

func (Doc) TargetIsOpened

func (d Doc) TargetIsOpened() bool

func (Doc) TargetOpen

func (d Doc) TargetOpen(version int32)

func (Doc) TargetPos

func (d Doc) TargetPos(enc common.Encoding, sourcePos common.Pos, mode ConvMode) (common.Pos, bool)

func (Doc) TargetRange

func (d Doc) TargetRange(enc common.Encoding, sourceRange common.Range, mode ConvMode) (common.Range, bool)

func (Doc) TargetWrite

func (d Doc) TargetWrite() error

type File

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

func NewFile

func NewFile(path string) (File, bool)

func NewFileFromURI

func NewFileFromURI(uri string) (File, bool)

func (File) Dir

func (f File) Dir() string

func (File) Exists

func (f File) Exists() bool

func (File) IsValid

func (f File) IsValid() bool

func (File) Kind

func (f File) Kind() FileKind

func (File) Name

func (f File) Name() string

func (File) Path

func (f File) Path() string

func (File) Remove

func (f File) Remove() error

func (File) Reverse

func (f File) Reverse() File

func (File) URI

func (f File) URI() string

func (File) ValidateTarget

func (f File) ValidateTarget(b []byte) (needsUpdate bool, err error)

type FileKind

type FileKind string
const (
	KindSource  FileKind = ".gox"
	KindTarget  FileKind = ".x.go"
	KindUnknown FileKind = ""
)

func (FileKind) Belongs

func (f FileKind) Belongs(path string) bool

func (FileKind) Revert

func (f FileKind) Revert() FileKind

func (FileKind) String

func (f FileKind) String() string

type Formatted

type Formatted struct {
	Text  string
	Range common.Range
}

type Manager

type Manager = *manager

func NewManager

func NewManager() Manager

type Symbol

type Symbol struct {
	Kind    symbol.Kind
	Name    string
	Range   common.Range
	Symbols []Symbol
}

Jump to

Keyboard shortcuts

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