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

package organization

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

// OrgIsPublicMemberReader is a Reader for the OrgIsPublicMember structure.
type OrgIsPublicMemberReader struct {
	formats strfmt.Registry
}

// ReadResponse reads a server response into the received o.
func (o *OrgIsPublicMemberReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) {
	switch response.Code() {
	case 204:
		result := NewOrgIsPublicMemberNoContent()
		if err := result.readResponse(response, consumer, o.formats); err != nil {
			return nil, err
		}
		return result, nil
	case 404:
		result := NewOrgIsPublicMemberNotFound()
		if err := result.readResponse(response, consumer, o.formats); err != nil {
			return nil, err
		}
		return nil, result
	default:
		return nil, runtime.NewAPIError("[GET /orgs/{org}/public_members/{username}] orgIsPublicMember", response, response.Code())
	}
}

// NewOrgIsPublicMemberNoContent creates a OrgIsPublicMemberNoContent with default headers values
func NewOrgIsPublicMemberNoContent() *OrgIsPublicMemberNoContent {
	return &OrgIsPublicMemberNoContent{}
}

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

user is a public member
*/
type OrgIsPublicMemberNoContent struct {
}

// IsSuccess returns true when this org is public member no content response has a 2xx status code
func (o *OrgIsPublicMemberNoContent) IsSuccess() bool {
	return true
}

// IsRedirect returns true when this org is public member no content response has a 3xx status code
func (o *OrgIsPublicMemberNoContent) IsRedirect() bool {
	return false
}

// IsClientError returns true when this org is public member no content response has a 4xx status code
func (o *OrgIsPublicMemberNoContent) IsClientError() bool {
	return false
}

// IsServerError returns true when this org is public member no content response has a 5xx status code
func (o *OrgIsPublicMemberNoContent) IsServerError() bool {
	return false
}

// IsCode returns true when this org is public member no content response a status code equal to that given
func (o *OrgIsPublicMemberNoContent) IsCode(code int) bool {
	return code == 204
}

// Code gets the status code for the org is public member no content response
func (o *OrgIsPublicMemberNoContent) Code() int {
	return 204
}

func (o *OrgIsPublicMemberNoContent) Error() string {
	return fmt.Sprintf("[GET /orgs/{org}/public_members/{username}][%d] orgIsPublicMemberNoContent", 204)
}

func (o *OrgIsPublicMemberNoContent) String() string {
	return fmt.Sprintf("[GET /orgs/{org}/public_members/{username}][%d] orgIsPublicMemberNoContent", 204)
}

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

	return nil
}

// NewOrgIsPublicMemberNotFound creates a OrgIsPublicMemberNotFound with default headers values
func NewOrgIsPublicMemberNotFound() *OrgIsPublicMemberNotFound {
	return &OrgIsPublicMemberNotFound{}
}

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

user is not a public member
*/
type OrgIsPublicMemberNotFound struct {
}

// IsSuccess returns true when this org is public member not found response has a 2xx status code
func (o *OrgIsPublicMemberNotFound) IsSuccess() bool {
	return false
}

// IsRedirect returns true when this org is public member not found response has a 3xx status code
func (o *OrgIsPublicMemberNotFound) IsRedirect() bool {
	return false
}

// IsClientError returns true when this org is public member not found response has a 4xx status code
func (o *OrgIsPublicMemberNotFound) IsClientError() bool {
	return true
}

// IsServerError returns true when this org is public member not found response has a 5xx status code
func (o *OrgIsPublicMemberNotFound) IsServerError() bool {
	return false
}

// IsCode returns true when this org is public member not found response a status code equal to that given
func (o *OrgIsPublicMemberNotFound) IsCode(code int) bool {
	return code == 404
}

// Code gets the status code for the org is public member not found response
func (o *OrgIsPublicMemberNotFound) Code() int {
	return 404
}

func (o *OrgIsPublicMemberNotFound) Error() string {
	return fmt.Sprintf("[GET /orgs/{org}/public_members/{username}][%d] orgIsPublicMemberNotFound", 404)
}

func (o *OrgIsPublicMemberNotFound) String() string {
	return fmt.Sprintf("[GET /orgs/{org}/public_members/{username}][%d] orgIsPublicMemberNotFound", 404)
}

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

	return nil
}
