// Code generated by go-swagger; DO NOT EDIT.

package repository

// This file was generated by the swagger tool.
// Editing this file might prove futile when you re-run the swagger generate command

import (
	"fmt"

	"github.com/go-openapi/runtime"
	"github.com/go-openapi/strfmt"
)

// UserCurrentDeleteSubscriptionReader is a Reader for the UserCurrentDeleteSubscription structure.
type UserCurrentDeleteSubscriptionReader struct {
	formats strfmt.Registry
}

// ReadResponse reads a server response into the received o.
func (o *UserCurrentDeleteSubscriptionReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) {
	switch response.Code() {
	case 204:
		result := NewUserCurrentDeleteSubscriptionNoContent()
		if err := result.readResponse(response, consumer, o.formats); err != nil {
			return nil, err
		}
		return result, nil
	case 404:
		result := NewUserCurrentDeleteSubscriptionNotFound()
		if err := result.readResponse(response, consumer, o.formats); err != nil {
			return nil, err
		}
		return nil, result
	default:
		return nil, runtime.NewAPIError("[DELETE /repos/{owner}/{repo}/subscription] userCurrentDeleteSubscription", response, response.Code())
	}
}

// NewUserCurrentDeleteSubscriptionNoContent creates a UserCurrentDeleteSubscriptionNoContent with default headers values
func NewUserCurrentDeleteSubscriptionNoContent() *UserCurrentDeleteSubscriptionNoContent {
	return &UserCurrentDeleteSubscriptionNoContent{}
}

/*
UserCurrentDeleteSubscriptionNoContent describes a response with status code 204, with default header values.

APIEmpty is an empty response
*/
type UserCurrentDeleteSubscriptionNoContent struct {
}

// IsSuccess returns true when this user current delete subscription no content response has a 2xx status code
func (o *UserCurrentDeleteSubscriptionNoContent) IsSuccess() bool {
	return true
}

// IsRedirect returns true when this user current delete subscription no content response has a 3xx status code
func (o *UserCurrentDeleteSubscriptionNoContent) IsRedirect() bool {
	return false
}

// IsClientError returns true when this user current delete subscription no content response has a 4xx status code
func (o *UserCurrentDeleteSubscriptionNoContent) IsClientError() bool {
	return false
}

// IsServerError returns true when this user current delete subscription no content response has a 5xx status code
func (o *UserCurrentDeleteSubscriptionNoContent) IsServerError() bool {
	return false
}

// IsCode returns true when this user current delete subscription no content response a status code equal to that given
func (o *UserCurrentDeleteSubscriptionNoContent) IsCode(code int) bool {
	return code == 204
}

// Code gets the status code for the user current delete subscription no content response
func (o *UserCurrentDeleteSubscriptionNoContent) Code() int {
	return 204
}

func (o *UserCurrentDeleteSubscriptionNoContent) Error() string {
	return fmt.Sprintf("[DELETE /repos/{owner}/{repo}/subscription][%d] userCurrentDeleteSubscriptionNoContent", 204)
}

func (o *UserCurrentDeleteSubscriptionNoContent) String() string {
	return fmt.Sprintf("[DELETE /repos/{owner}/{repo}/subscription][%d] userCurrentDeleteSubscriptionNoContent", 204)
}

func (o *UserCurrentDeleteSubscriptionNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {

	return nil
}

// NewUserCurrentDeleteSubscriptionNotFound creates a UserCurrentDeleteSubscriptionNotFound with default headers values
func NewUserCurrentDeleteSubscriptionNotFound() *UserCurrentDeleteSubscriptionNotFound {
	return &UserCurrentDeleteSubscriptionNotFound{}
}

/*
UserCurrentDeleteSubscriptionNotFound describes a response with status code 404, with default header values.

APINotFound is a not found empty response
*/
type UserCurrentDeleteSubscriptionNotFound struct {
}

// IsSuccess returns true when this user current delete subscription not found response has a 2xx status code
func (o *UserCurrentDeleteSubscriptionNotFound) IsSuccess() bool {
	return false
}

// IsRedirect returns true when this user current delete subscription not found response has a 3xx status code
func (o *UserCurrentDeleteSubscriptionNotFound) IsRedirect() bool {
	return false
}

// IsClientError returns true when this user current delete subscription not found response has a 4xx status code
func (o *UserCurrentDeleteSubscriptionNotFound) IsClientError() bool {
	return true
}

// IsServerError returns true when this user current delete subscription not found response has a 5xx status code
func (o *UserCurrentDeleteSubscriptionNotFound) IsServerError() bool {
	return false
}

// IsCode returns true when this user current delete subscription not found response a status code equal to that given
func (o *UserCurrentDeleteSubscriptionNotFound) IsCode(code int) bool {
	return code == 404
}

// Code gets the status code for the user current delete subscription not found response
func (o *UserCurrentDeleteSubscriptionNotFound) Code() int {
	return 404
}

func (o *UserCurrentDeleteSubscriptionNotFound) Error() string {
	return fmt.Sprintf("[DELETE /repos/{owner}/{repo}/subscription][%d] userCurrentDeleteSubscriptionNotFound", 404)
}

func (o *UserCurrentDeleteSubscriptionNotFound) String() string {
	return fmt.Sprintf("[DELETE /repos/{owner}/{repo}/subscription][%d] userCurrentDeleteSubscriptionNotFound", 404)
}

func (o *UserCurrentDeleteSubscriptionNotFound) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {

	return nil
}
