Documentation
¶
Index ¶
- Constants
- func QueryErrorTypeToString(errorType uint32) string
- type Context
- type IterMode
- type Iterator
- type Language
- type LanguageError
- type Node
- func (n *Node) Child(index uint64) (*Node, error)
- func (n *Node) ChildCount() (uint64, error)
- func (n *Node) EndByte() (uint64, error)
- func (n *Node) IsError() (bool, error)
- func (n *Node) IsNull() (bool, error)
- func (n *Node) Kind() (string, error)
- func (n *Node) NamedChild(index uint64) (*Node, error)
- func (n *Node) NamedChildCount() (uint64, error)
- func (n *Node) StartByte() (uint64, error)
- func (n *Node) String() (string, error)
- type Parser
- type Query
- type QueryCapture
- type QueryCursor
- type QueryMatch
- type Tree
- type TreeSitter
- func (ts *TreeSitter) Language(name string) (*Language, error)
- func (ts *TreeSitter) NewIterator(n *Node, mode IterMode) *Iterator
- func (ts *TreeSitter) NewParser() (*Parser, error)
- func (ts *TreeSitter) NewQuery(pattern string, l *Language) (*Query, error)
- func (ts *TreeSitter) NewQueryCursor() (*QueryCursor, error)
Constants ¶
View Source
const ( QueryErrorNone uint32 = iota QueryErrorSyntax QueryErrorNodeType QueryErrorField QueryErrorCapture QueryErrorStructure QueryErrorLanguage )
View Source
const Version = "v0.24.7"
Variables ¶
This section is empty.
Functions ¶
func QueryErrorTypeToString ¶
Types ¶
type Iterator ¶
type Iterator struct {
// contains filtered or unexported fields
}
func NewNamedIterator ¶
type Language ¶
type Language struct {
// contains filtered or unexported fields
}
func NewLanguage ¶
func NewLanguage(l uint64, t *TreeSitter) *Language
type LanguageError ¶
type LanguageError struct {
// contains filtered or unexported fields
}
func (LanguageError) Error ¶
func (l LanguageError) Error() string
type Node ¶
type Node struct {
// contains filtered or unexported fields
}
func (*Node) ChildCount ¶
func (*Node) NamedChildCount ¶
type Parser ¶
type Parser struct {
// contains filtered or unexported fields
}
func (*Parser) GetLanguageVersion ¶
func (*Parser) SetLanguage ¶
type QueryCapture ¶
type QueryCursor ¶
type QueryCursor struct {
// contains filtered or unexported fields
}
func (QueryCursor) NextMatch ¶
func (qc QueryCursor) NextMatch() (*QueryMatch, bool, error)
type QueryMatch ¶
type QueryMatch struct {
ID uint32
PatternIndex uint16
Captures []QueryCapture
}
type TreeSitter ¶
type TreeSitter struct {
// contains filtered or unexported fields
}
func (*TreeSitter) NewIterator ¶
func (ts *TreeSitter) NewIterator(n *Node, mode IterMode) *Iterator
func (*TreeSitter) NewParser ¶
func (ts *TreeSitter) NewParser() (*Parser, error)
func (*TreeSitter) NewQuery ¶
func (ts *TreeSitter) NewQuery(pattern string, l *Language) (*Query, error)
func (*TreeSitter) NewQueryCursor ¶
func (ts *TreeSitter) NewQueryCursor() (*QueryCursor, error)
Source Files
¶
Click to show internal directories.
Click to hide internal directories.