1 // Code generated by go-swagger; DO NOT EDIT.
5 // This file was generated by the swagger tool.
6 // Editing this file might prove futile when you re-run the swagger generate command
11 strfmt "github.com/go-openapi/strfmt"
13 "github.com/go-openapi/errors"
14 "github.com/go-openapi/swag"
15 "github.com/go-openapi/validate"
18 // Format2ActionDefinition format2 action definition
19 // swagger:model Format2ActionDefinition
20 type Format2ActionDefinition struct {
22 // r a n ue group parameters
24 RANUeGroupParameters []*RANUeGroupList `json:"RANUeGroupParameters"`
27 // Validate validates this format2 action definition
28 func (m *Format2ActionDefinition) Validate(formats strfmt.Registry) error {
31 if err := m.validateRANUeGroupParameters(formats); err != nil {
32 res = append(res, err)
36 return errors.CompositeValidationError(res...)
41 func (m *Format2ActionDefinition) validateRANUeGroupParameters(formats strfmt.Registry) error {
43 if err := validate.Required("RANUeGroupParameters", "body", m.RANUeGroupParameters); err != nil {
47 for i := 0; i < len(m.RANUeGroupParameters); i++ {
48 if swag.IsZero(m.RANUeGroupParameters[i]) { // not required
52 if m.RANUeGroupParameters[i] != nil {
53 if err := m.RANUeGroupParameters[i].Validate(formats); err != nil {
54 if ve, ok := err.(*errors.Validation); ok {
55 return ve.ValidateName("RANUeGroupParameters" + "." + strconv.Itoa(i))
66 // MarshalBinary interface implementation
67 func (m *Format2ActionDefinition) MarshalBinary() ([]byte, error) {
71 return swag.WriteJSON(m)
74 // UnmarshalBinary interface implementation
75 func (m *Format2ActionDefinition) UnmarshalBinary(b []byte) error {
76 var res Format2ActionDefinition
77 if err := swag.ReadJSON(b, &res); err != nil {