Documentation
¶
Index ¶
- Constants
- type ReferenceCompletionCreator
- func (c ReferenceCompletionCreator) Add(value any)
- func (c *ReferenceCompletionCreator) AddWithKey(key string, data any)
- func (c ReferenceCompletionCreator) FindMatch(query string) []fuzzyfinder.Rank
- func (c ReferenceCompletionCreator) FindMatchAndCalcCompletionData(query string) []ReferenceCompletionItem
- func (c ReferenceCompletionCreator) FindNextLevel(query string) []fuzzyfinder.Rank
- func (c ReferenceCompletionCreator) FindNextLevelCompletionData(query string) []ReferenceCompletionItem
- type ReferenceCompletionDetails
- type ReferenceCompletionItem
- type ReferenceCompletionLookUp
Constants ¶
View Source
const ArrayStringValuePrefix = "Array"
View Source
const MapStringValuePrefix = "Map"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ReferenceCompletionCreator ¶
type ReferenceCompletionCreator struct {
PathMap map[string]ReferenceCompletionDetails
}
func NewReferenceCompletionCreator ¶
func NewReferenceCompletionCreator() ReferenceCompletionCreator
func (ReferenceCompletionCreator) Add ¶
func (c ReferenceCompletionCreator) Add(value any)
func (*ReferenceCompletionCreator) AddWithKey ¶
func (c *ReferenceCompletionCreator) AddWithKey(key string, data any)
func (ReferenceCompletionCreator) FindMatch ¶
func (c ReferenceCompletionCreator) FindMatch(query string) []fuzzyfinder.Rank
func (ReferenceCompletionCreator) FindMatchAndCalcCompletionData ¶
func (c ReferenceCompletionCreator) FindMatchAndCalcCompletionData(query string) []ReferenceCompletionItem
func (ReferenceCompletionCreator) FindNextLevel ¶
func (c ReferenceCompletionCreator) FindNextLevel(query string) []fuzzyfinder.Rank
FindNextLevel returns only the immediate next-level children matching the query. For "response." it returns ["response.body", "response.status", "response.headers"] rather than all descendants. This enables VS Code-style drill-down completion.
func (ReferenceCompletionCreator) FindNextLevelCompletionData ¶
func (c ReferenceCompletionCreator) FindNextLevelCompletionData(query string) []ReferenceCompletionItem
FindNextLevelCompletionData returns completion items for the next level only, with proper Kind detection and EndIndex set to the start of the segment name.
type ReferenceCompletionDetails ¶
type ReferenceCompletionDetails struct {
Count uint
}
type ReferenceCompletionItem ¶
type ReferenceCompletionItem struct {
Kind reference.ReferenceKind
/** End token of the string to be completed, i.e. 'body' in 'response.bo|dy' */
EndToken string
/** Index of the completion start in the end token, i.e. 2 in 'bo|dy' of 'response.bo|dy' */
EndIndex int32
/** Number of items when reference is a map or an array */
ItemCount *int32
/** Environment names when reference is a variable */
Environments []string
}
type ReferenceCompletionLookUp ¶
func NewReferenceCompletionLookup ¶
func NewReferenceCompletionLookup() ReferenceCompletionLookUp
func (ReferenceCompletionLookUp) Add ¶
func (c ReferenceCompletionLookUp) Add(value any)
func (ReferenceCompletionLookUp) AddWithKey ¶
func (c ReferenceCompletionLookUp) AddWithKey(key string, value any)
Click to show internal directories.
Click to hide internal directories.