Documentation ¶
Index ¶
- Variables
- type Column
- type Command
- type CommandState
- type ComponentPodsTable
- func (p *ComponentPodsTable) DecodeURLQuery() error
- func (p *ComponentPodsTable) EncodeURLQuery() error
- func (p *ComponentPodsTable) GenComponentState(component *cptype.Component) error
- func (p *ComponentPodsTable) Init(ctx servicehub.Context) error
- func (p *ComponentPodsTable) InitComponent(ctx context.Context)
- func (p *ComponentPodsTable) Render(ctx context.Context, component *cptype.Component, _ cptype.Scenario, ...) error
- func (p *ComponentPodsTable) RenderTable() error
- func (p *ComponentPodsTable) SetComponentValue(ctx context.Context)
- func (p *ComponentPodsTable) Transfer(component *cptype.Component)
- type Data
- type Item
- type Link
- type LinkOperation
- type Operation
- type Percent
- type Props
- type Sorter
- type State
- type Status
- type StyleConfig
- type Values
Constants ¶
This section is empty.
Variables ¶
View Source
var PodStatusToColor = map[string]string{
"Completed": "steelblue",
"ContainerCreating": "orange",
"CrashLoopBackOff": "red",
"Error": "maroon",
"Evicted": "darkgoldenrod",
"ImagePullBackOff": "darksalmon",
"Pending": "teal",
"Running": "green",
"Terminating": "brown",
}
Functions ¶
This section is empty.
Types ¶
type Command ¶
type Command struct { Key string `json:"key,omitempty"` Target string `json:"target,omitempty"` State CommandState `json:"state,omitempty"` JumpOut bool `json:"jumpOut"` }
type CommandState ¶
type ComponentPodsTable ¶
type ComponentPodsTable struct { base.DefaultProvider Type string `json:"type,omitempty"` State State `json:"state,omitempty"` Data Data `json:"data,omitempty"` Props Props `json:"props,omitempty"` Operations map[string]interface{} `json:"operations,omitempty"` // contains filtered or unexported fields }
func (*ComponentPodsTable) DecodeURLQuery ¶
func (p *ComponentPodsTable) DecodeURLQuery() error
func (*ComponentPodsTable) EncodeURLQuery ¶
func (p *ComponentPodsTable) EncodeURLQuery() error
func (*ComponentPodsTable) GenComponentState ¶
func (p *ComponentPodsTable) GenComponentState(component *cptype.Component) error
func (*ComponentPodsTable) Init ¶
func (p *ComponentPodsTable) Init(ctx servicehub.Context) error
func (*ComponentPodsTable) InitComponent ¶
func (p *ComponentPodsTable) InitComponent(ctx context.Context)
func (*ComponentPodsTable) Render ¶
func (p *ComponentPodsTable) Render(ctx context.Context, component *cptype.Component, _ cptype.Scenario, event cptype.ComponentEvent, gs *cptype.GlobalStateData) error
func (*ComponentPodsTable) RenderTable ¶
func (p *ComponentPodsTable) RenderTable() error
func (*ComponentPodsTable) SetComponentValue ¶
func (p *ComponentPodsTable) SetComponentValue(ctx context.Context)
func (*ComponentPodsTable) Transfer ¶
func (p *ComponentPodsTable) Transfer(component *cptype.Component)
type Item ¶
type Item struct { ID string `json:"id,omitempty"` Status Status `json:"status,omitempty"` Name Link `json:"name,omitempty"` Namespace string `json:"namespace,omitempty"` IP string `json:"ip,omitempty"` Age string `json:"age,omitempty"` CPURequests string `json:"cpuRequests,omitempty"` CPURequestsNum int64 `json:"CPURequestsNum,omitempty"` CPUPercent Percent `json:"cpuPercent,omitempty"` CPULimits string `json:"cpuLimits,omitempty"` CPULimitsNum int64 `json:"CPULimitsNum,omitempty"` MemoryRequests string `json:"memoryRequests,omitempty"` MemoryRequestsNum int64 `json:"MemoryRequestsNum,omitempty"` MemoryPercent Percent `json:"memoryPercent,omitempty"` MemoryLimits string `json:"memoryLimits,omitempty"` MemoryLimitsNum int64 `json:"MemoryLimitsNum,omitempty"` Ready string `json:"ready,omitempty"` Node string `json:"node,omitempty"` }
type LinkOperation ¶
type Props ¶
type Props struct { IsLoadMore bool `json:"isLoadMore,omitempty"` RowKey string `json:"rowKey,omitempty"` PageSizeOptions []string `json:"pageSizeOptions,omitempty"` Columns []Column `json:"columns,omitempty"` Operations map[string]interface{} `json:"operations,omitempty"` SortDirections []string `json:"sortDirections,omitempty"` }
type State ¶
type State struct { ClusterName string `json:"clusterName,omitempty"` CountValues map[string]int `json:"countValues"` PageNo int `json:"pageNo"` PageSize int `json:"pageSize"` Sorter Sorter `json:"sorterData,omitempty"` Total int `json:"total"` Values Values `json:"values,omitempty"` PodsTableURLQuery string `json:"podsTable__urlQuery,omitempty"` ActiveKey string `json:"activeKey,omitempty"` }
type Status ¶
type Status struct { RenderType string `json:"renderType,omitempty"` Value string `json:"value,omitempty"` StyleConfig StyleConfig `json:"styleConfig,omitempty"` }
type StyleConfig ¶
type StyleConfig struct {
Color string `json:"color,omitempty"`
}
Click to show internal directories.
Click to hide internal directories.