Documentation
¶
Index ¶
Constants ¶
const ( ConnectionBlock = "connection" QueryBlock = "query" CheckBlock = "check" DashboardBlock = "dashboard" DatabaseBlock = "database" GeneralBlock = "general" TerminalBlock = "terminal" PluginBlock = "plugin" )
hcl options block types
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Check ¶ added in v0.20.0
type Check struct {
Output *string `hcl:"output" cty:"check_output"`
Separator *string `hcl:"separator" cty:"check_separator"`
Header *bool `hcl:"header" cty:"check_header"`
Timing *bool `hcl:"timing" cty:"check_timing"`
}
General
func (*Check) ConfigMap ¶ added in v0.20.0
ConfigMap creates a config map that can be merged with viper
func (*Check) Merge ¶ added in v0.20.0
Merge :: merge other options over the the top of this options object i.e. if a property is set in otherOptions, it takes precedence
func (*Check) SetBaseProperties ¶ added in v0.20.0
type Connection ¶
type Connection struct {
Cache *bool `hcl:"cache" json:"cache,omitempty"`
CacheTTL *int `hcl:"cache_ttl" json:"cache_ttl,omitempty"`
// legacy properties included for backwards compatibility with v0.13
LegacyCache *bool `json:"Cache,omitempty"`
LegacyCacheTTL *int `json:"CacheTTL,omitempty"`
}
Connection is a struct representing connection options json tags needed as this is stored in the connection state file
func (*Connection) ConfigMap ¶
func (c *Connection) ConfigMap() map[string]interface{}
func (*Connection) Equals ¶
func (c *Connection) Equals(other *Connection) bool
func (*Connection) Merge ¶
func (c *Connection) Merge(otherOptions Options)
Merge merges other options over the top of this options object i.e. if a property is set in otherOptions, it takes precedence
func (*Connection) MigrateLegacy ¶
func (c *Connection) MigrateLegacy()
MigrateLegacy migrates the legacy properties into new properties
func (*Connection) String ¶
func (c *Connection) String() string
type Database ¶
type Database struct {
Cache *bool `hcl:"cache"`
CacheMaxTtl *int `hcl:"cache_max_ttl"`
CacheMaxSizeMb *int `hcl:"cache_max_size_mb"`
Listen *string `hcl:"listen"`
Port *int `hcl:"port"`
SearchPath *string `hcl:"search_path"`
SearchPathPrefix *string `hcl:"search_path_prefix"`
StartTimeout *int `hcl:"start_timeout"`
}
type General ¶
type General struct {
UpdateCheck *string `hcl:"update_check"`
Telemetry *string `hcl:"telemetry"`
LogLevel *string `hcl:"log_level"`
MemoryMaxMb *int `hcl:"memory_max_mb"`
}
type GlobalDashboard ¶ added in v0.20.0
type GlobalDashboard struct {
// server settings
Port *int `hcl:"port"`
Listen *string `hcl:"listen"`
StartTimeout *int `hcl:"start_timeout"`
}
func (*GlobalDashboard) ConfigMap ¶ added in v0.20.0
func (d *GlobalDashboard) ConfigMap() map[string]interface{}
ConfigMap creates a config map that can be merged with viper
func (*GlobalDashboard) Merge ¶ added in v0.20.0
func (d *GlobalDashboard) Merge(otherOptions Options)
Merge :: merge other options over the the top of this options object i.e. if a property is set in otherOptions, it takes precedence
func (*GlobalDashboard) String ¶ added in v0.20.0
func (d *GlobalDashboard) String() string
type Plugin ¶ added in v0.21.0
type Plugin struct {
MemoryMaxMb *int `hcl:"memory_max_mb"`
}
func (*Plugin) ConfigMap ¶ added in v0.21.0
ConfigMap creates a config map that can be merged with viper
type Query ¶ added in v0.20.0
type Query struct {
Output *string `hcl:"output" cty:"query_output"`
Separator *string `hcl:"separator" cty:"query_separator"`
Header *bool `hcl:"header" cty:"query_header"`
Multi *bool `hcl:"multi" cty:"query_multi"`
Timing *bool `hcl:"timing" cty:"query_timing"`
AutoComplete *bool `hcl:"autocomplete" cty:"query_autocomplete"`
}
General
func (*Query) ConfigMap ¶ added in v0.20.0
ConfigMap creates a config map that can be merged with viper
func (*Query) Merge ¶ added in v0.20.0
Merge :: merge other options over the the top of this options object i.e. if a property is set in otherOptions, it takes precedence
func (*Query) SetBaseProperties ¶ added in v0.20.0
type Terminal ¶
type Terminal struct {
Output *string `hcl:"output"`
Separator *string `hcl:"separator"`
Header *bool `hcl:"header"`
Multi *bool `hcl:"multi"`
Timing *bool `hcl:"timing"`
SearchPath *string `hcl:"search_path"`
SearchPathPrefix *string `hcl:"search_path_prefix"`
Watch *bool `hcl:"watch"`
AutoComplete *bool `hcl:"autocomplete"`
}
type WorkspaceProfileDashboard ¶ added in v0.20.0
type WorkspaceProfileDashboard struct {
// workspace profile
Browser *bool `hcl:"browser" cty:"profile_dashboard_browser"`
}
func (*WorkspaceProfileDashboard) ConfigMap ¶ added in v0.20.0
func (d *WorkspaceProfileDashboard) ConfigMap() map[string]interface{}
ConfigMap creates a config map that can be merged with viper
func (*WorkspaceProfileDashboard) Merge ¶ added in v0.20.0
func (d *WorkspaceProfileDashboard) Merge(otherOptions Options)
Merge :: merge other options over the the top of this options object i.e. if a property is set in otherOptions, it takes precedence
func (*WorkspaceProfileDashboard) SetBaseProperties ¶ added in v0.20.0
func (t *WorkspaceProfileDashboard) SetBaseProperties(otherOptions Options)
func (*WorkspaceProfileDashboard) String ¶ added in v0.20.0
func (d *WorkspaceProfileDashboard) String() string