Documentation ¶
Index ¶
- Constants
- func GenericTypeToBlockType[T modconfig.ModTreeItem]() string
- func NewBenchmark(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewControl(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboard(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardCard(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardCategory(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardChart(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardContainer(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardEdge(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardFlow(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardGraph(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardHierarchy(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardImage(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardInput(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardNode(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardTable(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardText(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDashboardWith(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDetection(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewDetectionBenchmark(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewModResources(mod *modconfig.Mod, sourceMaps ...modconfig.ModResources) modconfig.ModResources
- func NewQuery(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
- func NewRootBenchmarkWithChildren(mod *modconfig.Mod, children []modconfig.ModTreeItem) modconfig.HclResource
- func ResolveArgs(qp QueryProvider, runtimeArgs *QueryArgs) ([]any, error)
- type Benchmark
- func (b *Benchmark) CtyValue() (cty.Value, error)
- func (b *Benchmark) Diff(other *Benchmark) *modconfig.ModTreeItemDiffs
- func (b *Benchmark) Equals(other *Benchmark) bool
- func (b *Benchmark) GetChildControls() []*Control
- func (b *Benchmark) GetListData() *printers.RowData
- func (b *Benchmark) GetShowData() *printers.RowData
- func (b *Benchmark) OnDecoded(block *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
- func (b *Benchmark) SetBaseProperties()
- func (b *Benchmark) String() string
- func (b *Benchmark) WalkResources(resourceFunc func(resource modconfig.ModTreeItem) (bool, error)) error
- type Control
- func (c *Control) CtyValue() (cty.Value, error)
- func (c *Control) Diff(other *Control) *modconfig.ModTreeItemDiffs
- func (c *Control) Equals(other *Control) bool
- func (c *Control) GetParentNames() []string
- func (c *Control) GetShowData() *printers.RowData
- func (c *Control) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
- func (c *Control) SetBaseProperties()
- func (c *Control) String() string
- type Dashboard
- func (d *Dashboard) AddChild(child modconfig.ModTreeItem) hcl.Diagnostics
- func (d *Dashboard) CtyValue() (cty.Value, error)
- func (d *Dashboard) Diff(other *Dashboard) *modconfig.ModTreeItemDiffs
- func (d *Dashboard) Equals(other *Dashboard) bool
- func (d *Dashboard) GetInput(name string) (*DashboardInput, bool)
- func (d *Dashboard) GetInputs() map[string]*DashboardInput
- func (d *Dashboard) InitInputs() hcl.Diagnostics
- func (d *Dashboard) OnDecoded(block *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
- func (d *Dashboard) SetBaseProperties() hcl.Diagnostics
- func (d *Dashboard) ValidateRuntimeDependencies(workspace modconfig.ModResourcesProvider) error
- func (d *Dashboard) WalkResources(resourceFunc func(resource modconfig.HclResource) (bool, error)) error
- type DashboardCard
- func (c *DashboardCard) CtyValue() (cty.Value, error)
- func (c *DashboardCard) Diff(other *DashboardCard) *modconfig.ModTreeItemDiffs
- func (c *DashboardCard) Equals(other *DashboardCard) bool
- func (c *DashboardCard) GetDocumentation() string
- func (c *DashboardCard) GetShowData() *printers.RowData
- func (c *DashboardCard) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
- func (c *DashboardCard) SetBaseProperties()
- func (c *DashboardCard) ValidateQuery() hcl.Diagnostics
- type DashboardCategory
- func (c *DashboardCategory) CtyValue() (cty.Value, error)
- func (c *DashboardCategory) Diff(other *DashboardCategory) *modconfig.ModTreeItemDiffs
- func (c *DashboardCategory) Equals(other *DashboardCategory) bool
- func (c *DashboardCategory) OnDecoded(block *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
- func (c *DashboardCategory) SetBaseProperties()
- type DashboardCategoryFold
- type DashboardCategoryList
- type DashboardCategoryProperty
- type DashboardCategoryPropertyList
- type DashboardChart
- func (c *DashboardChart) CtyValue() (cty.Value, error)
- func (c *DashboardChart) Diff(other *DashboardChart) *modconfig.ModTreeItemDiffs
- func (c *DashboardChart) Equals(other *DashboardChart) bool
- func (c *DashboardChart) GetShowData() *printers.RowData
- func (c *DashboardChart) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
- func (c *DashboardChart) SetBaseProperties()
- type DashboardChartAxes
- type DashboardChartAxesX
- type DashboardChartAxesY
- type DashboardChartAxisTitle
- type DashboardChartLabels
- type DashboardChartLegend
- type DashboardChartSeries
- type DashboardChartSeriesList
- type DashboardChartSeriesPoint
- type DashboardContainer
- func (c *DashboardContainer) CtyValue() (cty.Value, error)
- func (c *DashboardContainer) Diff(other *DashboardContainer) *modconfig.ModTreeItemDiffs
- func (c *DashboardContainer) Equals(other *DashboardContainer) bool
- func (c *DashboardContainer) GetShowData() *printers.RowData
- func (c *DashboardContainer) OnDecoded(block *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
- func (c *DashboardContainer) WalkResources(resourceFunc func(resource modconfig.HclResource) (bool, error)) error
- type DashboardEdge
- func (e *DashboardEdge) CtyValue() (cty.Value, error)
- func (e *DashboardEdge) Diff(other *DashboardEdge) *modconfig.ModTreeItemDiffs
- func (e *DashboardEdge) Equals(other *DashboardEdge) bool
- func (e *DashboardEdge) GetDocumentation() string
- func (e *DashboardEdge) OnDecoded(_ *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
- func (e *DashboardEdge) SetBaseProperties()
- type DashboardEdgeList
- type DashboardFlow
- func (f *DashboardFlow) CtyValue() (cty.Value, error)
- func (f *DashboardFlow) Diff(other *DashboardFlow) *modconfig.ModTreeItemDiffs
- func (f *DashboardFlow) Equals(other *DashboardFlow) bool
- func (f *DashboardFlow) GetChildren() []modconfig.ModTreeItem
- func (f *DashboardFlow) GetShowData() *printers.RowData
- func (f *DashboardFlow) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
- func (f *DashboardFlow) SetBaseProperties()
- func (*DashboardFlow) ValidateQuery() hcl.Diagnostics
- type DashboardGraph
- func (g *DashboardGraph) CtyValue() (cty.Value, error)
- func (g *DashboardGraph) Diff(other *DashboardGraph) *modconfig.ModTreeItemDiffs
- func (g *DashboardGraph) Equals(other *DashboardGraph) bool
- func (g *DashboardGraph) GetChildren() []modconfig.ModTreeItem
- func (g *DashboardGraph) GetShowData() *printers.RowData
- func (g *DashboardGraph) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
- func (g *DashboardGraph) SetBaseProperties()
- type DashboardHierarchy
- func (h *DashboardHierarchy) CtyValue() (cty.Value, error)
- func (h *DashboardHierarchy) Diff(other *DashboardHierarchy) *modconfig.ModTreeItemDiffs
- func (h *DashboardHierarchy) Equals(other *DashboardHierarchy) bool
- func (h *DashboardHierarchy) GetChildren() []modconfig.ModTreeItem
- func (h *DashboardHierarchy) GetDocumentation() string
- func (h *DashboardHierarchy) GetShowData() *printers.RowData
- func (h *DashboardHierarchy) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
- func (h *DashboardHierarchy) SetBaseProperties()
- type DashboardImage
- func (i *DashboardImage) CtyValue() (cty.Value, error)
- func (i *DashboardImage) Diff(other *DashboardImage) *modconfig.ModTreeItemDiffs
- func (i *DashboardImage) Equals(other *DashboardImage) bool
- func (*DashboardImage) GetDocumentation() string
- func (i *DashboardImage) GetShowData() *printers.RowData
- func (*DashboardImage) GetType() string
- func (i *DashboardImage) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
- func (i *DashboardImage) SetBaseProperties()
- func (i *DashboardImage) ValidateQuery() hcl.Diagnostics
- type DashboardInput
- func (i *DashboardInput) Clone() *DashboardInput
- func (i *DashboardInput) CtyValue() (cty.Value, error)
- func (i *DashboardInput) DependsOnInput(changedInputName string) bool
- func (i *DashboardInput) Diff(other *DashboardInput) *modconfig.ModTreeItemDiffs
- func (i *DashboardInput) Equals(other *DashboardInput) bool
- func (i *DashboardInput) GetShowData() *printers.RowData
- func (i *DashboardInput) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
- func (i *DashboardInput) SetBaseProperties()
- func (i *DashboardInput) SetDashboard(dashboard *Dashboard)
- func (i *DashboardInput) ValidateQuery() hcl.Diagnostics
- type DashboardInputOption
- type DashboardLeafNode
- type DashboardLeafNodeImpl
- type DashboardNode
- func (n *DashboardNode) CtyValue() (cty.Value, error)
- func (n *DashboardNode) Diff(other *DashboardNode) *modconfig.ModTreeItemDiffs
- func (n *DashboardNode) Equals(other *DashboardNode) bool
- func (n *DashboardNode) OnDecoded(_ *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
- func (n *DashboardNode) SetBaseProperties()
- type DashboardNodeList
- type DashboardTable
- func (t *DashboardTable) CtyValue() (cty.Value, error)
- func (t *DashboardTable) Diff(other *DashboardTable) *modconfig.ModTreeItemDiffs
- func (t *DashboardTable) Equals(other *DashboardTable) bool
- func (*DashboardTable) GetDocumentation() string
- func (t *DashboardTable) GetShowData() *printers.RowData
- func (t *DashboardTable) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
- func (t *DashboardTable) SetBaseProperties()
- type DashboardTableColumn
- type DashboardTableColumnList
- type DashboardText
- func (t *DashboardText) CtyValue() (cty.Value, error)
- func (t *DashboardText) Diff(other *DashboardText) *modconfig.ModTreeItemDiffs
- func (t *DashboardText) Equals(other *DashboardText) bool
- func (*DashboardText) GetDocumentation() string
- func (t *DashboardText) GetShowData() *printers.RowData
- func (t *DashboardText) OnDecoded(*hcl.Block, modconfig.ModResourcesProvider) hcl.Diagnostics
- func (t *DashboardText) SetBaseProperties()
- type DashboardWith
- type Detection
- func (t *Detection) CtyValue() (cty.Value, error)
- func (t *Detection) Diff(other *Detection) *modconfig.ModTreeItemDiffs
- func (t *Detection) Equals(other *Detection) bool
- func (t *Detection) GetShowData() *printers.RowData
- func (t *Detection) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
- func (t *Detection) SetBaseProperties()
- type DetectionBenchmark
- func (d *DetectionBenchmark) CtyValue() (cty.Value, error)
- func (d *DetectionBenchmark) Diff(other *DetectionBenchmark) *modconfig.ModTreeItemDiffs
- func (d *DetectionBenchmark) Equals(other *DetectionBenchmark) bool
- func (d *DetectionBenchmark) GetListData() *printers.RowData
- func (d *DetectionBenchmark) GetShowData() *printers.RowData
- func (d *DetectionBenchmark) OnDecoded(block *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
- func (d *DetectionBenchmark) SetBaseProperties()
- func (d *DetectionBenchmark) WalkResources(resourceFunc func(resource modconfig.HclResource) (bool, error)) error
- type NodeAndEdgeProvider
- type NodeAndEdgeProviderImpl
- func (f *NodeAndEdgeProviderImpl) AddCategory(category *DashboardCategory) hcl.Diagnostics
- func (f *NodeAndEdgeProviderImpl) AddChild(child modconfig.HclResource) hcl.Diagnostics
- func (f *NodeAndEdgeProviderImpl) GetEdges() DashboardEdgeList
- func (f *NodeAndEdgeProviderImpl) GetNodes() DashboardNodeList
- func (f *NodeAndEdgeProviderImpl) SetEdges(edges DashboardEdgeList)
- func (f *NodeAndEdgeProviderImpl) SetNodes(nodes DashboardNodeList)
- type PowerpipeModResources
- func (m *PowerpipeModResources) AddMaps(sourceMaps ...modconfig.ModResources)
- func (m *PowerpipeModResources) AddReference(ref *modconfig.ResourceReference)
- func (m *PowerpipeModResources) AddResource(item modconfig.HclResource) hcl.Diagnostics
- func (m *PowerpipeModResources) AddSnapshots(snapshotPaths []string)
- func (m *PowerpipeModResources) Empty() bool
- func (m *PowerpipeModResources) Equals(o modconfig.ModResources) bool
- func (m *PowerpipeModResources) GetMods() map[string]*modconfig.Mod
- func (m *PowerpipeModResources) GetReferences() map[string]*modconfig.ResourceReference
- func (m *PowerpipeModResources) GetResource(parsedName *modconfig.ParsedResourceName) (resource modconfig.HclResource, found bool)
- func (m *PowerpipeModResources) GetVariables() map[string]*modconfig.Variable
- func (m *PowerpipeModResources) QueryProviders() []QueryProvider
- func (m *PowerpipeModResources) TopLevelResources() modconfig.ModResources
- func (m *PowerpipeModResources) WalkResources(resourceFunc func(item modconfig.HclResource) (bool, error)) error
- type Query
- type QueryArgs
- func (q *QueryArgs) AddPositionalArgVal(value any) error
- func (q *QueryArgs) ArgsStringList() []string
- func (q *QueryArgs) ConvertArgsList() ([]any, error)
- func (q *QueryArgs) Empty() bool
- func (q *QueryArgs) Equals(other *QueryArgs) bool
- func (q *QueryArgs) GetNamedArg(name string) (interface{}, bool, error)
- func (q *QueryArgs) GetPositionalArg(idx int) (interface{}, bool, error)
- func (q *QueryArgs) GetShowData() *printers.RowData
- func (q *QueryArgs) Merge(other *QueryArgs, source QueryProvider) (*QueryArgs, error)
- func (q *QueryArgs) SetArgList(argList []any) error
- func (q *QueryArgs) SetArgMap(argMap map[string]any) error
- func (q *QueryArgs) SetNamedArgVal(name string, value any) (err error)
- func (q *QueryArgs) SetPositionalArgVal(value any, idx int) (err error)
- func (q *QueryArgs) String() string
- func (q *QueryArgs) ToString(value any) (string, error)
- func (q *QueryArgs) Validate() error
- type QueryProvider
- type QueryProviderImpl
- func (q *QueryProviderImpl) ArgsInheritedFromBase() bool
- func (q *QueryProviderImpl) CtyValue() (cty.Value, error)
- func (q *QueryProviderImpl) Diff(other QueryProvider) *modconfig.ModTreeItemDiffs
- func (q *QueryProviderImpl) GetArgs() *QueryArgs
- func (b *QueryProviderImpl) GetNestedStructs() []modconfig.CtyValueProvider
- func (q *QueryProviderImpl) GetParams() []*modconfig.ParamDef
- func (q *QueryProviderImpl) GetQuery() *Query
- func (q *QueryProviderImpl) GetQueryProviderImpl() *QueryProviderImpl
- func (q *QueryProviderImpl) GetResolvedQuery(runtimeArgs *QueryArgs) (*modconfig.ResolvedQuery, error)
- func (q *QueryProviderImpl) GetSQL() *string
- func (q *QueryProviderImpl) GetShowData() *printers.RowData
- func (q *QueryProviderImpl) MergeParentArgs(queryProvider QueryProvider, parent QueryProvider) (diags hcl.Diagnostics)
- func (q *QueryProviderImpl) OnDecoded(block *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
- func (q *QueryProviderImpl) ParamsInheritedFromBase() bool
- func (q *QueryProviderImpl) RequiresExecution(queryProvider QueryProvider) bool
- func (q *QueryProviderImpl) SetArgs(args *QueryArgs)
- func (q *QueryProviderImpl) SetBaseProperties()
- func (q *QueryProviderImpl) SetParams(params []*modconfig.ParamDef)
- func (q *QueryProviderImpl) ValidateQuery() hcl.Diagnostics
- type RuntimeDependency
- type RuntimeDependencyProvider
- type RuntimeDependencyProviderImpl
- type WithProvider
- type WithProviderImpl
Constants ¶
const RuntimeDependencyDashboardScope = "self"
Variables ¶
This section is empty.
Functions ¶
func GenericTypeToBlockType ¶
func GenericTypeToBlockType[T modconfig.ModTreeItem]() string
GenericTypeToBlockType converts a resource type generic param into a block type NOTE special case handling for dashboard items
func NewBenchmark ¶
func NewBenchmark(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewControl ¶
func NewControl(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboard ¶
func NewDashboard(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardCard ¶
func NewDashboardCard(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardCategory ¶
func NewDashboardCategory(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardChart ¶
func NewDashboardChart(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardContainer ¶
func NewDashboardContainer(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardEdge ¶
func NewDashboardEdge(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardFlow ¶
func NewDashboardFlow(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardGraph ¶
func NewDashboardGraph(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardHierarchy ¶
func NewDashboardHierarchy(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardImage ¶
func NewDashboardImage(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardInput ¶
func NewDashboardInput(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardNode ¶
func NewDashboardNode(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardTable ¶
func NewDashboardTable(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardText ¶
func NewDashboardText(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDashboardWith ¶
func NewDashboardWith(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDetection ¶
func NewDetection(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewDetectionBenchmark ¶
func NewDetectionBenchmark(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewModResources ¶
func NewModResources(mod *modconfig.Mod, sourceMaps ...modconfig.ModResources) modconfig.ModResources
func NewQuery ¶
func NewQuery(block *hcl.Block, mod *modconfig.Mod, shortName string) modconfig.HclResource
func NewRootBenchmarkWithChildren ¶
func NewRootBenchmarkWithChildren(mod *modconfig.Mod, children []modconfig.ModTreeItem) modconfig.HclResource
func ResolveArgs ¶
func ResolveArgs(qp QueryProvider, runtimeArgs *QueryArgs) ([]any, error)
ResolveArgs resolves the argument values, falling back on defaults from param definitions in the source (if present) it returns the arg values as a csv string which can be used in a query invocation (the arg values and param defaults will already have been converted to postgres format)
Types ¶
type Benchmark ¶
type Benchmark struct { modconfig.ResourceWithMetadataImpl modconfig.ModTreeItemImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` // child names as NamedItem structs - used to allow setting children via the 'children' property ChildNames modconfig.NamedItemList `cty:"child_names" json:"-"` ChildNameStrings []string `cty:"child_name_strings" json:"children,omitempty"` // dashboard specific properties Inputs []*DashboardInput `cty:"inputs" json:"inputs,omitempty"` Base *Benchmark `hcl:"base" json:"-"` }
Benchmark is a struct representing the Benchmark resource
func (*Benchmark) GetChildControls ¶
GetChildControls return a flat list of controls underneath the benchmark in the tree
func (*Benchmark) GetListData ¶
GetListData implements printers.Listable
func (*Benchmark) GetShowData ¶
GetShowData implements printers.Showable
func (*Benchmark) OnDecoded ¶
func (b *Benchmark) OnDecoded(block *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*Benchmark) SetBaseProperties ¶
func (b *Benchmark) SetBaseProperties()
func (*Benchmark) WalkResources ¶
type Control ¶
type Control struct { modconfig.ResourceWithMetadataImpl QueryProviderImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Severity *string `cty:"severity" hcl:"severity" snapshot:"severity" json:"severity,omitempty"` // dashboard specific properties Base *Control `hcl:"base" json:"-"` // contains filtered or unexported fields }
Control is a struct representing the Control resource
func (*Control) GetParentNames ¶
func (*Control) GetShowData ¶
GetShowData implements printers.Showable
func (*Control) OnDecoded ¶
func (c *Control) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*Control) SetBaseProperties ¶
func (c *Control) SetBaseProperties()
type Dashboard ¶
type Dashboard struct { modconfig.ResourceWithMetadataImpl modconfig.ModTreeItemImpl WithProviderImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Inputs []*DashboardInput `cty:"inputs" json:"inputs,omitempty"` UrlPath string `cty:"url_path" json:"url_path,omitempty"` Base *Dashboard `hcl:"base" json:"-"` // store children in a way which can be serialised via cty ChildNames []string `cty:"children" json:"children,omitempty"` // contains filtered or unexported fields }
Dashboard is a struct representing the Dashboard resource
func NewQueryDashboard ¶
func NewQueryDashboard(qp QueryProvider) (*Dashboard, error)
NewQueryDashboard creates a dashboard to wrap a query/control this is used for snapshot generation
func (*Dashboard) AddChild ¶
func (d *Dashboard) AddChild(child modconfig.ModTreeItem) hcl.Diagnostics
func (*Dashboard) GetInputs ¶
func (d *Dashboard) GetInputs() map[string]*DashboardInput
func (*Dashboard) InitInputs ¶
func (d *Dashboard) InitInputs() hcl.Diagnostics
func (*Dashboard) OnDecoded ¶
func (d *Dashboard) OnDecoded(block *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*Dashboard) SetBaseProperties ¶
func (d *Dashboard) SetBaseProperties() hcl.Diagnostics
func (*Dashboard) ValidateRuntimeDependencies ¶
func (d *Dashboard) ValidateRuntimeDependencies(workspace modconfig.ModResourcesProvider) error
func (*Dashboard) WalkResources ¶
type DashboardCard ¶
type DashboardCard struct { modconfig.ResourceWithMetadataImpl QueryProviderImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Label *string `cty:"label" hcl:"label" snapshot:"label" json:"label,omitempty"` Value *string `cty:"value" hcl:"value" snapshot:"value" json:"value,omitempty"` Icon *string `cty:"icon" hcl:"icon" snapshot:"icon" json:"icon,omitempty"` HREF *string `cty:"href" hcl:"href" snapshot:"href" json:"href,omitempty"` Base *DashboardCard `hcl:"base" json:"-"` }
DashboardCard is a struct representing a leaf dashboard node
func (*DashboardCard) CtyValue ¶
func (c *DashboardCard) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardCard) Diff ¶
func (c *DashboardCard) Diff(other *DashboardCard) *modconfig.ModTreeItemDiffs
func (*DashboardCard) Equals ¶
func (c *DashboardCard) Equals(other *DashboardCard) bool
func (*DashboardCard) GetDocumentation ¶
func (c *DashboardCard) GetDocumentation() string
GetDocumentation implements ModTreeItem
func (*DashboardCard) GetShowData ¶
func (c *DashboardCard) GetShowData() *printers.RowData
GetShowData implements printers.Showable
func (*DashboardCard) OnDecoded ¶
func (c *DashboardCard) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DashboardCard) SetBaseProperties ¶
func (c *DashboardCard) SetBaseProperties()
func (*DashboardCard) ValidateQuery ¶
func (c *DashboardCard) ValidateQuery() hcl.Diagnostics
ValidateQuery implements QueryProvider
type DashboardCategory ¶
type DashboardCategory struct { modconfig.ResourceWithMetadataImpl modconfig.ModTreeItemImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` // TACTICAL: include a title property (with a different name to the property in HclResourceImpl for clarity) // This is purely to ensure the title is included in the panel properties of snapshots // Note: this will be parsed from HCL, but we must set this explicitly in SetBaseProperties if there is a base CategoryTitle *string `cty:"title" hcl:"title" snapshot:"title" json:"-"` CategoryName string `snapshot:"name" json:"-"` Color *string `cty:"color" hcl:"color" snapshot:"color" json:"color,omitempty"` Depth *int `cty:"depth" hcl:"depth" snapshot:"depth" json:"depth,omitempty"` Icon *string `cty:"icon" hcl:"icon" snapshot:"icon" json:"icon,omitempty"` HREF *string `cty:"href" hcl:"href" snapshot:"href" json:"href,omitempty"` Fold *DashboardCategoryFold `cty:"fold" hcl:"fold,block" snapshot:"fold" json:"fold,omitempty"` PropertyList DashboardCategoryPropertyList `cty:"property_list" hcl:"property,block" json:"-"` Properties map[string]*DashboardCategoryProperty `cty:"properties" snapshot:"properties" json:"properties,omitempty"` PropertyOrder []string `cty:"property_order" hcl:"property_order,optional" snapshot:"property_order" json:"property_order,omitempty"` Base *DashboardCategory `hcl:"base" json:"base,omitempty"` }
func (*DashboardCategory) CtyValue ¶
func (c *DashboardCategory) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardCategory) Diff ¶
func (c *DashboardCategory) Diff(other *DashboardCategory) *modconfig.ModTreeItemDiffs
func (*DashboardCategory) Equals ¶
func (c *DashboardCategory) Equals(other *DashboardCategory) bool
func (*DashboardCategory) OnDecoded ¶
func (c *DashboardCategory) OnDecoded(block *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DashboardCategory) SetBaseProperties ¶
func (c *DashboardCategory) SetBaseProperties()
type DashboardCategoryFold ¶
type DashboardCategoryFold struct { Title *string `cty:"title" hcl:"title" snapshot:"title" json:"title,omitempty"` Threshold *int `cty:"threshold" hcl:"threshold" snapshot:"threshold" json:"threshold,omitempty"` Icon *string `cty:"icon" hcl:"icon" snapshot:"icon" json:"icon,omitempty"` }
func (DashboardCategoryFold) Equals ¶
func (f DashboardCategoryFold) Equals(other *DashboardCategoryFold) bool
type DashboardCategoryList ¶
type DashboardCategoryList []*DashboardCategory
func (*DashboardCategoryList) Merge ¶
func (c *DashboardCategoryList) Merge(other DashboardCategoryList)
type DashboardCategoryProperty ¶
type DashboardCategoryProperty struct { ShortName string `hcl:"name,label" snapshot:"name" json:"name"` Display *string `cty:"display" hcl:"display" snapshot:"display" json:"display,omitempty"` Wrap *string `cty:"wrap" hcl:"wrap" snapshot:"wrap" json:"wrap,omitempty"` HREF *string `cty:"href" hcl:"href" snapshot:"href" json:"href,omitempty"` }
func (DashboardCategoryProperty) Equals ¶
func (c DashboardCategoryProperty) Equals(other *DashboardCategoryProperty) bool
type DashboardCategoryPropertyList ¶
type DashboardCategoryPropertyList []*DashboardCategoryProperty
func (*DashboardCategoryPropertyList) Merge ¶
func (c *DashboardCategoryPropertyList) Merge(other DashboardCategoryPropertyList)
type DashboardChart ¶
type DashboardChart struct { modconfig.ResourceWithMetadataImpl QueryProviderImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Legend *DashboardChartLegend `cty:"legend" hcl:"legend,block" snapshot:"legend" json:"legend,omitempty"` SeriesList DashboardChartSeriesList `cty:"series_list" hcl:"series,block" json:"series,omitempty"` Axes *DashboardChartAxes `cty:"axes" hcl:"axes,block" snapshot:"axes" json:"axes,omitempty"` Grouping *string `cty:"grouping" hcl:"grouping" snapshot:"grouping" json:"grouping,omitempty"` Transform *string `cty:"transform" hcl:"transform" snapshot:"transform" json:"transform,omitempty"` Series map[string]*DashboardChartSeries `cty:"series" snapshot:"series"` Base *DashboardChart `hcl:"base" json:"-"` }
DashboardChart is a struct representing a leaf dashboard node
func (*DashboardChart) CtyValue ¶
func (c *DashboardChart) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardChart) Diff ¶
func (c *DashboardChart) Diff(other *DashboardChart) *modconfig.ModTreeItemDiffs
func (*DashboardChart) Equals ¶
func (c *DashboardChart) Equals(other *DashboardChart) bool
func (*DashboardChart) GetShowData ¶
func (c *DashboardChart) GetShowData() *printers.RowData
GetShowData implements printers.Showable
func (*DashboardChart) OnDecoded ¶
func (c *DashboardChart) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DashboardChart) SetBaseProperties ¶
func (c *DashboardChart) SetBaseProperties()
type DashboardChartAxes ¶
type DashboardChartAxes struct { X *DashboardChartAxesX `cty:"x" hcl:"x,block" json:"x,omitempty"` Y *DashboardChartAxesY `cty:"y" hcl:"y,block" json:"y,omitempty"` }
func (*DashboardChartAxes) Equals ¶
func (a *DashboardChartAxes) Equals(other *DashboardChartAxes) bool
func (*DashboardChartAxes) Merge ¶
func (a *DashboardChartAxes) Merge(other *DashboardChartAxes)
type DashboardChartAxesX ¶
type DashboardChartAxesX struct { Title *DashboardChartAxisTitle `cty:"title" hcl:"title,block" json:"title,omitempty"` Labels *DashboardChartLabels `cty:"labels" hcl:"labels,block" json:"labels,omitempty"` Min *int `cty:"min" hcl:"min" json:"min,omitempty"` Max *int `cty:"max" hcl:"max" json:"max,omitempty"` }
func (*DashboardChartAxesX) Equals ¶
func (x *DashboardChartAxesX) Equals(other *DashboardChartAxesX) bool
func (*DashboardChartAxesX) Merge ¶
func (x *DashboardChartAxesX) Merge(other *DashboardChartAxesX)
type DashboardChartAxesY ¶
type DashboardChartAxesY struct { Title *DashboardChartAxisTitle `cty:"title" hcl:"title,block" json:"title,omitempty"` Labels *DashboardChartLabels `cty:"labels" hcl:"labels,block" json:"labels,omitempty"` Min *int `cty:"min" hcl:"min" json:"min,omitempty"` Max *int `cty:"max" hcl:"max" json:"max,omitempty"` }
func (*DashboardChartAxesY) Equals ¶
func (y *DashboardChartAxesY) Equals(other *DashboardChartAxesY) bool
func (*DashboardChartAxesY) Merge ¶
func (y *DashboardChartAxesY) Merge(other *DashboardChartAxesY)
type DashboardChartAxisTitle ¶
type DashboardChartAxisTitle struct { Display *string `cty:"display" hcl:"display" json:"display,omitempty"` Align *string `cty:"align" hcl:"align" json:"align,omitempty"` Value *string `cty:"value" hcl:"value" json:"value,omitempty"` }
func (*DashboardChartAxisTitle) Equals ¶
func (t *DashboardChartAxisTitle) Equals(other *DashboardChartAxisTitle) bool
func (*DashboardChartAxisTitle) Merge ¶
func (t *DashboardChartAxisTitle) Merge(other *DashboardChartAxisTitle)
type DashboardChartLabels ¶
type DashboardChartLabels struct { Display *string `cty:"display" hcl:"display" json:"display,omitempty"` Format *string `cty:"format" hcl:"format" json:"format,omitempty"` }
func (*DashboardChartLabels) Equals ¶
func (l *DashboardChartLabels) Equals(other *DashboardChartLabels) bool
func (*DashboardChartLabels) Merge ¶
func (l *DashboardChartLabels) Merge(other *DashboardChartLabels)
type DashboardChartLegend ¶
type DashboardChartLegend struct { Display *string `cty:"display" hcl:"display" json:"display,omitempty"` Position *string `cty:"position" hcl:"position" json:"position,omitempty"` }
func (*DashboardChartLegend) Equals ¶
func (l *DashboardChartLegend) Equals(other *DashboardChartLegend) bool
func (*DashboardChartLegend) Merge ¶
func (l *DashboardChartLegend) Merge(other *DashboardChartLegend)
type DashboardChartSeries ¶
type DashboardChartSeries struct { Name string `hcl:"name,label" json:"name"` Title *string `cty:"title" hcl:"title" json:"title,omitempty"` Color *string `cty:"color" hcl:"color" json:"color,omitempty"` Points map[string]*DashboardChartSeriesPoint `cty:"points" json:"points,omitempty"` PointsList []*DashboardChartSeriesPoint `hcl:"point,block" json:"-"` }
func (*DashboardChartSeries) Equals ¶
func (s *DashboardChartSeries) Equals(other *DashboardChartSeries) bool
func (*DashboardChartSeries) OnDecoded ¶
func (s *DashboardChartSeries) OnDecoded()
type DashboardChartSeriesList ¶
type DashboardChartSeriesList []*DashboardChartSeries
func (*DashboardChartSeriesList) Merge ¶
func (s *DashboardChartSeriesList) Merge(other DashboardChartSeriesList)
type DashboardChartSeriesPoint ¶
type DashboardChartSeriesPoint struct { Name string `hcl:"name,label" json:"-"` Color *string `cty:"color" hcl:"color" json:"color,omitempty"` }
func (DashboardChartSeriesPoint) Equals ¶
func (s DashboardChartSeriesPoint) Equals(other *DashboardChartSeriesPoint) bool
type DashboardContainer ¶
type DashboardContainer struct { modconfig.ResourceWithMetadataImpl modconfig.ModTreeItemImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Inputs []*DashboardInput `cty:"inputs" json:"inputs,omitempty"` // store children in a way which can be serialised via cty ChildNames []string `cty:"children" json:"children,omitempty"` }
DashboardContainer is a struct representing the Dashboard and Container resource
func (*DashboardContainer) CtyValue ¶
func (c *DashboardContainer) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardContainer) Diff ¶
func (c *DashboardContainer) Diff(other *DashboardContainer) *modconfig.ModTreeItemDiffs
func (*DashboardContainer) Equals ¶
func (c *DashboardContainer) Equals(other *DashboardContainer) bool
func (*DashboardContainer) GetShowData ¶
func (c *DashboardContainer) GetShowData() *printers.RowData
GetShowData implements printers.Showable
func (*DashboardContainer) OnDecoded ¶
func (c *DashboardContainer) OnDecoded(block *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DashboardContainer) WalkResources ¶
func (c *DashboardContainer) WalkResources(resourceFunc func(resource modconfig.HclResource) (bool, error)) error
type DashboardEdge ¶
type DashboardEdge struct { modconfig.ResourceWithMetadataImpl QueryProviderImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Category *DashboardCategory `cty:"category" hcl:"category" snapshot:"category" json:"category,omitempty"` Base *DashboardEdge `hcl:"base" json:"-"` }
DashboardEdge is a struct representing a leaf dashboard node
func (*DashboardEdge) CtyValue ¶
func (e *DashboardEdge) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardEdge) Diff ¶
func (e *DashboardEdge) Diff(other *DashboardEdge) *modconfig.ModTreeItemDiffs
func (*DashboardEdge) Equals ¶
func (e *DashboardEdge) Equals(other *DashboardEdge) bool
func (*DashboardEdge) GetDocumentation ¶
func (e *DashboardEdge) GetDocumentation() string
GetDocumentation implements DashboardLeafNode
func (*DashboardEdge) OnDecoded ¶
func (e *DashboardEdge) OnDecoded(_ *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DashboardEdge) SetBaseProperties ¶
func (e *DashboardEdge) SetBaseProperties()
type DashboardEdgeList ¶
type DashboardEdgeList []*DashboardEdge
func (*DashboardEdgeList) Contains ¶
func (l *DashboardEdgeList) Contains(other *DashboardEdge) bool
func (*DashboardEdgeList) Get ¶
func (l *DashboardEdgeList) Get(name string) *DashboardEdge
func (*DashboardEdgeList) Merge ¶
func (l *DashboardEdgeList) Merge(other DashboardEdgeList)
func (*DashboardEdgeList) Names ¶
func (l *DashboardEdgeList) Names() []string
type DashboardFlow ¶
type DashboardFlow struct { modconfig.ResourceWithMetadataImpl DashboardLeafNodeImpl // NOTE: we must have cty tag on at least one property otherwise gohcl.DecodeExpression panics NodeAndEdgeProviderImpl `cty:"node_and_edge_provider"` // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Base *DashboardFlow `hcl:"base" json:"-"` }
DashboardFlow is a struct representing a leaf dashboard node
func (*DashboardFlow) CtyValue ¶
func (f *DashboardFlow) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardFlow) Diff ¶
func (f *DashboardFlow) Diff(other *DashboardFlow) *modconfig.ModTreeItemDiffs
func (*DashboardFlow) Equals ¶
func (f *DashboardFlow) Equals(other *DashboardFlow) bool
func (*DashboardFlow) GetChildren ¶
func (f *DashboardFlow) GetChildren() []modconfig.ModTreeItem
TODO [node_reuse] Add DashboardLeafNodeImpl and move this there https://github.com/turbot/steampipe/issues/2926 GetChildren implements ModTreeItem
func (*DashboardFlow) GetShowData ¶
func (f *DashboardFlow) GetShowData() *printers.RowData
GetShowData implements printers.Showable
func (*DashboardFlow) OnDecoded ¶
func (f *DashboardFlow) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DashboardFlow) SetBaseProperties ¶
func (f *DashboardFlow) SetBaseProperties()
func (*DashboardFlow) ValidateQuery ¶
func (*DashboardFlow) ValidateQuery() hcl.Diagnostics
ValidateQuery implements QueryProvider
type DashboardGraph ¶
type DashboardGraph struct { modconfig.ResourceWithMetadataImpl DashboardLeafNodeImpl // NOTE: we must have cty tag on at least one property otherwise gohcl.DecodeExpression panics NodeAndEdgeProviderImpl `cty:"node_and_edge_provider"` // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Direction *string `cty:"direction" hcl:"direction" json:"direction,omitempty" snapshot:"direction"` Base *DashboardGraph `hcl:"base" json:"-"` }
DashboardGraph is a struct representing a leaf dashboard node
func (*DashboardGraph) CtyValue ¶
func (g *DashboardGraph) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardGraph) Diff ¶
func (g *DashboardGraph) Diff(other *DashboardGraph) *modconfig.ModTreeItemDiffs
func (*DashboardGraph) Equals ¶
func (g *DashboardGraph) Equals(other *DashboardGraph) bool
func (*DashboardGraph) GetChildren ¶
func (g *DashboardGraph) GetChildren() []modconfig.ModTreeItem
GetChildren implements ModTreeItem
func (*DashboardGraph) GetShowData ¶
func (g *DashboardGraph) GetShowData() *printers.RowData
GetShowData implements printers.Showable
func (*DashboardGraph) OnDecoded ¶
func (g *DashboardGraph) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DashboardGraph) SetBaseProperties ¶
func (g *DashboardGraph) SetBaseProperties()
type DashboardHierarchy ¶
type DashboardHierarchy struct { modconfig.ResourceWithMetadataImpl DashboardLeafNodeImpl // NOTE: we must have cty tag on at least one property otherwise gohcl.DecodeExpression panics NodeAndEdgeProviderImpl `cty:"node_and_edge_provider"` // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Base *DashboardHierarchy `hcl:"base" json:"-"` }
DashboardHierarchy is a struct representing a leaf dashboard node
func (*DashboardHierarchy) CtyValue ¶
func (h *DashboardHierarchy) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardHierarchy) Diff ¶
func (h *DashboardHierarchy) Diff(other *DashboardHierarchy) *modconfig.ModTreeItemDiffs
func (*DashboardHierarchy) Equals ¶
func (h *DashboardHierarchy) Equals(other *DashboardHierarchy) bool
func (*DashboardHierarchy) GetChildren ¶
func (h *DashboardHierarchy) GetChildren() []modconfig.ModTreeItem
GetChildren implements ModTreeItem
func (*DashboardHierarchy) GetDocumentation ¶
func (h *DashboardHierarchy) GetDocumentation() string
GetDocumentation implements ModTreeItem
func (*DashboardHierarchy) GetShowData ¶
func (h *DashboardHierarchy) GetShowData() *printers.RowData
GetShowData implements printers.Showable
func (*DashboardHierarchy) OnDecoded ¶
func (h *DashboardHierarchy) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DashboardHierarchy) SetBaseProperties ¶
func (h *DashboardHierarchy) SetBaseProperties()
type DashboardImage ¶
type DashboardImage struct { modconfig.ResourceWithMetadataImpl QueryProviderImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Src *string `cty:"src" hcl:"src" json:"src,omitempty" snapshot:"src"` Alt *string `cty:"alt" hcl:"alt" json:"alt,omitempty" snapshot:"alt"` Base *DashboardImage `hcl:"base" json:"-"` }
DashboardImage is a struct representing a leaf dashboard node
func (*DashboardImage) CtyValue ¶
func (i *DashboardImage) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardImage) Diff ¶
func (i *DashboardImage) Diff(other *DashboardImage) *modconfig.ModTreeItemDiffs
func (*DashboardImage) Equals ¶
func (i *DashboardImage) Equals(other *DashboardImage) bool
func (*DashboardImage) GetDocumentation ¶
func (*DashboardImage) GetDocumentation() string
GetDocumentation implements ModTreeItem
func (*DashboardImage) GetShowData ¶
func (i *DashboardImage) GetShowData() *printers.RowData
GetShowData implements printers.Showable
func (*DashboardImage) GetType ¶
func (*DashboardImage) GetType() string
GetType implements DashboardLeafNode
func (*DashboardImage) OnDecoded ¶
func (i *DashboardImage) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DashboardImage) SetBaseProperties ¶
func (i *DashboardImage) SetBaseProperties()
func (*DashboardImage) ValidateQuery ¶
func (i *DashboardImage) ValidateQuery() hcl.Diagnostics
ValidateQuery implements QueryProvider
type DashboardInput ¶
type DashboardInput struct { modconfig.ResourceWithMetadataImpl QueryProviderImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` DashboardName string `json:"dashboard,omitempty"` Label *string `cty:"label" hcl:"label" json:"label,omitempty" snapshot:"label"` Placeholder *string `cty:"placeholder" hcl:"placeholder" json:"placeholder,omitempty" snapshot:"placeholder"` Options []*DashboardInputOption `cty:"options" hcl:"option,block" json:"options,omitempty" snapshot:"options"` // tactical - exists purely so we can put "unqualified_name" in the snbapshot panel for the input // TODO remove when input names are refactored https://github.com/turbot/steampipe/issues/2863 InputName string `cty:"input_name" json:"unqualified_name" snapshot:"unqualified_name"` Base *DashboardInput `hcl:"base" json:"-"` // contains filtered or unexported fields }
DashboardInput is a struct representing a leaf dashboard node
func (*DashboardInput) Clone ¶
func (i *DashboardInput) Clone() *DashboardInput
TODO remove https://github.com/turbot/steampipe/issues/2864
func (*DashboardInput) CtyValue ¶
func (i *DashboardInput) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardInput) DependsOnInput ¶
func (i *DashboardInput) DependsOnInput(changedInputName string) bool
DependsOnInput returns whether this input has a runtime dependency on the given input¬
func (*DashboardInput) Diff ¶
func (i *DashboardInput) Diff(other *DashboardInput) *modconfig.ModTreeItemDiffs
func (*DashboardInput) Equals ¶
func (i *DashboardInput) Equals(other *DashboardInput) bool
func (*DashboardInput) GetShowData ¶
func (i *DashboardInput) GetShowData() *printers.RowData
GetShowData implements printers.Showable
func (*DashboardInput) OnDecoded ¶
func (i *DashboardInput) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DashboardInput) SetBaseProperties ¶
func (i *DashboardInput) SetBaseProperties()
func (*DashboardInput) SetDashboard ¶
func (i *DashboardInput) SetDashboard(dashboard *Dashboard)
SetDashboard sets the parent dashboard container
func (*DashboardInput) ValidateQuery ¶
func (i *DashboardInput) ValidateQuery() hcl.Diagnostics
ValidateQuery implements QueryProvider
type DashboardInputOption ¶
type DashboardInputOption struct { Name string `hcl:"name,label" json:"name" snapshot:"name"` Label *string `cty:"label" hcl:"label" json:"label,omitempty" snapshot:"label"` }
DashboardInputOption is a struct representing dashboard input option
func (DashboardInputOption) Equals ¶
func (o DashboardInputOption) Equals(other *DashboardInputOption) bool
type DashboardLeafNode ¶
type DashboardLeafNode interface { modconfig.ModTreeItem modconfig.ResourceWithMetadata GetDisplay() string GetType() string GetWidth() int }
DashboardLeafNode must be implemented by resources may be a leaf node in the dashboard execution tree
type DashboardLeafNodeImpl ¶
type DashboardLeafNodeImpl struct { DashboardLeafNodeRemain hcl.Body `hcl:",remain" json:"-"` Width *int `cty:"width" hcl:"width" json:"width,omitempty"` Type *string `cty:"type" hcl:"type" json:"type,omitempty"` Display *string `cty:"display" hcl:"display" json:"display,omitempty" snapshot:"display"` }
func (*DashboardLeafNodeImpl) GetDisplay ¶
func (d *DashboardLeafNodeImpl) GetDisplay() string
func (*DashboardLeafNodeImpl) GetType ¶
func (d *DashboardLeafNodeImpl) GetType() string
func (*DashboardLeafNodeImpl) GetWidth ¶
func (d *DashboardLeafNodeImpl) GetWidth() int
type DashboardNode ¶
type DashboardNode struct { modconfig.ResourceWithMetadataImpl QueryProviderImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Category *DashboardCategory `cty:"category" hcl:"category" json:"category,omitempty" snapshot:"category"` Base *DashboardNode `hcl:"base" json:"-"` }
DashboardNode is a struct representing a leaf dashboard node
func (*DashboardNode) CtyValue ¶
func (n *DashboardNode) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardNode) Diff ¶
func (n *DashboardNode) Diff(other *DashboardNode) *modconfig.ModTreeItemDiffs
func (*DashboardNode) Equals ¶
func (n *DashboardNode) Equals(other *DashboardNode) bool
func (*DashboardNode) OnDecoded ¶
func (n *DashboardNode) OnDecoded(_ *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource—
func (*DashboardNode) SetBaseProperties ¶
func (n *DashboardNode) SetBaseProperties()
type DashboardNodeList ¶
type DashboardNodeList []*DashboardNode
func (*DashboardNodeList) Contains ¶
func (l *DashboardNodeList) Contains(other *DashboardNode) bool
func (*DashboardNodeList) Get ¶
func (l *DashboardNodeList) Get(name string) *DashboardNode
func (*DashboardNodeList) Merge ¶
func (l *DashboardNodeList) Merge(other DashboardNodeList)
func (*DashboardNodeList) Names ¶
func (l *DashboardNodeList) Names() []string
type DashboardTable ¶
type DashboardTable struct { modconfig.ResourceWithMetadataImpl QueryProviderImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` ColumnList DashboardTableColumnList `cty:"column_list" hcl:"column,block" json:"columns,omitempty"` Columns map[string]*DashboardTableColumn `cty:"columns" snapshot:"columns"` Base *DashboardTable `hcl:"base" json:"-"` }
DashboardTable is a struct representing a leaf dashboard node
func NewQueryDashboardTable ¶
func NewQueryDashboardTable(qp QueryProvider) (*DashboardTable, error)
NewQueryDashboardTable creates a Table to wrap a query. This is used in order to execute queries as dashboards
func (*DashboardTable) CtyValue ¶
func (t *DashboardTable) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardTable) Diff ¶
func (t *DashboardTable) Diff(other *DashboardTable) *modconfig.ModTreeItemDiffs
func (*DashboardTable) Equals ¶
func (t *DashboardTable) Equals(other *DashboardTable) bool
func (*DashboardTable) GetDocumentation ¶
func (*DashboardTable) GetDocumentation() string
GetDocumentation implements ModTreeItem
func (*DashboardTable) GetShowData ¶
func (t *DashboardTable) GetShowData() *printers.RowData
GetShowData implements printers.Showable
func (*DashboardTable) OnDecoded ¶
func (t *DashboardTable) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DashboardTable) SetBaseProperties ¶
func (t *DashboardTable) SetBaseProperties()
type DashboardTableColumn ¶
type DashboardTableColumn struct { Name string `hcl:"name,label" json:"name" snapshot:"name"` Display *string `cty:"display" hcl:"display" json:"display,omitempty" snapshot:"display"` Wrap *string `cty:"wrap" hcl:"wrap" json:"wrap,omitempty" snapshot:"wrap"` HREF *string `cty:"href" hcl:"href" json:"href,omitempty" snapshot:"href"` }
func (DashboardTableColumn) Equals ¶
func (c DashboardTableColumn) Equals(other *DashboardTableColumn) bool
type DashboardTableColumnList ¶
type DashboardTableColumnList []*DashboardTableColumn
func (*DashboardTableColumnList) Merge ¶
func (c *DashboardTableColumnList) Merge(other DashboardTableColumnList)
type DashboardText ¶
type DashboardText struct { modconfig.ResourceWithMetadataImpl modconfig.ModTreeItemImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Value *string `cty:"value" hcl:"value" snapshot:"value" json:"value,omitempty"` Base *DashboardText `hcl:"base" json:"-"` Mod *modconfig.Mod `cty:"mod" json:"-"` }
DashboardText is a struct representing a leaf dashboard node
func (*DashboardText) CtyValue ¶
func (t *DashboardText) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardText) Diff ¶
func (t *DashboardText) Diff(other *DashboardText) *modconfig.ModTreeItemDiffs
func (*DashboardText) Equals ¶
func (t *DashboardText) Equals(other *DashboardText) bool
func (*DashboardText) GetDocumentation ¶
func (*DashboardText) GetDocumentation() string
GetDocumentation implements ModTreeItem
func (*DashboardText) GetShowData ¶
func (t *DashboardText) GetShowData() *printers.RowData
GetShowData implements printers.Showable
func (*DashboardText) OnDecoded ¶
func (t *DashboardText) OnDecoded(*hcl.Block, modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DashboardText) SetBaseProperties ¶
func (t *DashboardText) SetBaseProperties()
type DashboardWith ¶
type DashboardWith struct { modconfig.ResourceWithMetadataImpl QueryProviderImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` }
DashboardWith is a struct representing a leaf dashboard node
func (*DashboardWith) CtyValue ¶
func (w *DashboardWith) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DashboardWith) Diff ¶
func (w *DashboardWith) Diff(other *DashboardWith) *modconfig.ModTreeItemDiffs
func (*DashboardWith) Equals ¶
func (w *DashboardWith) Equals(other *DashboardWith) bool
func (*DashboardWith) OnDecoded ¶
func (w *DashboardWith) OnDecoded(_ *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
type Detection ¶
type Detection struct { modconfig.ResourceWithMetadataImpl QueryProviderImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` Severity *string `cty:"severity" hcl:"severity" snapshot:"severity" json:"severity,omitempty"` DisplayColumns []string `cty:"display_columns" hcl:"display_columns,optional" snapshot:"display_columns" json:"display_columns,omitempty"` Base *Detection `hcl:"base" json:"-"` }
Detection is a struct representing a leaf dashboard node
func (*Detection) GetShowData ¶
GetShowData implements printers.Showable
func (*Detection) OnDecoded ¶
func (t *Detection) OnDecoded(block *hcl.Block, resourceMapProvider modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*Detection) SetBaseProperties ¶
func (t *Detection) SetBaseProperties()
type DetectionBenchmark ¶
type DetectionBenchmark struct { modconfig.ResourceWithMetadataImpl modconfig.ModTreeItemImpl DashboardLeafNodeImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` // store children in a way which can be serialised via cty ChildNames modconfig.NamedItemList `cty:"child_names" json:"-"` ChildNameStrings []string `cty:"child_name_strings" json:"children,omitempty"` // dashboard specific properties Inputs []*DashboardInput `cty:"inputs" json:"inputs,omitempty"` Base *DetectionBenchmark `hcl:"base" json:"-"` }
func NewWrapperDetectionBenchmark ¶
func NewWrapperDetectionBenchmark(detection *Detection) *DetectionBenchmark
NewWrapperDetectionBenchmark creates a new DetectionBenchmark to wrap a detection which we wish to execute
func (*DetectionBenchmark) CtyValue ¶
func (d *DetectionBenchmark) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*DetectionBenchmark) Diff ¶
func (d *DetectionBenchmark) Diff(other *DetectionBenchmark) *modconfig.ModTreeItemDiffs
func (*DetectionBenchmark) Equals ¶
func (d *DetectionBenchmark) Equals(other *DetectionBenchmark) bool
func (*DetectionBenchmark) GetListData ¶
func (d *DetectionBenchmark) GetListData() *printers.RowData
GetListData implements printers.Listable
func (*DetectionBenchmark) GetShowData ¶
func (d *DetectionBenchmark) GetShowData() *printers.RowData
GetShowData implements printers.Showable
func (*DetectionBenchmark) OnDecoded ¶
func (d *DetectionBenchmark) OnDecoded(block *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
func (*DetectionBenchmark) SetBaseProperties ¶
func (d *DetectionBenchmark) SetBaseProperties()
func (*DetectionBenchmark) WalkResources ¶
func (d *DetectionBenchmark) WalkResources(resourceFunc func(resource modconfig.HclResource) (bool, error)) error
type NodeAndEdgeProvider ¶
type NodeAndEdgeProvider interface { QueryProvider WithProvider GetEdges() DashboardEdgeList SetEdges(DashboardEdgeList) GetNodes() DashboardNodeList SetNodes(DashboardNodeList) AddCategory(category *DashboardCategory) hcl.Diagnostics AddChild(child modconfig.HclResource) hcl.Diagnostics }
NodeAndEdgeProvider must be implemented by any dashboard leaf node which supports edges and nodes (DashboardGraph, DashboardFlow, DashboardHierarchy) TODO [node_reuse] add NodeAndEdgeProviderImpl https://github.com/turbot/steampipe/issues/2918
type NodeAndEdgeProviderImpl ¶
type NodeAndEdgeProviderImpl struct { WithProviderImpl QueryProviderImpl NodeEdgeProviderRemain hcl.Body `hcl:",remain" json:"-"` Nodes DashboardNodeList `cty:"node_list" json:"nodes,omitempty"` Edges DashboardEdgeList `cty:"edge_list" json:"edges,omitempty"` NodeNames []string `json:"-" snapshot:"nodes"` EdgeNames []string `json:"-" snapshot:"edges"` Categories map[string]*DashboardCategory `cty:"categories" json:"categories" snapshot:"categories"` }
func NewNodeAndEdgeProviderImpl ¶
func NewNodeAndEdgeProviderImpl(block *hcl.Block, mod *modconfig.Mod, name string) NodeAndEdgeProviderImpl
func (*NodeAndEdgeProviderImpl) AddCategory ¶
func (f *NodeAndEdgeProviderImpl) AddCategory(category *DashboardCategory) hcl.Diagnostics
AddCategory implements NodeAndEdgeProvider
func (*NodeAndEdgeProviderImpl) AddChild ¶
func (f *NodeAndEdgeProviderImpl) AddChild(child modconfig.HclResource) hcl.Diagnostics
AddChild implements NodeAndEdgeProvider
func (*NodeAndEdgeProviderImpl) GetEdges ¶
func (f *NodeAndEdgeProviderImpl) GetEdges() DashboardEdgeList
GetEdges implements NodeAndEdgeProvider
func (*NodeAndEdgeProviderImpl) GetNodes ¶
func (f *NodeAndEdgeProviderImpl) GetNodes() DashboardNodeList
GetNodes implements NodeAndEdgeProvider
func (*NodeAndEdgeProviderImpl) SetEdges ¶
func (f *NodeAndEdgeProviderImpl) SetEdges(edges DashboardEdgeList)
SetEdges implements NodeAndEdgeProvider
func (*NodeAndEdgeProviderImpl) SetNodes ¶
func (f *NodeAndEdgeProviderImpl) SetNodes(nodes DashboardNodeList)
SetNodes implements NodeAndEdgeProvider
type PowerpipeModResources ¶
type PowerpipeModResources struct { // the parent mod Mod *modconfig.Mod Benchmarks map[string]*Benchmark Controls map[string]*Control Dashboards map[string]*Dashboard DashboardCategories map[string]*DashboardCategory DashboardCards map[string]*DashboardCard DashboardCharts map[string]*DashboardChart DashboardContainers map[string]*DashboardContainer DashboardEdges map[string]*DashboardEdge DashboardFlows map[string]*DashboardFlow DashboardGraphs map[string]*DashboardGraph DashboardHierarchies map[string]*DashboardHierarchy DashboardImages map[string]*DashboardImage DashboardInputs map[string]map[string]*DashboardInput DashboardTables map[string]*DashboardTable Detections map[string]*Detection DetectionBenchmarks map[string]*DetectionBenchmark DashboardTexts map[string]*DashboardText DashboardNodes map[string]*DashboardNode GlobalDashboardInputs map[string]*DashboardInput Locals map[string]*modconfig.Local Variables map[string]*modconfig.Variable // all mods (including deps) Mods map[string]*modconfig.Mod Queries map[string]*Query References map[string]*modconfig.ResourceReference // map of snapshot paths, keyed by snapshot name Snapshots map[string]string }
PowerpipeModResources is a struct containing maps of all mod resource types This is provided to avoid db needing to reference workspace package
func GetModResources ¶
func GetModResources(mod *modconfig.Mod) *PowerpipeModResources
func (*PowerpipeModResources) AddMaps ¶
func (m *PowerpipeModResources) AddMaps(sourceMaps ...modconfig.ModResources)
func (*PowerpipeModResources) AddReference ¶
func (m *PowerpipeModResources) AddReference(ref *modconfig.ResourceReference)
func (*PowerpipeModResources) AddResource ¶
func (m *PowerpipeModResources) AddResource(item modconfig.HclResource) hcl.Diagnostics
func (*PowerpipeModResources) AddSnapshots ¶
func (m *PowerpipeModResources) AddSnapshots(snapshotPaths []string)
func (*PowerpipeModResources) Empty ¶
func (m *PowerpipeModResources) Empty() bool
func (*PowerpipeModResources) Equals ¶
func (m *PowerpipeModResources) Equals(o modconfig.ModResources) bool
func (*PowerpipeModResources) GetMods ¶
func (m *PowerpipeModResources) GetMods() map[string]*modconfig.Mod
func (*PowerpipeModResources) GetReferences ¶
func (m *PowerpipeModResources) GetReferences() map[string]*modconfig.ResourceReference
func (*PowerpipeModResources) GetResource ¶
func (m *PowerpipeModResources) GetResource(parsedName *modconfig.ParsedResourceName) (resource modconfig.HclResource, found bool)
GetResource tries to find a resource with the given name in the PowerpipeModResources NOTE: this does NOT support inputs, which are NOT uniquely named in a mod
func (*PowerpipeModResources) GetVariables ¶
func (m *PowerpipeModResources) GetVariables() map[string]*modconfig.Variable
func (*PowerpipeModResources) QueryProviders ¶
func (m *PowerpipeModResources) QueryProviders() []QueryProvider
QueryProviders returns a slice of all QueryProviders
func (*PowerpipeModResources) TopLevelResources ¶
func (m *PowerpipeModResources) TopLevelResources() modconfig.ModResources
TopLevelResources returns a new PowerpipeModResources containing only top level resources (i.e. no dependencies)
func (*PowerpipeModResources) WalkResources ¶
func (m *PowerpipeModResources) WalkResources(resourceFunc func(item modconfig.HclResource) (bool, error)) error
WalkResources calls resourceFunc for every resource in the mod if any resourceFunc returns false or an error, return immediately
type Query ¶
type Query struct { modconfig.ResourceWithMetadataImpl QueryProviderImpl // required to allow partial decoding Remain hcl.Body `hcl:",remain" json:"-"` // only here as otherwise gocty.ImpliedType panics Unused string `cty:"unused" json:"-"` }
Query is a struct representing the Query resource
func (*Query) OnDecoded ¶
func (q *Query) OnDecoded(*hcl.Block, modconfig.ModResourcesProvider) hcl.Diagnostics
OnDecoded implements HclResource
type QueryArgs ¶
type QueryArgs struct { // NOTE: ArgMap and ArgList should not be set directly, but should be set using the // SetNamedArgVal and SetPositionalArgVal methods // This is so that stringNamedArgs and stringPositionalArgs can be set correctly ArgMap map[string]string `cty:"args" json:"args,omitempty"` // args list may be sparsely populated (in case of runtime dependencies) // so use *string ArgList []*string `cty:"args_list" json:"args_list,omitempty"` References []*modconfig.ResourceReference `cty:"refs" json:"refs,omitempty"` // contains filtered or unexported fields }
QueryArgs is a struct which contains the arguments used to invoke a query these may either be passed by name, in a map, or as a list of positional args NOTE: if both are present the named parameters are used
func MergeArgs ¶
func MergeArgs(queryProvider QueryProvider, runtimeArgs *QueryArgs) (*QueryArgs, error)
MergeArgs ensures base and runtime args are non nil and merges them into single args
func NewQueryArgs ¶
func NewQueryArgs() *QueryArgs
func (*QueryArgs) AddPositionalArgVal ¶
func (*QueryArgs) ArgsStringList ¶
ArgsStringList convert ArgLists into list of strings
func (*QueryArgs) ConvertArgsList ¶
ConvertArgsList convert ArgList into list of interface{} by unmarshalling
func (*QueryArgs) GetNamedArg ¶
func (*QueryArgs) GetPositionalArg ¶
func (*QueryArgs) GetShowData ¶
GetShowData implements printers.Showable
func (*QueryArgs) Merge ¶
func (q *QueryArgs) Merge(other *QueryArgs, source QueryProvider) (*QueryArgs, error)
Merge merges the other args with ourselves, creating and returning a new QueryArgs with the result NOTE: other has precedence
func (*QueryArgs) SetArgList ¶
func (*QueryArgs) SetNamedArgVal ¶
func (*QueryArgs) SetPositionalArgVal ¶
SetPositionalArgVal sets the value of a positional arg NOTE: we add by index so we can populate stringPositionalArgs if needed
type QueryProvider ¶
type QueryProvider interface { RuntimeDependencyProvider GetArgs() *QueryArgs GetParams() []*modconfig.ParamDef GetSQL() *string GetQuery() *Query SetArgs(*QueryArgs) SetParams([]*modconfig.ParamDef) GetResolvedQuery(*QueryArgs) (*modconfig.ResolvedQuery, error) RequiresExecution(QueryProvider) bool ValidateQuery() hcl.Diagnostics MergeParentArgs(QueryProvider, QueryProvider) hcl.Diagnostics GetQueryProviderImpl() *QueryProviderImpl ParamsInheritedFromBase() bool ArgsInheritedFromBase() bool }
QueryProvider must be implemented by resources which have query/sql
type QueryProviderImpl ¶
type QueryProviderImpl struct { RuntimeDependencyProviderImpl QueryProviderRemain hcl.Body `hcl:",remain" json:"-"` SQL *string `cty:"sql" hcl:"sql" json:"sql,omitempty"` Query *Query `cty:"query" hcl:"query" json:"-"` Args *QueryArgs `cty:"args" json:"args,omitempty"` Params []*modconfig.ParamDef `cty:"params" json:"params,omitempty"` QueryName *string `json:"query,omitempty"` // contains filtered or unexported fields }
func NewQueryProviderImpl ¶
func NewQueryProviderImpl(block *hcl.Block, mod *modconfig.Mod, shortName string) QueryProviderImpl
func (*QueryProviderImpl) ArgsInheritedFromBase ¶
func (q *QueryProviderImpl) ArgsInheritedFromBase() bool
ArgsInheritedFromBase implements QueryProvider determine whether our args were inherited from base resource
func (*QueryProviderImpl) CtyValue ¶
func (q *QueryProviderImpl) CtyValue() (cty.Value, error)
CtyValue implements CtyValueProvider
func (*QueryProviderImpl) Diff ¶
func (q *QueryProviderImpl) Diff(other QueryProvider) *modconfig.ModTreeItemDiffs
func (*QueryProviderImpl) GetArgs ¶
func (q *QueryProviderImpl) GetArgs() *QueryArgs
GetArgs implements QueryProvider
func (*QueryProviderImpl) GetNestedStructs ¶
func (b *QueryProviderImpl) GetNestedStructs() []modconfig.CtyValueProvider
func (*QueryProviderImpl) GetParams ¶
func (q *QueryProviderImpl) GetParams() []*modconfig.ParamDef
GetParams implements QueryProvider
func (*QueryProviderImpl) GetQuery ¶
func (q *QueryProviderImpl) GetQuery() *Query
GetQuery implements QueryProvider
func (*QueryProviderImpl) GetQueryProviderImpl ¶
func (q *QueryProviderImpl) GetQueryProviderImpl() *QueryProviderImpl
GetQueryProviderImpl implements QueryProvider
func (*QueryProviderImpl) GetResolvedQuery ¶
func (q *QueryProviderImpl) GetResolvedQuery(runtimeArgs *QueryArgs) (*modconfig.ResolvedQuery, error)
GetResolvedQuery return the SQL and args to run the query
func (*QueryProviderImpl) GetSQL ¶
func (q *QueryProviderImpl) GetSQL() *string
GetSQL implements QueryProvider
func (*QueryProviderImpl) GetShowData ¶
func (q *QueryProviderImpl) GetShowData() *printers.RowData
GetShowData implements printers.Showable
func (*QueryProviderImpl) MergeParentArgs ¶
func (q *QueryProviderImpl) MergeParentArgs(queryProvider QueryProvider, parent QueryProvider) (diags hcl.Diagnostics)
MergeParentArgs merges our args with our parent args (ours take precedence)
func (*QueryProviderImpl) OnDecoded ¶
func (q *QueryProviderImpl) OnDecoded(block *hcl.Block, _ modconfig.ModResourcesProvider) hcl.Diagnostics
func (*QueryProviderImpl) ParamsInheritedFromBase ¶
func (q *QueryProviderImpl) ParamsInheritedFromBase() bool
ParamsInheritedFromBase implements QueryProvider determine whether our params were inherited from base resource
func (*QueryProviderImpl) RequiresExecution ¶
func (q *QueryProviderImpl) RequiresExecution(queryProvider QueryProvider) bool
RequiresExecution implements QueryProvider
func (*QueryProviderImpl) SetArgs ¶
func (q *QueryProviderImpl) SetArgs(args *QueryArgs)
SetArgs implements QueryProvider
func (*QueryProviderImpl) SetBaseProperties ¶
func (q *QueryProviderImpl) SetBaseProperties()
func (*QueryProviderImpl) SetParams ¶
func (q *QueryProviderImpl) SetParams(params []*modconfig.ParamDef)
SetParams implements QueryProvider
func (*QueryProviderImpl) ValidateQuery ¶
func (q *QueryProviderImpl) ValidateQuery() hcl.Diagnostics
ValidateQuery implements QueryProvider returns an error if neither sql or query are set it is overridden by resource types for which sql is optional
type RuntimeDependency ¶
type RuntimeDependency struct { PropertyPath *modconfig.ParsedPropertyPath TargetPropertyName *string // TACTICAL the name of the parent property - either "args" or "param.<name>" ParentPropertyName string TargetPropertyIndex *int // TACTICAL - if set, wrap the dependency value in an array // this provides support for args which convert a runtime dependency to an array, like: // arns = [input.arn] IsArray bool // resource which provides has the dependency Provider modconfig.HclResource }
func (*RuntimeDependency) Equals ¶
func (d *RuntimeDependency) Equals(other *RuntimeDependency) bool
func (*RuntimeDependency) SourceResourceName ¶
func (d *RuntimeDependency) SourceResourceName() string
func (*RuntimeDependency) String ¶
func (d *RuntimeDependency) String() string
func (*RuntimeDependency) ValidateSource ¶
func (d *RuntimeDependency) ValidateSource(dashboard *Dashboard, workspace modconfig.ModResourcesProvider) error
type RuntimeDependencyProvider ¶
type RuntimeDependencyProvider interface { modconfig.ModTreeItem AddRuntimeDependencies([]*RuntimeDependency) GetRuntimeDependencies() map[string]*RuntimeDependency }
RuntimeDependencyProvider is implemented by all QueryProviders and Dashboard
type RuntimeDependencyProviderImpl ¶
type RuntimeDependencyProviderImpl struct { modconfig.ModTreeItemImpl // required to allow partial decoding RuntimeDependencyProviderRemain hcl.Body `hcl:",remain" json:"-"` // contains filtered or unexported fields }
func (*RuntimeDependencyProviderImpl) AddRuntimeDependencies ¶
func (b *RuntimeDependencyProviderImpl) AddRuntimeDependencies(dependencies []*RuntimeDependency)
func (*RuntimeDependencyProviderImpl) GetNestedStructs ¶
func (b *RuntimeDependencyProviderImpl) GetNestedStructs() []modconfig.CtyValueProvider
func (*RuntimeDependencyProviderImpl) GetRuntimeDependencies ¶
func (b *RuntimeDependencyProviderImpl) GetRuntimeDependencies() map[string]*RuntimeDependency
type WithProvider ¶
type WithProvider interface { AddWith(with *DashboardWith) hcl.Diagnostics GetWiths() []*DashboardWith GetWith(string) (*DashboardWith, bool) }
type WithProviderImpl ¶
type WithProviderImpl struct { // required to allow partial decoding WithProviderRemain hcl.Body `hcl:",remain" json:"-"` // contains filtered or unexported fields }
func (*WithProviderImpl) AddWith ¶
func (b *WithProviderImpl) AddWith(with *DashboardWith) hcl.Diagnostics
func (*WithProviderImpl) GetWith ¶
func (b *WithProviderImpl) GetWith(name string) (*DashboardWith, bool)
func (*WithProviderImpl) GetWiths ¶
func (b *WithProviderImpl) GetWiths() []*DashboardWith
Source Files ¶
- benchmark.go
- control.go
- dashboard.go
- dashboard_card.go
- dashboard_category.go
- dashboard_category_fold.go
- dashboard_category_helpers.go
- dashboard_category_list.go
- dashboard_category_property.go
- dashboard_category_property_list.go
- dashboard_chart.go
- dashboard_chart_axes.go
- dashboard_chart_labels.go
- dashboard_chart_legend.go
- dashboard_chart_series.go
- dashboard_chart_series_list.go
- dashboard_chart_series_point.go
- dashboard_container.go
- dashboard_edge.go
- dashboard_edge_list.go
- dashboard_flow.go
- dashboard_graph.go
- dashboard_hierarchy.go
- dashboard_image.go
- dashboard_input.go
- dashboard_leaf_node_impl.go
- dashboard_node.go
- dashboard_node_list.go
- dashboard_option.go
- dashboard_table.go
- dashboard_table_column.go
- dashboard_table_column_list.go
- dashboard_text.go
- dashboard_with.go
- detection.go
- detection_benchmark.go
- diffs.go
- generic_type.go
- interfaces.go
- mod_resources.go
- node_edge_provider_impl.go
- query.go
- query_args.go
- query_args_helpers.go
- query_provider_impl.go
- runtime_dependency.go
- runtime_dependency_provider_impl.go
- with_provider_impl.go