2023-01-20 03:41:35 -06:00
|
|
|
package pfs
|
|
|
|
|
|
|
|
import (
|
2024-03-21 05:11:29 -05:00
|
|
|
"cuelang.org/go/cue"
|
2023-01-20 03:41:35 -06:00
|
|
|
"cuelang.org/go/cue/ast"
|
|
|
|
)
|
|
|
|
|
|
|
|
// ParsedPlugin represents everything knowable about a single plugin from static
|
|
|
|
// analysis of its filesystem tree contents, as performed by [ParsePluginFS].
|
|
|
|
//
|
|
|
|
// Guarantees described in the below comments only exist for instances of this
|
|
|
|
// struct returned from [ParsePluginFS].
|
|
|
|
type ParsedPlugin struct {
|
|
|
|
// Properties contains the plugin's definition, as declared in plugin.json.
|
2024-03-07 04:09:19 -06:00
|
|
|
Properties Metadata
|
2024-03-21 05:11:29 -05:00
|
|
|
CueFile cue.Value
|
|
|
|
Variant SchemaInterface
|
2023-01-20 03:41:35 -06:00
|
|
|
|
|
|
|
// CUEImports lists the CUE import statements in the plugin's grafanaplugin CUE
|
|
|
|
// package, if any.
|
|
|
|
CUEImports []*ast.ImportSpec
|
|
|
|
}
|