Documentation
¶
Index ¶
- Constants
- Variables
- func EnsureWidgetIds(def *models.DashboardDefinition)
- func FindWidget(def *models.DashboardDefinition, widgetId string) int
- func IsAllowedWidgetType(widgetType string) bool
- func MarshalDefinition(def *models.DashboardDefinition) ([]byte, error)
- func NewWidgetId() string
- func ParseDefinition(raw []byte) (*models.DashboardDefinition, error)
- func SupportedSchemaVersion(v int) bool
- func TruncateName(name string, maxRunes int) string
Constants ¶
View Source
const MaxWidgetConfigBytes = 32 * 1024
View Source
const MaxWidgetsPerDashboard = 100
View Source
const SchemaVersion = 1
Variables ¶
View Source
var AllowedWidgetTypes = []string{"line_chart", "area_chart", "stacked_area", "bar_chart", "single_value", "gauge", "table"}
View Source
var ErrUnsupportedSchemaVersion = errors.New("unsupported dashboard schemaVersion")
Functions ¶
func EnsureWidgetIds ¶
func EnsureWidgetIds(def *models.DashboardDefinition)
func FindWidget ¶
func FindWidget(def *models.DashboardDefinition, widgetId string) int
func IsAllowedWidgetType ¶
func MarshalDefinition ¶
func MarshalDefinition(def *models.DashboardDefinition) ([]byte, error)
func NewWidgetId ¶
func NewWidgetId() string
func ParseDefinition ¶
func ParseDefinition(raw []byte) (*models.DashboardDefinition, error)
func SupportedSchemaVersion ¶
func TruncateName ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.