Documentation ¶
Index ¶
- Constants
- func ConvertHandler(items []unstructured.Unstructured, param *ConvertParam) ([]unstructured.Unstructured, error)
- func ConvertListToUnstructured(list interface{}) (unstructured.Unstructured, error)
- func ExactFilter(items []unstructured.Unstructured, exact map[string]sets.Set[string]) ([]unstructured.Unstructured, error)
- func FuzzyFilter(items []unstructured.Unstructured, fuzzy map[string][]string) ([]unstructured.Unstructured, error)
- func GetDeepFloat64(item unstructured.Unstructured, keyStr string) (value float64)
- func GetDeepValue(item interface{}, keyStr string) ([]string, error)
- func PageHandler(items []unstructured.Unstructured, limit int, offset int) ([]unstructured.Unstructured, error)
- func ParseJsonDataHandler(data []byte) (unstructuredObj *unstructured.Unstructured, err error)
- func SetDecoder(scheme *runtime.Scheme)
- func SortHandler(items []unstructured.Unstructured, param *SortParam) ([]unstructured.Unstructured, error)
- type Condition
- type ConvertParam
- type ConverterContext
- type Filter
- type InstallFunc
- type PageBean
- type SortParam
Constants ¶
View Source
const ( Labels = "labels" Annotations = "annotations" )
Variables ¶
This section is empty.
Functions ¶
func ConvertHandler ¶ added in v1.7.3
func ConvertHandler(items []unstructured.Unstructured, param *ConvertParam) ([]unstructured.Unstructured, error)
func ConvertListToUnstructured ¶ added in v1.9.0
func ConvertListToUnstructured(list interface{}) (unstructured.Unstructured, error)
func ExactFilter ¶ added in v1.7.3
func ExactFilter(items []unstructured.Unstructured, exact map[string]sets.Set[string]) ([]unstructured.Unstructured, error)
func FuzzyFilter ¶ added in v1.7.3
func FuzzyFilter(items []unstructured.Unstructured, fuzzy map[string][]string) ([]unstructured.Unstructured, error)
func GetDeepFloat64 ¶
func GetDeepFloat64(item unstructured.Unstructured, keyStr string) (value float64)
GetDeepFloat64 get float64 value by metadata.xx.xx.xx, multi level key
func GetDeepValue ¶
GetDeepValue get value by metadata.xx.xx.xx, multi level key
func PageHandler ¶ added in v1.7.3
func PageHandler(items []unstructured.Unstructured, limit int, offset int) ([]unstructured.Unstructured, error)
func ParseJsonDataHandler ¶ added in v1.7.3
func ParseJsonDataHandler(data []byte) (unstructuredObj *unstructured.Unstructured, err error)
func SetDecoder ¶ added in v1.7.6
func SortHandler ¶ added in v1.7.3
func SortHandler(items []unstructured.Unstructured, param *SortParam) ([]unstructured.Unstructured, error)
Types ¶
type Condition ¶ added in v1.7.3
type Condition struct { Exact map[string]sets.Set[string] Fuzzy map[string][]string Limit int Offset int SortName string SortOrder string SortFunc string }
func PageFilterOption ¶ added in v1.7.3
type ConvertParam ¶ added in v1.7.3
type ConvertParam struct {
// contains filtered or unexported fields
}
type ConverterContext ¶
type ConverterContext struct { EnableConvert bool RawGvr *schema.GroupVersionResource ConvertedGvr *schema.GroupVersionResource Converter *conversion.VersionConverter }
type Filter ¶
type Filter struct { Scheme *runtime.Scheme // ConverterContext holds methods to convert objects *ConverterContext }
Filter is the filter condition
func GetEmptyFilter ¶ added in v1.7.3
func GetEmptyFilter() *Filter
func NewFilter ¶ added in v1.7.3
func NewFilter( ctx *ConverterContext, installFunc ...InstallFunc) *Filter
func (*Filter) FilterObjectList ¶ added in v1.7.3
type InstallFunc ¶ added in v1.7.3
Click to show internal directories.
Click to hide internal directories.