github.com/cilium/cilium@v1.16.2/api/v1/models/cgroup_container_metadata.go (about) 1 // Code generated by go-swagger; DO NOT EDIT. 2 3 // Copyright Authors of Cilium 4 // SPDX-License-Identifier: Apache-2.0 5 6 package models 7 8 // This file was generated by the swagger tool. 9 // Editing this file might prove futile when you re-run the swagger generate command 10 11 import ( 12 "context" 13 14 "github.com/go-openapi/strfmt" 15 "github.com/go-openapi/swag" 16 ) 17 18 // CgroupContainerMetadata cgroup container metadata 19 // 20 // swagger:model CgroupContainerMetadata 21 type CgroupContainerMetadata struct { 22 23 // cgroup id 24 CgroupID uint64 `json:"cgroup-id,omitempty"` 25 26 // cgroup path 27 CgroupPath string `json:"cgroup-path,omitempty"` 28 } 29 30 // Validate validates this cgroup container metadata 31 func (m *CgroupContainerMetadata) Validate(formats strfmt.Registry) error { 32 return nil 33 } 34 35 // ContextValidate validates this cgroup container metadata based on context it is used 36 func (m *CgroupContainerMetadata) ContextValidate(ctx context.Context, formats strfmt.Registry) error { 37 return nil 38 } 39 40 // MarshalBinary interface implementation 41 func (m *CgroupContainerMetadata) MarshalBinary() ([]byte, error) { 42 if m == nil { 43 return nil, nil 44 } 45 return swag.WriteJSON(m) 46 } 47 48 // UnmarshalBinary interface implementation 49 func (m *CgroupContainerMetadata) UnmarshalBinary(b []byte) error { 50 var res CgroupContainerMetadata 51 if err := swag.ReadJSON(b, &res); err != nil { 52 return err 53 } 54 *m = res 55 return nil 56 }