// 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"
)

// RepoDeleteGitHookReader is a Reader for the RepoDeleteGitHook structure.
type RepoDeleteGitHookReader struct {
	formats strfmt.Registry
}

// ReadResponse reads a server response into the received o.
func (o *RepoDeleteGitHookReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) {
	switch response.Code() {
	case 204:
		result := NewRepoDeleteGitHookNoContent()
		if err := result.readResponse(response, consumer, o.formats); err != nil {
			return nil, err
		}
		return result, nil
	case 404:
		result := NewRepoDeleteGitHookNotFound()
		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}/hooks/git/{id}] repoDeleteGitHook", response, response.Code())
	}
}

// NewRepoDeleteGitHookNoContent creates a RepoDeleteGitHookNoContent with default headers values
func NewRepoDeleteGitHookNoContent() *RepoDeleteGitHookNoContent {
	return &RepoDeleteGitHookNoContent{}
}

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

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

// IsSuccess returns true when this repo delete git hook no content response has a 2xx status code
func (o *RepoDeleteGitHookNoContent) IsSuccess() bool {
	return true
}

// IsRedirect returns true when this repo delete git hook no content response has a 3xx status code
func (o *RepoDeleteGitHookNoContent) IsRedirect() bool {
	return false
}

// IsClientError returns true when this repo delete git hook no content response has a 4xx status code
func (o *RepoDeleteGitHookNoContent) IsClientError() bool {
	return false
}

// IsServerError returns true when this repo delete git hook no content response has a 5xx status code
func (o *RepoDeleteGitHookNoContent) IsServerError() bool {
	return false
}

// IsCode returns true when this repo delete git hook no content response a status code equal to that given
func (o *RepoDeleteGitHookNoContent) IsCode(code int) bool {
	return code == 204
}

// Code gets the status code for the repo delete git hook no content response
func (o *RepoDeleteGitHookNoContent) Code() int {
	return 204
}

func (o *RepoDeleteGitHookNoContent) Error() string {
	return fmt.Sprintf("[DELETE /repos/{owner}/{repo}/hooks/git/{id}][%d] repoDeleteGitHookNoContent", 204)
}

func (o *RepoDeleteGitHookNoContent) String() string {
	return fmt.Sprintf("[DELETE /repos/{owner}/{repo}/hooks/git/{id}][%d] repoDeleteGitHookNoContent", 204)
}

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

	return nil
}

// NewRepoDeleteGitHookNotFound creates a RepoDeleteGitHookNotFound with default headers values
func NewRepoDeleteGitHookNotFound() *RepoDeleteGitHookNotFound {
	return &RepoDeleteGitHookNotFound{}
}

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

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

// IsSuccess returns true when this repo delete git hook not found response has a 2xx status code
func (o *RepoDeleteGitHookNotFound) IsSuccess() bool {
	return false
}

// IsRedirect returns true when this repo delete git hook not found response has a 3xx status code
func (o *RepoDeleteGitHookNotFound) IsRedirect() bool {
	return false
}

// IsClientError returns true when this repo delete git hook not found response has a 4xx status code
func (o *RepoDeleteGitHookNotFound) IsClientError() bool {
	return true
}

// IsServerError returns true when this repo delete git hook not found response has a 5xx status code
func (o *RepoDeleteGitHookNotFound) IsServerError() bool {
	return false
}

// IsCode returns true when this repo delete git hook not found response a status code equal to that given
func (o *RepoDeleteGitHookNotFound) IsCode(code int) bool {
	return code == 404
}

// Code gets the status code for the repo delete git hook not found response
func (o *RepoDeleteGitHookNotFound) Code() int {
	return 404
}

func (o *RepoDeleteGitHookNotFound) Error() string {
	return fmt.Sprintf("[DELETE /repos/{owner}/{repo}/hooks/git/{id}][%d] repoDeleteGitHookNotFound", 404)
}

func (o *RepoDeleteGitHookNotFound) String() string {
	return fmt.Sprintf("[DELETE /repos/{owner}/{repo}/hooks/git/{id}][%d] repoDeleteGitHookNotFound", 404)
}

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

	return nil
}
