criterias

package
v0.0.0-...-e59334c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 28, 2020 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Age

type Age struct {
	Source      string `json:"source"`
	Direction   string `json:"direction"`
	Units       string `json:"units"`
	UnitCount   int    `json:"unit_count"`
	Timestring  string `json:"timestring,omitempty"`
	Field       string `json:"field,omitempty"`
	StatsResult string `json:"stats_result,omitempty"`
	// contains filtered or unexported fields
}

Age represents the age filter criteria

func (*Age) FillFromContainer

func (a *Age) FillFromContainer(container *gabs.Container) (Criteriable, error)

FillFromContainer implementation of the Criteriable interface

func (*Age) Include

func (bc *Age) Include() bool

Include returns whether or not an index should be included on the actionable list

func (*Age) Name

func (a *Age) Name() string

Name implementation of the Criteriable interface

func (*Age) Validate

func (a *Age) Validate() error

Validate implementation of the Criteriable interface

type Alias

type Alias struct {
	Aliases []string `json:"aliases"`
	// contains filtered or unexported fields
}

Alias represents the alias filter criteria

func (*Alias) FillFromContainer

func (a *Alias) FillFromContainer(container *gabs.Container) (Criteriable, error)

FillFromContainer implementation of the Criteriable interface

func (*Alias) Include

func (bc *Alias) Include() bool

Include returns whether or not an index should be included on the actionable list

func (*Alias) Name

func (a *Alias) Name() string

Name implementation of the Criteriable interface

func (*Alias) Validate

func (a *Alias) Validate() error

Validate implementation of the Criteriable interface

type Allocated

type Allocated struct {
	AllocationType string      `json:"allocation_type"`
	Key            string      `json:"key"`
	RawValue       interface{} `json:"value"`
	Value          string
	// contains filtered or unexported fields
}

Allocated represents the allocated filter criteria

func (*Allocated) FillFromContainer

func (a *Allocated) FillFromContainer(container *gabs.Container) (Criteriable, error)

FillFromContainer implementation of the Criteriable interface

func (*Allocated) Include

func (bc *Allocated) Include() bool

Include returns whether or not an index should be included on the actionable list

func (*Allocated) Name

func (a *Allocated) Name() string

Name implementation of the Criteriable interface

func (*Allocated) Validate

func (a *Allocated) Validate() error

Validate implementation of the Criteriable interface

type Builder

type Builder struct {
	// contains filtered or unexported fields
}

func NewBuilder

func NewBuilder() *Builder

NewBuilder returns a *Builder instance

func (*Builder) AggregateCriteria

func (b *Builder) AggregateCriteria() []Criteriable

func (*Builder) Build

func (b *Builder) Build(action string, filters []*gabs.Container) error

func (*Builder) Criteria

func (b *Builder) Criteria() []Criteriable

func (*Builder) IsEmpty

func (b *Builder) IsEmpty() bool

type Closed

type Closed struct {
	// contains filtered or unexported fields
}

Closed represents the closed filter cirteria

func (*Closed) FillFromContainer

func (c *Closed) FillFromContainer(container *gabs.Container) (Criteriable, error)

FillFromContainer implementation of the Criteriable interface

func (*Closed) Include

func (bc *Closed) Include() bool

Include returns whether or not an index should be included on the actionable list

func (*Closed) Name

func (c *Closed) Name() string

Name implementation of the Criteriable interface

func (*Closed) Validate

func (c *Closed) Validate() error

Validate implementation of the Criteriable interface

type Count

type Count struct {
	Count   int    `json:"count"`
	Pattern string `json:"pattern"`
	// contains filtered or unexported fields
}

Count represents the count filter criteria

func (*Count) FillFromContainer

func (c *Count) FillFromContainer(container *gabs.Container) (Criteriable, error)

FillFromContainer implementation of the Criteriable interface

func (*Count) GetField

func (bua *Count) GetField() string

GetField returns the Field property

func (*Count) GetReverse

func (bua *Count) GetReverse() bool

GetReverse return the Reverse property

func (*Count) GetSource

func (bua *Count) GetSource() string

GetSource returns the Source property

func (*Count) GetStatsResult

func (bua *Count) GetStatsResult() string

GetStatsResult returns the StatsResult property

func (*Count) GetStrictMode

func (bua *Count) GetStrictMode() bool

GetStrictMode returns the StrictMode property

func (*Count) GetTimestring

func (bua *Count) GetTimestring() string

GetTimestring returns the Timestring property

func (*Count) Name

func (c *Count) Name() string

Name implementation of the Criteriable interface

func (*Count) Validate

func (c *Count) Validate() error

Validate implementation of the Criteriable interface

type Criteriable

type Criteriable interface {
	Validate() error

	FillFromContainer(container *gabs.Container) (Criteriable, error)

	Name() string
}

