github.com/sap/cf-mta-plugin@v2.6.3+incompatible/clients/mtaclient/operations/get_csrf_token_responses.go (about)

     1  // Code generated by go-swagger; DO NOT EDIT.
     2  
     3  package operations
     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  	"fmt"
    10  
    11  	"github.com/go-openapi/runtime"
    12  
    13  	strfmt "github.com/go-openapi/strfmt"
    14  
    15  	baseclient "github.com/cloudfoundry-incubator/multiapps-cli-plugin/clients/baseclient"
    16  )
    17  
    18  // GetCsrfTokenReader is a Reader for the GetCsrfToken structure.
    19  type GetCsrfTokenReader struct {
    20  	formats strfmt.Registry
    21  }
    22  
    23  // ReadResponse reads a server response into the received o.
    24  func (o *GetCsrfTokenReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) {
    25  	switch response.Code() {
    26  
    27  	case 204:
    28  		result := NewGetCsrfTokenNoContent()
    29  		if err := result.readResponse(response, consumer, o.formats); err != nil {
    30  			return nil, err
    31  		}
    32  		return result, nil
    33  
    34  	default:
    35  		return nil, baseclient.BuildErrorResponse(response, consumer, o.formats)
    36  	}
    37  }
    38  
    39  // NewGetCsrfTokenNoContent creates a GetCsrfTokenNoContent with default headers values
    40  func NewGetCsrfTokenNoContent() *GetCsrfTokenNoContent {
    41  	return &GetCsrfTokenNoContent{}
    42  }
    43  
    44  /*GetCsrfTokenNoContent handles this case with default header values.
    45  
    46  No Content
    47  */
    48  type GetCsrfTokenNoContent struct {
    49  }
    50  
    51  func (o *GetCsrfTokenNoContent) Error() string {
    52  	return fmt.Sprintf("[GET /csrf-token][%d] getCsrfTokenNoContent ", 204)
    53  }
    54  
    55  func (o *GetCsrfTokenNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
    56  
    57  	return nil
    58  }