...

Source file src/github.com/redhat-developer/odo/pkg/apiserver-gen/go/model_general_error.go

Documentation: github.com/redhat-developer/odo/pkg/apiserver-gen/go

     1  /*
     2   * odo dev
     3   *
     4   * API interface for 'odo dev'
     5   *
     6   * API version: 0.1
     7   * Generated by: OpenAPI Generator (https://openapi-generator.tech)
     8   */
     9  
    10  package openapi
    11  
    12  type GeneralError struct {
    13  	Message string `json:"message,omitempty"`
    14  }
    15  
    16  // AssertGeneralErrorRequired checks if the required fields are not zero-ed
    17  func AssertGeneralErrorRequired(obj GeneralError) error {
    18  	return nil
    19  }
    20  
    21  // AssertRecurseGeneralErrorRequired recursively checks if required fields are not zero-ed in a nested slice.
    22  // Accepts only nested slice of GeneralError (e.g. [][]GeneralError), otherwise ErrTypeAssertionError is thrown.
    23  func AssertRecurseGeneralErrorRequired(objSlice interface{}) error {
    24  	return AssertRecurseInterfaceRequired(objSlice, func(obj interface{}) error {
    25  		aGeneralError, ok := obj.(GeneralError)
    26  		if !ok {
    27  			return ErrTypeAssertionError
    28  		}
    29  		return AssertGeneralErrorRequired(aGeneralError)
    30  	})
    31  }
    32  

View as plain text