Documentation ¶
Index ¶
- Constants
- func GetObjectType(object map[string]interface{}) workloadinterface.ObjectType
- func IsTypeRegoResponseVector(object map[string]interface{}) bool
- func IsTypeScanObject(object map[string]interface{}) bool
- func ListMapToMeta(resourceMap []map[string]interface{}) []workloadinterface.IMetadata
- func NewObject(object map[string]interface{}) workloadinterface.IMetadata
- type RegoResponseVectorObject
- func (obj *RegoResponseVectorObject) GetApiVersion() string
- func (obj *RegoResponseVectorObject) GetID() string
- func (obj *RegoResponseVectorObject) GetKind() string
- func (obj *RegoResponseVectorObject) GetName() string
- func (obj *RegoResponseVectorObject) GetNamespace() string
- func (obj *RegoResponseVectorObject) GetObject() map[string]interface{}
- func (obj *RegoResponseVectorObject) GetObjectType() workloadinterface.ObjectType
- func (obj *RegoResponseVectorObject) GetRelatedObjects() []workloadinterface.IMetadata
- func (obj *RegoResponseVectorObject) GetWorkload() map[string]interface{}
- func (obj *RegoResponseVectorObject) SetApiVersion(apiVersion string)
- func (obj *RegoResponseVectorObject) SetKind(kind string)
- func (obj *RegoResponseVectorObject) SetName(name string)
- func (obj *RegoResponseVectorObject) SetNamespace(namespace string)
- func (obj *RegoResponseVectorObject) SetObject(object map[string]interface{})
- func (obj *RegoResponseVectorObject) SetRelatedObjects(relatedObjects []map[string]interface{})
- func (obj *RegoResponseVectorObject) SetWorkload(object map[string]interface{})
- func (obj *RegoResponseVectorObject) ToString() string
- type ScanObject
- func (scanObject *ScanObject) GetApiVersion() string
- func (scanObject *ScanObject) GetID() string
- func (scanObject *ScanObject) GetKind() string
- func (scanObject *ScanObject) GetName() string
- func (scanObject *ScanObject) GetNamespace() string
- func (scanObject *ScanObject) GetObject() map[string]interface{}
- func (scanObject *ScanObject) GetObjectType() workloadinterface.ObjectType
- func (scanObject *ScanObject) GetWorkload() map[string]interface{}
- func (scanObject *ScanObject) SetApiVersion(apiVersion string)
- func (scanObject *ScanObject) SetKind(kind string)
- func (scanObject *ScanObject) SetName(name string)
- func (scanObject *ScanObject) SetNamespace(namespace string)
- func (scanObject *ScanObject) SetObject(object map[string]interface{})
- func (scanObject *ScanObject) SetWorkload(object map[string]interface{})
- type ScanObjectMetadata
Constants ¶
View Source
const RelatedObjectsKey string = "relatedObjects"
View Source
const TypeRegoResponseVectorObject workloadinterface.ObjectType = "regoResponse"
Variables ¶
This section is empty.
Functions ¶
func GetObjectType ¶
func GetObjectType(object map[string]interface{}) workloadinterface.ObjectType
func IsTypeScanObject ¶ added in v0.0.258
func ListMapToMeta ¶
func ListMapToMeta(resourceMap []map[string]interface{}) []workloadinterface.IMetadata
func NewObject ¶
func NewObject(object map[string]interface{}) workloadinterface.IMetadata
Returns the currect object that supports the IMetadata interface
Types ¶
type RegoResponseVectorObject ¶
type RegoResponseVectorObject struct {
// contains filtered or unexported fields
}
func NewRegoResponseVectorObject ¶
func NewRegoResponseVectorObject(object map[string]interface{}) *RegoResponseVectorObject
func NewRegoResponseVectorObjectFromBytes ¶
func NewRegoResponseVectorObjectFromBytes(object []byte) (*RegoResponseVectorObject, error)
func (*RegoResponseVectorObject) GetApiVersion ¶
func (obj *RegoResponseVectorObject) GetApiVersion() string
=================== Get ================================
func (*RegoResponseVectorObject) GetID ¶
func (obj *RegoResponseVectorObject) GetID() string
func (*RegoResponseVectorObject) GetKind ¶
func (obj *RegoResponseVectorObject) GetKind() string
func (*RegoResponseVectorObject) GetName ¶
func (obj *RegoResponseVectorObject) GetName() string
func (*RegoResponseVectorObject) GetNamespace ¶
func (obj *RegoResponseVectorObject) GetNamespace() string
func (*RegoResponseVectorObject) GetObject ¶
func (obj *RegoResponseVectorObject) GetObject() map[string]interface{}
func (*RegoResponseVectorObject) GetObjectType ¶
func (obj *RegoResponseVectorObject) GetObjectType() workloadinterface.ObjectType
func (*RegoResponseVectorObject) GetRelatedObjects ¶
func (obj *RegoResponseVectorObject) GetRelatedObjects() []workloadinterface.IMetadata
func (*RegoResponseVectorObject) GetWorkload ¶
func (obj *RegoResponseVectorObject) GetWorkload() map[string]interface{}
func (*RegoResponseVectorObject) SetApiVersion ¶
func (obj *RegoResponseVectorObject) SetApiVersion(apiVersion string)
func (*RegoResponseVectorObject) SetKind ¶
func (obj *RegoResponseVectorObject) SetKind(kind string)
func (*RegoResponseVectorObject) SetName ¶
func (obj *RegoResponseVectorObject) SetName(name string)
func (*RegoResponseVectorObject) SetNamespace ¶
func (obj *RegoResponseVectorObject) SetNamespace(namespace string)
=================== Set ================================
func (*RegoResponseVectorObject) SetObject ¶
func (obj *RegoResponseVectorObject) SetObject(object map[string]interface{})
func (*RegoResponseVectorObject) SetRelatedObjects ¶
func (obj *RegoResponseVectorObject) SetRelatedObjects(relatedObjects []map[string]interface{})
func (*RegoResponseVectorObject) SetWorkload ¶
func (obj *RegoResponseVectorObject) SetWorkload(object map[string]interface{})
func (*RegoResponseVectorObject) ToString ¶
func (obj *RegoResponseVectorObject) ToString() string
type ScanObject ¶ added in v0.0.258
type ScanObject struct { ApiVersion string `json:"apiVersion"` Kind string `json:"kind"` Metadata ScanObjectMetadata `json:"metadata"` }
A ScanObject represents a K8S object to be scanned
func NewScanObject ¶ added in v0.0.258
func NewScanObject(object map[string]interface{}) *ScanObject
NewScanObject construct a ScanObject from map[string]interface{}. If the map does not match the object, will return nil
func (*ScanObject) GetApiVersion ¶ added in v0.0.258
func (scanObject *ScanObject) GetApiVersion() string
func (*ScanObject) GetID ¶ added in v0.0.258
func (scanObject *ScanObject) GetID() string
func (*ScanObject) GetKind ¶ added in v0.0.258
func (scanObject *ScanObject) GetKind() string
func (*ScanObject) GetName ¶ added in v0.0.258
func (scanObject *ScanObject) GetName() string
func (*ScanObject) GetNamespace ¶ added in v0.0.258
func (scanObject *ScanObject) GetNamespace() string
func (*ScanObject) GetObject ¶ added in v0.0.258
func (scanObject *ScanObject) GetObject() map[string]interface{}
func (*ScanObject) GetObjectType ¶ added in v0.0.258
func (scanObject *ScanObject) GetObjectType() workloadinterface.ObjectType
func (*ScanObject) GetWorkload ¶ added in v0.0.258
func (scanObject *ScanObject) GetWorkload() map[string]interface{}
func (*ScanObject) SetApiVersion ¶ added in v0.0.258
func (scanObject *ScanObject) SetApiVersion(apiVersion string)
func (*ScanObject) SetKind ¶ added in v0.0.258
func (scanObject *ScanObject) SetKind(kind string)
func (*ScanObject) SetName ¶ added in v0.0.258
func (scanObject *ScanObject) SetName(name string)
func (*ScanObject) SetNamespace ¶ added in v0.0.258
func (scanObject *ScanObject) SetNamespace(namespace string)
func (*ScanObject) SetObject ¶ added in v0.0.258
func (scanObject *ScanObject) SetObject(object map[string]interface{})
func (*ScanObject) SetWorkload ¶ added in v0.0.258
func (scanObject *ScanObject) SetWorkload(object map[string]interface{})
type ScanObjectMetadata ¶ added in v0.0.258
type ScanObjectMetadata struct { Name string `json:"name"` Namespace string `json:"namespace,omitempty"` }
func (*ScanObjectMetadata) GetName ¶ added in v0.0.258
func (scanObjectMetadata *ScanObjectMetadata) GetName() string
func (*ScanObjectMetadata) GetNamespace ¶ added in v0.0.258
func (scanObjectMetadata *ScanObjectMetadata) GetNamespace() string
func (*ScanObjectMetadata) SetName ¶ added in v0.0.258
func (scanObjectMetadata *ScanObjectMetadata) SetName(name string)
func (*ScanObjectMetadata) SetNamespace ¶ added in v0.0.258
func (scanObjectMetadata *ScanObjectMetadata) SetNamespace(namespace string)
Click to show internal directories.
Click to hide internal directories.