Documentation
¶
Index ¶
- type AlignResult
- type BootstrapResult
- type Change
- type CommitResult
- type DriftResult
- type ExecutionLevel
- type Formatter
- type HumanFormatter
- func (f *HumanFormatter) FormatAlignResult(result AlignResult) (string, error)
- func (f *HumanFormatter) FormatBootstrapResult(result BootstrapResult) (string, error)
- func (f *HumanFormatter) FormatCommitResult(result CommitResult) (string, error)
- func (f *HumanFormatter) FormatPreviewResult(result PreviewResult) (string, error)
- type JSONFormatter
- func (f *JSONFormatter) FormatAlignResult(result AlignResult) (string, error)
- func (f *JSONFormatter) FormatBootstrapResult(result BootstrapResult) (string, error)
- func (f *JSONFormatter) FormatCommitResult(result CommitResult) (string, error)
- func (f *JSONFormatter) FormatPreviewResult(result PreviewResult) (string, error)
- type MarkdownFormatter
- func (f *MarkdownFormatter) FormatAlignResult(result AlignResult) (string, error)
- func (f *MarkdownFormatter) FormatBootstrapResult(result BootstrapResult) (string, error)
- func (f *MarkdownFormatter) FormatCommitResult(result CommitResult) (string, error)
- func (f *MarkdownFormatter) FormatPreviewResult(result PreviewResult) (string, error)
- type OutputFormat
- type PreviewResult
- type ResourceStatus
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AlignResult ¶
type AlignResult struct {
Success bool
DriftDetected bool
ActionsApplied int
Resources []ResourceStatus
Duration time.Duration
Error error
}
AlignResult represents the result of an align operation
type BootstrapResult ¶
type BootstrapResult struct {
Success bool
ProvidersInstalled []string
ResourceCount int
ModulesLoaded int
PolicyViolations []policy.PolicyViolation
Duration time.Duration
Error error
}
BootstrapResult represents the result of a bootstrap operation
type Change ¶
type Change struct {
Type string // create, update, delete
ResourceKind string
ResourceName string
Description string
}
Change represents a planned infrastructure change
type CommitResult ¶
type CommitResult struct {
Success bool
ResourcesApplied int
ExecutionLevels []ExecutionLevel
TotalDuration time.Duration
Error error
}
CommitResult represents the result of a commit operation
type DriftResult ¶
DriftResult represents drift detection results for a resource
type ExecutionLevel ¶
ExecutionLevel represents a level in the DAG execution
type Formatter ¶
type Formatter interface {
FormatBootstrapResult(result BootstrapResult) (string, error)
FormatPreviewResult(result PreviewResult) (string, error)
FormatCommitResult(result CommitResult) (string, error)
FormatAlignResult(result AlignResult) (string, error)
}
Formatter defines the interface for output formatters
func NewFormatter ¶
func NewFormatter(format OutputFormat) Formatter
NewFormatter creates a new formatter based on the specified format
type HumanFormatter ¶
type HumanFormatter struct{}
HumanFormatter implements the Formatter interface for human-readable output
func NewHumanFormatter ¶
func NewHumanFormatter() *HumanFormatter
NewHumanFormatter creates a new human-readable formatter
func (*HumanFormatter) FormatAlignResult ¶
func (f *HumanFormatter) FormatAlignResult(result AlignResult) (string, error)
FormatAlignResult formats an align result for human reading
func (*HumanFormatter) FormatBootstrapResult ¶
func (f *HumanFormatter) FormatBootstrapResult(result BootstrapResult) (string, error)
FormatBootstrapResult formats a bootstrap result for human reading
func (*HumanFormatter) FormatCommitResult ¶
func (f *HumanFormatter) FormatCommitResult(result CommitResult) (string, error)
FormatCommitResult formats a commit result for human reading
func (*HumanFormatter) FormatPreviewResult ¶
func (f *HumanFormatter) FormatPreviewResult(result PreviewResult) (string, error)
FormatPreviewResult formats a preview result for human reading
type JSONFormatter ¶
type JSONFormatter struct{}
JSONFormatter implements the Formatter interface for JSON output
func NewJSONFormatter ¶
func NewJSONFormatter() *JSONFormatter
NewJSONFormatter creates a new JSON formatter
func (*JSONFormatter) FormatAlignResult ¶
func (f *JSONFormatter) FormatAlignResult(result AlignResult) (string, error)
FormatAlignResult formats an align result as JSON
func (*JSONFormatter) FormatBootstrapResult ¶
func (f *JSONFormatter) FormatBootstrapResult(result BootstrapResult) (string, error)
FormatBootstrapResult formats a bootstrap result as JSON
func (*JSONFormatter) FormatCommitResult ¶
func (f *JSONFormatter) FormatCommitResult(result CommitResult) (string, error)
FormatCommitResult formats a commit result as JSON
func (*JSONFormatter) FormatPreviewResult ¶
func (f *JSONFormatter) FormatPreviewResult(result PreviewResult) (string, error)
FormatPreviewResult formats a preview result as JSON
type MarkdownFormatter ¶
type MarkdownFormatter struct{}
MarkdownFormatter implements the Formatter interface for Markdown output
func NewMarkdownFormatter ¶
func NewMarkdownFormatter() *MarkdownFormatter
NewMarkdownFormatter creates a new Markdown formatter
func (*MarkdownFormatter) FormatAlignResult ¶
func (f *MarkdownFormatter) FormatAlignResult(result AlignResult) (string, error)
FormatAlignResult formats an align result as Markdown
func (*MarkdownFormatter) FormatBootstrapResult ¶
func (f *MarkdownFormatter) FormatBootstrapResult(result BootstrapResult) (string, error)
FormatBootstrapResult formats a bootstrap result as Markdown
func (*MarkdownFormatter) FormatCommitResult ¶
func (f *MarkdownFormatter) FormatCommitResult(result CommitResult) (string, error)
FormatCommitResult formats a commit result as Markdown
func (*MarkdownFormatter) FormatPreviewResult ¶
func (f *MarkdownFormatter) FormatPreviewResult(result PreviewResult) (string, error)
FormatPreviewResult formats a preview result as Markdown
type OutputFormat ¶
type OutputFormat string
OutputFormat represents the supported output formats
const ( FormatHuman OutputFormat = "human" FormatJSON OutputFormat = "json" FormatMarkdown OutputFormat = "markdown" )
type PreviewResult ¶
type PreviewResult struct {
Success bool
ChangesCount int
Changes []Change
DriftResults []DriftResult
Duration time.Duration
Error error
}
PreviewResult represents the result of a preview operation