Documentation
¶
Index ¶
- type AdvancedQueries
- func (q *AdvancedQueries) Enable(val bool) *AdvancedQueries
- func (q *AdvancedQueries) WithDataFormat(f *Format) *AdvancedQueries
- func (q *AdvancedQueries) WithDataRateFormat(f *Format) *AdvancedQueries
- func (q *AdvancedQueries) WithNumberFormat(f *Format) *AdvancedQueries
- func (q *AdvancedQueries) WithNumberRateFormat(f *Format) *AdvancedQueries
- func (q *AdvancedQueries) WithPercentFormat(f *Format) *AdvancedQueries
- func (q *AdvancedQueries) WithTimeFormat(f *Format) *AdvancedQueries
- type AxesConfiguration
- type Base
- type Bottom
- type Dashboard
- type DisplayInfo
- type EventDisplaySettings
- type Format
- type FormatUnit
- type Layout
- type Left
- type LegendConfiguration
- type NumberThresholds
- type PanelType
- type Panels
- type QueryParams
- type Right
- type ScopeExpressionList
- type SharingMember
- type SharingOptions
- type TeamSharingOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdvancedQueries ¶
type AdvancedQueries struct {
Enabled bool `json:"enabled"`
DisplayInfo DisplayInfo `json:"displayInfo"`
Format Format `json:"format"`
Query string `json:"query"`
ID int `json:"id"`
ParentPanel *Panels `json:"-"`
}
func NewPromqlQuery ¶
func NewPromqlQuery(query string, parentPanel *Panels, displayInfo DisplayInfo) *AdvancedQueries
func (*AdvancedQueries) Enable ¶
func (q *AdvancedQueries) Enable(val bool) *AdvancedQueries
func (*AdvancedQueries) WithDataFormat ¶
func (q *AdvancedQueries) WithDataFormat(f *Format) *AdvancedQueries
func (*AdvancedQueries) WithDataRateFormat ¶
func (q *AdvancedQueries) WithDataRateFormat(f *Format) *AdvancedQueries
func (*AdvancedQueries) WithNumberFormat ¶
func (q *AdvancedQueries) WithNumberFormat(f *Format) *AdvancedQueries
func (*AdvancedQueries) WithNumberRateFormat ¶
func (q *AdvancedQueries) WithNumberRateFormat(f *Format) *AdvancedQueries
func (*AdvancedQueries) WithPercentFormat ¶
func (q *AdvancedQueries) WithPercentFormat(f *Format) *AdvancedQueries
func (*AdvancedQueries) WithTimeFormat ¶
func (q *AdvancedQueries) WithTimeFormat(f *Format) *AdvancedQueries
type AxesConfiguration ¶
type Dashboard ¶
type Dashboard struct {
Version int `json:"version,omitempty"`
CustomerID interface{} `json:"customerId"`
TeamID int `json:"teamId"`
Schema int `json:"schema"`
AutoCreated bool `json:"autoCreated"`
PublicToken string `json:"publicToken"`
ScopeExpressionList []*ScopeExpressionList `json:"scopeExpressionList"`
Layout []*Layout `json:"layout"`
TeamScope interface{} `json:"teamScope"`
EventDisplaySettings EventDisplaySettings `json:"eventDisplaySettings"`
ID int `json:"id,omitempty"`
Name string `json:"name"`
Description string `json:"description"`
Username string `json:"username"`
SharingSettings []*SharingOptions `json:"sharingSettings"`
Public bool `json:"public"`
Favorite bool `json:"favorite"`
CreatedOn int64 `json:"createdOn"`
ModifiedOn int64 `json:"modifiedOn"`
Panels []*Panels `json:"panels"`
TeamScopeExpressionList []interface{} `json:"teamScopeExpressionList"`
CreatedOnDate string `json:"createdOnDate"`
ModifiedOnDate string `json:"modifiedOnDate"`
TeamSharingOptions TeamSharingOptions `json:"teamSharingOptions"`
}
func DashboardFromJSON ¶
func NewDashboard ¶
type DisplayInfo ¶
type EventDisplaySettings ¶
type EventDisplaySettings struct {
Enabled bool `json:"enabled"`
QueryParams QueryParams `json:"queryParams"`
}
type Format ¶
type FormatUnit ¶
type FormatUnit string
const ( FormatUnitPercentage FormatUnit = "%" FormatUnitData FormatUnit = "byte" FormatUnitDataRate FormatUnit = "byteRate" FormatUnitNumber FormatUnit = "number" FormatUnitNumberRate FormatUnit = "numberRate" FormatUnitTime FormatUnit = "relativeTime" )
type Left ¶
type Left struct {
Enabled bool `json:"enabled"`
DisplayName interface{} `json:"displayName"`
Unit string `json:"unit"`
DisplayFormat string `json:"displayFormat"`
Decimals interface{} `json:"decimals"`
MinValue int `json:"minValue"`
MaxValue interface{} `json:"maxValue"`
MinInputFormat string `json:"minInputFormat"`
MaxInputFormat string `json:"maxInputFormat"`
Scale string `json:"scale"`
}
type LegendConfiguration ¶
type NumberThresholds ¶
type NumberThresholds struct {
Base Base `json:"base"`
Values []interface{} `json:"values"`
}
type Panels ¶
type Panels struct {
ID int `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
AxesConfiguration *AxesConfiguration `json:"axesConfiguration,omitempty"`
LegendConfiguration *LegendConfiguration `json:"legendConfiguration,omitempty"`
ApplyScopeToAll bool `json:"applyScopeToAll,omitempty"`
ApplySegmentationToAll bool `json:"applySegmentationToAll,omitempty"`
AdvancedQueries []*AdvancedQueries `json:"advancedQueries,omitempty"`
NumberThresholds *NumberThresholds `json:"numberThresholds,omitempty"`
MarkdownSource *string `json:"markdownSource,omitempty"`
PanelTitleVisible bool `json:"panelTitleVisible"`
TextAutosized bool `json:"textAutosized"`
TransparentBackground bool `json:"transparentBackground"`
Type PanelType `json:"type"`
// Just a helper to the client, the actual field is in Dashboard
Layout *Layout `json:"-"`
}
func (*Panels) AddQueries ¶
func (p *Panels) AddQueries(queries ...*AdvancedQueries) (*Panels, error)
type QueryParams ¶
type Right ¶
type Right struct {
Enabled bool `json:"enabled"`
DisplayName interface{} `json:"displayName"`
Unit string `json:"unit"`
DisplayFormat string `json:"displayFormat"`
Decimals interface{} `json:"decimals"`
MinValue int `json:"minValue"`
MaxValue interface{} `json:"maxValue"`
MinInputFormat string `json:"minInputFormat"`
MaxInputFormat string `json:"maxInputFormat"`
Scale string `json:"scale"`
}
type ScopeExpressionList ¶ added in v0.5.11
type SharingMember ¶ added in v0.5.30
type SharingOptions ¶ added in v0.5.30
type SharingOptions struct {
Member SharingMember `json:"member"`
Role string `json:"role"`
}
type TeamSharingOptions ¶
Click to show internal directories.
Click to hide internal directories.