github.com/kubearmor/cilium@v1.6.12/api/v1/models/address_pair.go (about) 1 // Code generated by go-swagger; DO NOT EDIT. 2 3 package models 4 5 // This file was generated by the swagger tool. 6 // Editing this file might prove futile when you re-run the swagger generate command 7 8 import ( 9 strfmt "github.com/go-openapi/strfmt" 10 11 "github.com/go-openapi/swag" 12 ) 13 14 // AddressPair Addressing information of an endpoint 15 // swagger:model AddressPair 16 type AddressPair struct { 17 18 // IPv4 address 19 IPV4 string `json:"ipv4,omitempty"` 20 21 // UUID of IPv4 expiration timer 22 IPV4ExpirationUUID string `json:"ipv4-expiration-uuid,omitempty"` 23 24 // IPv6 address 25 IPV6 string `json:"ipv6,omitempty"` 26 27 // UUID of IPv6 expiration timer 28 IPV6ExpirationUUID string `json:"ipv6-expiration-uuid,omitempty"` 29 } 30 31 // Validate validates this address pair 32 func (m *AddressPair) Validate(formats strfmt.Registry) error { 33 return nil 34 } 35 36 // MarshalBinary interface implementation 37 func (m *AddressPair) MarshalBinary() ([]byte, error) { 38 if m == nil { 39 return nil, nil 40 } 41 return swag.WriteJSON(m) 42 } 43 44 // UnmarshalBinary interface implementation 45 func (m *AddressPair) UnmarshalBinary(b []byte) error { 46 var res AddressPair 47 if err := swag.ReadJSON(b, &res); err != nil { 48 return err 49 } 50 *m = res 51 return nil 52 }