github.com/sap/cf-mta-plugin@v2.6.3+incompatible/clients/models/cloud_foundry_resource_entity.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/errors"
    12  	"github.com/go-openapi/swag"
    13  )
    14  
    15  // CloudFoundryResourceEntity cloud foundry resource entity
    16  // swagger:model CloudFoundryResource_entity
    17  
    18  type CloudFoundryResourceEntity struct {
    19  
    20  	// name
    21  	Name string `json:"name,omitempty"`
    22  }
    23  
    24  /* polymorph CloudFoundryResource_entity name false */
    25  
    26  // Validate validates this cloud foundry resource entity
    27  func (m *CloudFoundryResourceEntity) Validate(formats strfmt.Registry) error {
    28  	var res []error
    29  
    30  	if len(res) > 0 {
    31  		return errors.CompositeValidationError(res...)
    32  	}
    33  	return nil
    34  }
    35  
    36  // MarshalBinary interface implementation
    37  func (m *CloudFoundryResourceEntity) 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 *CloudFoundryResourceEntity) UnmarshalBinary(b []byte) error {
    46  	var res CloudFoundryResourceEntity
    47  	if err := swag.ReadJSON(b, &res); err != nil {
    48  		return err
    49  	}
    50  	*m = res
    51  	return nil
    52  }