type Empty

type Empty struct {
	// contains filtered or unexported fields
}

Empty representation of the empty filter criteria

func (*Empty) FillFromContainer

func (e *Empty) FillFromContainer(container *gabs.Container) (Criteriable, error)

FillFromContainer implementation of the Criteriable interface

func (*Empty) Include

func (bc *Empty) Include() bool

Include returns whether or not an index should be included on the actionable list

func (*Empty) Name

func (e *Empty) Name() string

Name implementation of the Criteriable interface

func (*Empty) Validate

func (e *Empty) Validate() error

Validate implementation of the Criteriable interface

type Forcemerged

type Forcemerged struct {
	MaxNumSegments int `json:"max_segments"`
	// contains filtered or unexported fields
}

Forcemerged representst the forcemerged filter criteria

func (*Forcemerged) FillFromContainer

func (f *Forcemerged) FillFromContainer(container *gabs.Container) (Criteriable, error)

FillFromContainer implementation of the Criteriable interface

func (*Forcemerged) Include

func (bc *Forcemerged) Include() bool

Include returns whether or not an index should be included on the actionable list

func (*Forcemerged) Name

func (f *Forcemerged) Name() string

Name implementation of the Criteriable interface

func (*Forcemerged) Validate

func (f *Forcemerged) Validate() error

Validate implementation of the Criteriable interface

type Kibana

type Kibana struct {
	// contains filtered or unexported fields
}

Kibana represents the kibana filter criteria

func (*Kibana) FillFromContainer

func (k *Kibana) FillFromContainer(container *gabs.Container) (Criteriable, error)

Kibana implementation of the Criteriable interface

func (*Kibana) Include

func (bc *Kibana) Include() bool

Include returns whether or not an index should be included on the actionable list

func (*Kibana) Name

func (k *Kibana) Name() string

Name implementation of the Criteriable interface

func (*Kibana) Validate

func (k *Kibana) Validate() error

Validate implementation of the Criteriable interface

type Pattern

type Pattern struct {
	Kind  string `json:"kind"`
	Value string `json:"value"`
	// contains filtered or unexported fields
}

Pattern represents the pattern filter criteria

func (*Pattern) FillFromContainer

func (p *Pattern) FillFromContainer(container *gabs.Container) (Criteriable, error)

FillFromContainer implementation of the Criteriable interface

func (*Pattern) Include

func (bc *Pattern) Include() bool

Include returns whether or not an index should be included on the actionable list

func (*Pattern) Name

func (p *Pattern) Name() string

Name implementation of the Criteriable interface

func (*Pattern) Validate

func (p *Pattern) Validate() error

Validate implementation of the Criteriable interface

type Sortable

type Sortable interface {
	GetField() string

	GetStatsResult() string

	GetReverse() bool

	GetTimestring() string

	GetSource() string

	GetStrictMode() bool
}

type Space

type Space struct {
	FeThresholdBehavior string `json:"fe_threshold_behavior"`
	DiskSpace           int    `json:"disk_space"`
	Units               string `json:"units"`
	// contains filtered or unexported fields
}

Space represents the space filter criteria

func (*Space) FillFromContainer

func (s *Space) FillFromContainer(container *gabs.Container) (Criteriable, error)

FillFromContainer implementation of the Criteriable interface

func (*Space) GetField

func (bua *Space) GetField() string

GetField returns the Field property

func (*Space) GetReverse

func (bua *Space) GetReverse() bool

GetReverse return the Reverse property

func (*Space) GetSource

func (bua *Space) GetSource() string

GetSource returns the Source property

func (*Space) GetStatsResult

func (bua *Space) GetStatsResult() string

GetStatsResult returns the StatsResult property

func (*Space) GetStrictMode

func (bua *Space) GetStrictMode() bool

GetStrictMode returns the StrictMode property

func (*Space) GetTimestring

func (bua *Space) GetTimestring() string

GetTimestring returns the Timestring property

func (*Space) Name

func (s *Space) Name() string

Name implementation of the Criteriable interface

func (*Space) Validate

func (s *Space) Validate() error

Validate implementation of the Criteriable interface

type State

type State struct {
	State string `json:"state"`
	// contains filtered or unexported fields
}

State represents the state filter criteria

func (*State) FillFromContainer

func (s *State) FillFromContainer(container *gabs.Container) (Criteriable, error)

FillFromContainer implementation of the Criteriable interface

func (*State) Include

func (bc *State) Include() bool

Include returns whether or not an index should be included on the actionable list

func (*State) Name

func (s *State) Name() string

Name implementation of the Criteriable interface

func (*State) Validate

func (s *State) Validate() error

Validate implementation of the Criteriable interface

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
⌂ 换网址