// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: base/types/gfspserver/download.proto

package gfspserver

import (
	context "context"
	fmt "fmt"
	gfsperrors "github.com/bnb-chain/greenfield-storage-provider/base/types/gfsperrors"
	gfsptask "github.com/bnb-chain/greenfield-storage-provider/base/types/gfsptask"
	grpc1 "github.com/cosmos/gogoproto/grpc"
	proto "github.com/cosmos/gogoproto/proto"
	grpc "google.golang.org/grpc"
	codes "google.golang.org/grpc/codes"
	status "google.golang.org/grpc/status"
	io "io"
	math "math"
	math_bits "math/bits"
)

// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf

// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package

type GfSpDownloadObjectRequest struct {
	DownloadObjectTask *gfsptask.GfSpDownloadObjectTask `protobuf:"bytes,1,opt,name=download_object_task,json=downloadObjectTask,proto3" json:"download_object_task,omitempty"`
}

func (m *GfSpDownloadObjectRequest) Reset()         { *m = GfSpDownloadObjectRequest{} }
func (m *GfSpDownloadObjectRequest) String() string { return proto.CompactTextString(m) }
func (*GfSpDownloadObjectRequest) ProtoMessage()    {}
func (*GfSpDownloadObjectRequest) Descriptor() ([]byte, []int) {
	return fileDescriptor_4e9c5d8fc8df4b20, []int{0}
}
func (m *GfSpDownloadObjectRequest) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *GfSpDownloadObjectRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_GfSpDownloadObjectRequest.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *GfSpDownloadObjectRequest) XXX_Merge(src proto.Message) {
	xxx_messageInfo_GfSpDownloadObjectRequest.Merge(m, src)
}
func (m *GfSpDownloadObjectRequest) XXX_Size() int {
	return m.Size()
}
func (m *GfSpDownloadObjectRequest) XXX_DiscardUnknown() {
	xxx_messageInfo_GfSpDownloadObjectRequest.DiscardUnknown(m)
}

var xxx_messageInfo_GfSpDownloadObjectRequest proto.InternalMessageInfo

func (m *GfSpDownloadObjectRequest) GetDownloadObjectTask() *gfsptask.GfSpDownloadObjectTask {
	if m != nil {
		return m.DownloadObjectTask
	}
	return nil
}

type GfSpDownloadObjectResponse struct {
	Err  *gfsperrors.GfSpError `protobuf:"bytes,1,opt,name=err,proto3" json:"err,omitempty"`
	Data []byte                `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
}

func (m *GfSpDownloadObjectResponse) Reset()         { *m = GfSpDownloadObjectResponse{} }
func (m *GfSpDownloadObjectResponse) String() string { return proto.CompactTextString(m) }
func (*GfSpDownloadObjectResponse) ProtoMessage()    {}
func (*GfSpDownloadObjectResponse) Descriptor() ([]byte, []int) {
	return fileDescriptor_4e9c5d8fc8df4b20, []int{1}
}
func (m *GfSpDownloadObjectResponse) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *GfSpDownloadObjectResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_GfSpDownloadObjectResponse.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *GfSpDownloadObjectResponse) XXX_Merge(src proto.Message) {
	xxx_messageInfo_GfSpDownloadObjectResponse.Merge(m, src)
}
func (m *GfSpDownloadObjectResponse) XXX_Size() int {
	return m.Size()
}
func (m *GfSpDownloadObjectResponse) XXX_DiscardUnknown() {
	xxx_messageInfo_GfSpDownloadObjectResponse.DiscardUnknown(m)
}

var xxx_messageInfo_GfSpDownloadObjectResponse proto.InternalMessageInfo

func (m *GfSpDownloadObjectResponse) GetErr() *gfsperrors.GfSpError {
	if m != nil {
		return m.Err
	}
	return nil
}

func (m *GfSpDownloadObjectResponse) GetData() []byte {
	if m != nil {
		return m.Data
	}
	return nil
}

type GfSpDownloadPieceRequest struct {
	DownloadPieceTask *gfsptask.GfSpDownloadPieceTask `protobuf:"bytes,1,opt,name=download_piece_task,json=downloadPieceTask,proto3" json:"download_piece_task,omitempty"`
}

func (m *GfSpDownloadPieceRequest) Reset()         { *m = GfSpDownloadPieceRequest{} }
func (m *GfSpDownloadPieceRequest) String() string { return proto.CompactTextString(m) }
func (*GfSpDownloadPieceRequest) ProtoMessage()    {}
func (*GfSpDownloadPieceRequest) Descriptor() ([]byte, []int) {
	return fileDescriptor_4e9c5d8fc8df4b20, []int{2}
}
func (m *GfSpDownloadPieceRequest) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *GfSpDownloadPieceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_GfSpDownloadPieceRequest.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *GfSpDownloadPieceRequest) XXX_Merge(src proto.Message) {
	xxx_messageInfo_GfSpDownloadPieceRequest.Merge(m, src)
}
func (m *GfSpDownloadPieceRequest) XXX_Size() int {
	return m.Size()
}
func (m *GfSpDownloadPieceRequest) XXX_DiscardUnknown() {
	xxx_messageInfo_GfSpDownloadPieceRequest.DiscardUnknown(m)
}

var xxx_messageInfo_GfSpDownloadPieceRequest proto.InternalMessageInfo

func (m *GfSpDownloadPieceRequest) GetDownloadPieceTask() *gfsptask.GfSpDownloadPieceTask {
	if m != nil {
		return m.DownloadPieceTask
	}
	return nil
}

type GfSpDownloadPieceResponse struct {
	Err  *gfsperrors.GfSpError `protobuf:"bytes,1,opt,name=err,proto3" json:"err,omitempty"`
	Data []byte                `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
}

func (m *GfSpDownloadPieceResponse) Reset()         { *m = GfSpDownloadPieceResponse{} }
func (m *GfSpDownloadPieceResponse) String() string { return proto.CompactTextString(m) }
func (*GfSpDownloadPieceResponse) ProtoMessage()    {}
func (*GfSpDownloadPieceResponse) Descriptor() ([]byte, []int) {
	return fileDescriptor_4e9c5d8fc8df4b20, []int{3}
}
func (m *GfSpDownloadPieceResponse) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *GfSpDownloadPieceResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_GfSpDownloadPieceResponse.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *GfSpDownloadPieceResponse) XXX_Merge(src proto.Message) {
	xxx_messageInfo_GfSpDownloadPieceResponse.Merge(m, src)
}
func (m *GfSpDownloadPieceResponse) XXX_Size() int {
	return m.Size()
}
func (m *GfSpDownloadPieceResponse) XXX_DiscardUnknown() {
	xxx_messageInfo_GfSpDownloadPieceResponse.DiscardUnknown(m)
}

var xxx_messageInfo_GfSpDownloadPieceResponse proto.InternalMessageInfo

func (m *GfSpDownloadPieceResponse) GetErr() *gfsperrors.GfSpError {
	if m != nil {
		return m.Err
	}
	return nil
}

func (m *GfSpDownloadPieceResponse) GetData() []byte {
	if m != nil {
		return m.Data
	}
	return nil
}

type GfSpGetChallengeInfoRequest struct {
	ChallengePieceTask *gfsptask.GfSpChallengePieceTask `protobuf:"bytes,1,opt,name=challenge_piece_task,json=challengePieceTask,proto3" json:"challenge_piece_task,omitempty"`
}

func (m *GfSpGetChallengeInfoRequest) Reset()         { *m = GfSpGetChallengeInfoRequest{} }
func (m *GfSpGetChallengeInfoRequest) String() string { return proto.CompactTextString(m) }
func (*GfSpGetChallengeInfoRequest) ProtoMessage()    {}
func (*GfSpGetChallengeInfoRequest) Descriptor() ([]byte, []int) {
	return fileDescriptor_4e9c5d8fc8df4b20, []int{4}
}
func (m *GfSpGetChallengeInfoRequest) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *GfSpGetChallengeInfoRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_GfSpGetChallengeInfoRequest.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *GfSpGetChallengeInfoRequest) XXX_Merge(src proto.Message) {
	xxx_messageInfo_GfSpGetChallengeInfoRequest.Merge(m, src)
}
func (m *GfSpGetChallengeInfoRequest) XXX_Size() int {
	return m.Size()
}
func (m *GfSpGetChallengeInfoRequest) XXX_DiscardUnknown() {
	xxx_messageInfo_GfSpGetChallengeInfoRequest.DiscardUnknown(m)
}

var xxx_messageInfo_GfSpGetChallengeInfoRequest proto.InternalMessageInfo

func (m *GfSpGetChallengeInfoRequest) GetChallengePieceTask() *gfsptask.GfSpChallengePieceTask {
	if m != nil {
		return m.ChallengePieceTask
	}
	return nil
}

type GfSpGetChallengeInfoResponse struct {
	Err           *gfsperrors.GfSpError `protobuf:"bytes,1,opt,name=err,proto3" json:"err,omitempty"`
	Data          []byte                `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
	IntegrityHash []byte                `protobuf:"bytes,3,opt,name=integrity_hash,json=integrityHash,proto3" json:"integrity_hash,omitempty"`
	Checksums     [][]byte              `protobuf:"bytes,4,rep,name=checksums,proto3" json:"checksums,omitempty"`
}

func (m *GfSpGetChallengeInfoResponse) Reset()         { *m = GfSpGetChallengeInfoResponse{} }
func (m *GfSpGetChallengeInfoResponse) String() string { return proto.CompactTextString(m) }
func (*GfSpGetChallengeInfoResponse) ProtoMessage()    {}
func (*GfSpGetChallengeInfoResponse) Descriptor() ([]byte, []int) {
	return fileDescriptor_4e9c5d8fc8df4b20, []int{5}
}
func (m *GfSpGetChallengeInfoResponse) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *GfSpGetChallengeInfoResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_GfSpGetChallengeInfoResponse.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *GfSpGetChallengeInfoResponse) XXX_Merge(src proto.Message) {
	xxx_messageInfo_GfSpGetChallengeInfoResponse.Merge(m, src)
}
func (m *GfSpGetChallengeInfoResponse) XXX_Size() int {
	return m.Size()
}
func (m *GfSpGetChallengeInfoResponse) XXX_DiscardUnknown() {
	xxx_messageInfo_GfSpGetChallengeInfoResponse.DiscardUnknown(m)
}

var xxx_messageInfo_GfSpGetChallengeInfoResponse proto.InternalMessageInfo

func (m *GfSpGetChallengeInfoResponse) GetErr() *gfsperrors.GfSpError {
	if m != nil {
		return m.Err
	}
	return nil
}

func (m *GfSpGetChallengeInfoResponse) GetData() []byte {
	if m != nil {
		return m.Data
	}
	return nil
}

func (m *GfSpGetChallengeInfoResponse) GetIntegrityHash() []byte {
	if m != nil {
		return m.IntegrityHash
	}
	return nil
}

func (m *GfSpGetChallengeInfoResponse) GetChecksums() [][]byte {
	if m != nil {
		return m.Checksums
	}
	return nil
}

type GfSpReimburseQuotaRequest struct {
	BucketId   uint64 `protobuf:"varint,1,opt,name=bucket_id,json=bucketId,proto3" json:"bucket_id,omitempty"`
	ExtraQuota uint64 `protobuf:"varint,2,opt,name=extra_quota,json=extraQuota,proto3" json:"extra_quota,omitempty"`
	// year_month is the query bucket quota's month, like "2023-03"
	YearMonth string `protobuf:"bytes,3,opt,name=year_month,json=yearMonth,proto3" json:"year_month,omitempty"`
}

func (m *GfSpReimburseQuotaRequest) Reset()         { *m = GfSpReimburseQuotaRequest{} }
func (m *GfSpReimburseQuotaRequest) String() string { return proto.CompactTextString(m) }
func (*GfSpReimburseQuotaRequest) ProtoMessage()    {}
func (*GfSpReimburseQuotaRequest) Descriptor() ([]byte, []int) {
	return fileDescriptor_4e9c5d8fc8df4b20, []int{6}
}
func (m *GfSpReimburseQuotaRequest) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *GfSpReimburseQuotaRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_GfSpReimburseQuotaRequest.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *GfSpReimburseQuotaRequest) XXX_Merge(src proto.Message) {
	xxx_messageInfo_GfSpReimburseQuotaRequest.Merge(m, src)
}
func (m *GfSpReimburseQuotaRequest) XXX_Size() int {
	return m.Size()
}
func (m *GfSpReimburseQuotaRequest) XXX_DiscardUnknown() {
	xxx_messageInfo_GfSpReimburseQuotaRequest.DiscardUnknown(m)
}

var xxx_messageInfo_GfSpReimburseQuotaRequest proto.InternalMessageInfo

func (m *GfSpReimburseQuotaRequest) GetBucketId() uint64 {
	if m != nil {
		return m.BucketId
	}
	return 0
}

func (m *GfSpReimburseQuotaRequest) GetExtraQuota() uint64 {
	if m != nil {
		return m.ExtraQuota
	}
	return 0
}

func (m *GfSpReimburseQuotaRequest) GetYearMonth() string {
	if m != nil {
		return m.YearMonth
	}
	return ""
}

type GfSpReimburseQuotaResponse struct {
	Err *gfsperrors.GfSpError `protobuf:"bytes,1,opt,name=err,proto3" json:"err,omitempty"`
}

func (m *GfSpReimburseQuotaResponse) Reset()         { *m = GfSpReimburseQuotaResponse{} }
func (m *GfSpReimburseQuotaResponse) String() string { return proto.CompactTextString(m) }
func (*GfSpReimburseQuotaResponse) ProtoMessage()    {}
func (*GfSpReimburseQuotaResponse) Descriptor() ([]byte, []int) {
	return fileDescriptor_4e9c5d8fc8df4b20, []int{7}
}
func (m *GfSpReimburseQuotaResponse) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *GfSpReimburseQuotaResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_GfSpReimburseQuotaResponse.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *GfSpReimburseQuotaResponse) XXX_Merge(src proto.Message) {
	xxx_messageInfo_GfSpReimburseQuotaResponse.Merge(m, src)
}
func (m *GfSpReimburseQuotaResponse) XXX_Size() int {
	return m.Size()
}
func (m *GfSpReimburseQuotaResponse) XXX_DiscardUnknown() {
	xxx_messageInfo_GfSpReimburseQuotaResponse.DiscardUnknown(m)
}

var xxx_messageInfo_GfSpReimburseQuotaResponse proto.InternalMessageInfo

func (m *GfSpReimburseQuotaResponse) GetErr() *gfsperrors.GfSpError {
	if m != nil {
		return m.Err
	}
	return nil
}

type GfSpDeductQuotaForBucketMigrateRequest struct {
	BucketId    uint64 `protobuf:"varint,1,opt,name=bucket_id,json=bucketId,proto3" json:"bucket_id,omitempty"`
	DeductQuota uint64 `protobuf:"varint,2,opt,name=deduct_quota,json=deductQuota,proto3" json:"deduct_quota,omitempty"`
	// year_month is the query bucket quota's month, like "2023-03"
	YearMonth string `protobuf:"bytes,3,opt,name=year_month,json=yearMonth,proto3" json:"year_month,omitempty"`
}

func (m *GfSpDeductQuotaForBucketMigrateRequest) Reset() {
	*m = GfSpDeductQuotaForBucketMigrateRequest{}
}
func (m *GfSpDeductQuotaForBucketMigrateRequest) String() string { return proto.CompactTextString(m) }
func (*GfSpDeductQuotaForBucketMigrateRequest) ProtoMessage()    {}
func (*GfSpDeductQuotaForBucketMigrateRequest) Descriptor() ([]byte, []int) {
	return fileDescriptor_4e9c5d8fc8df4b20, []int{8}
}
func (m *GfSpDeductQuotaForBucketMigrateRequest) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *GfSpDeductQuotaForBucketMigrateRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_GfSpDeductQuotaForBucketMigrateRequest.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *GfSpDeductQuotaForBucketMigrateRequest) XXX_Merge(src proto.Message) {
	xxx_messageInfo_GfSpDeductQuotaForBucketMigrateRequest.Merge(m, src)
}
func (m *GfSpDeductQuotaForBucketMigrateRequest) XXX_Size() int {
	return m.Size()
}
func (m *GfSpDeductQuotaForBucketMigrateRequest) XXX_DiscardUnknown() {
	xxx_messageInfo_GfSpDeductQuotaForBucketMigrateRequest.DiscardUnknown(m)
}

var xxx_messageInfo_GfSpDeductQuotaForBucketMigrateRequest proto.InternalMessageInfo

func (m *GfSpDeductQuotaForBucketMigrateRequest) GetBucketId() uint64 {
	if m != nil {
		return m.BucketId
	}
	return 0
}

func (m *GfSpDeductQuotaForBucketMigrateRequest) GetDeductQuota() uint64 {
	if m != nil {
		return m.DeductQuota
	}
	return 0
}

func (m *GfSpDeductQuotaForBucketMigrateRequest) GetYearMonth() string {
	if m != nil {
		return m.YearMonth
	}
	return ""
}

type GfSpDeductQuotaForBucketMigrateResponse struct {
	Err *gfsperrors.GfSpError `protobuf:"bytes,1,opt,name=err,proto3" json:"err,omitempty"`
}

func (m *GfSpDeductQuotaForBucketMigrateResponse) Reset() {
	*m = GfSpDeductQuotaForBucketMigrateResponse{}
}
func (m *GfSpDeductQuotaForBucketMigrateResponse) String() string { return proto.CompactTextString(m) }
func (*GfSpDeductQuotaForBucketMigrateResponse) ProtoMessage()    {}
func (*GfSpDeductQuotaForBucketMigrateResponse) Descriptor() ([]byte, []int) {
	return fileDescriptor_4e9c5d8fc8df4b20, []int{9}
}
func (m *GfSpDeductQuotaForBucketMigrateResponse) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *GfSpDeductQuotaForBucketMigrateResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_GfSpDeductQuotaForBucketMigrateResponse.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *GfSpDeductQuotaForBucketMigrateResponse) XXX_Merge(src proto.Message) {
	xxx_messageInfo_GfSpDeductQuotaForBucketMigrateResponse.Merge(m, src)
}
func (m *GfSpDeductQuotaForBucketMigrateResponse) XXX_Size() int {
	return m.Size()
}
func (m *GfSpDeductQuotaForBucketMigrateResponse) XXX_DiscardUnknown() {
	xxx_messageInfo_GfSpDeductQuotaForBucketMigrateResponse.DiscardUnknown(m)
}

var xxx_messageInfo_GfSpDeductQuotaForBucketMigrateResponse proto.InternalMessageInfo

func (m *GfSpDeductQuotaForBucketMigrateResponse) GetErr() *gfsperrors.GfSpError {
	if m != nil {
		return m.Err
	}
	return nil
}

func init() {
	proto.RegisterType((*GfSpDownloadObjectRequest)(nil), "base.types.gfspserver.GfSpDownloadObjectRequest")
	proto.RegisterType((*GfSpDownloadObjectResponse)(nil), "base.types.gfspserver.GfSpDownloadObjectResponse")
	proto.RegisterType((*GfSpDownloadPieceRequest)(nil), "base.types.gfspserver.GfSpDownloadPieceRequest")
	proto.RegisterType((*GfSpDownloadPieceResponse)(nil), "base.types.gfspserver.GfSpDownloadPieceResponse")
	proto.RegisterType((*GfSpGetChallengeInfoRequest)(nil), "base.types.gfspserver.GfSpGetChallengeInfoRequest")
	proto.RegisterType((*GfSpGetChallengeInfoResponse)(nil), "base.types.gfspserver.GfSpGetChallengeInfoResponse")
	proto.RegisterType((*GfSpReimburseQuotaRequest)(nil), "base.types.gfspserver.GfSpReimburseQuotaRequest")
	proto.RegisterType((*GfSpReimburseQuotaResponse)(nil), "base.types.gfspserver.GfSpReimburseQuotaResponse")
	proto.RegisterType((*GfSpDeductQuotaForBucketMigrateRequest)(nil), "base.types.gfspserver.GfSpDeductQuotaForBucketMigrateRequest")
	proto.RegisterType((*GfSpDeductQuotaForBucketMigrateResponse)(nil), "base.types.gfspserver.GfSpDeductQuotaForBucketMigrateResponse")
}

func init() {
	proto.RegisterFile("base/types/gfspserver/download.proto", fileDescriptor_4e9c5d8fc8df4b20)
}

var fileDescriptor_4e9c5d8fc8df4b20 = []byte{
	// 679 bytes of a gzipped FileDescriptorProto
	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x56, 0x4d, 0x4f, 0xdb, 0x4a,
	0x14, 0x8d, 0x1f, 0x79, 0x4f, 0x2f, 0x03, 0xef, 0x49, 0x0c, 0x54, 0x4a, 0x0d, 0x35, 0xc1, 0xea,
	0x07, 0x6a, 0x85, 0x4d, 0xc3, 0xba, 0x5d, 0xd0, 0x16, 0xca, 0x02, 0x95, 0x9a, 0xae, 0x90, 0x50,
	0x3a, 0xf6, 0xdc, 0xd8, 0x6e, 0x12, 0x8f, 0x99, 0x19, 0xa7, 0xd0, 0x76, 0xd3, 0x55, 0xb7, 0xfd,
	0x0d, 0xdd, 0x76, 0xd7, 0x5f, 0xd1, 0x25, 0xcb, 0x2e, 0x2b, 0xf8, 0x23, 0x95, 0xc7, 0xf9, 0x22,
	0x31, 0x09, 0x20, 0x36, 0x89, 0x75, 0xe6, 0xde, 0x73, 0xee, 0xb9, 0x9e, 0x7b, 0x13, 0x74, 0xd7,
	0x25, 0x02, 0x6c, 0x79, 0x1c, 0x83, 0xb0, 0xfd, 0xba, 0x88, 0x05, 0xf0, 0x36, 0x70, 0x9b, 0xb2,
	0xf7, 0x51, 0x93, 0x11, 0x6a, 0xc5, 0x9c, 0x49, 0x86, 0x6f, 0xa5, 0x51, 0x96, 0x8a, 0xb2, 0xfa,
	0x51, 0xfa, 0xf2, 0x50, 0x32, 0x70, 0xce, 0xb8, 0xb0, 0xd5, 0x57, 0x96, 0xa9, 0x1b, 0x43, 0x21,
	0x92, 0x88, 0x86, 0x9d, 0x7e, 0x64, 0xe7, 0xe6, 0x07, 0x74, 0x7b, 0xab, 0xbe, 0x17, 0x3f, 0xef,
	0xe8, 0xbd, 0x72, 0xdf, 0x81, 0x27, 0x1d, 0x38, 0x4c, 0x40, 0x48, 0x7c, 0x80, 0xe6, 0xbb, 0x85,
	0xd4, 0x98, 0x3a, 0xa9, 0xa5, 0xa9, 0x65, 0xad, 0xa2, 0xad, 0x4c, 0x57, 0x1f, 0x59, 0x43, 0x55,
	0x29, 0xda, 0x51, 0xb6, 0x37, 0x44, 0x34, 0x1c, 0x4c, 0x47, 0x30, 0x93, 0x22, 0x3d, 0x4f, 0x5b,
	0xc4, 0x2c, 0x12, 0x80, 0xab, 0x68, 0x0a, 0x38, 0xef, 0x68, 0x55, 0x86, 0xb5, 0x32, 0xab, 0x4a,
	0xed, 0x45, 0xfa, 0xe8, 0xa4, 0xc1, 0x18, 0xa3, 0x22, 0x25, 0x92, 0x94, 0xff, 0xaa, 0x68, 0x2b,
	0x33, 0x8e, 0x7a, 0x36, 0xdb, 0xa8, 0x3c, 0xa8, 0xb2, 0x1b, 0x82, 0x07, 0x5d, 0x83, 0xfb, 0x68,
	0xae, 0x67, 0x30, 0x4e, 0x0f, 0x06, 0xfd, 0x3d, 0x9c, 0xe8, 0x4f, 0x71, 0x29, 0x7b, 0xb3, 0x74,
	0x18, 0x32, 0xbd, 0xf3, 0x9d, 0xed, 0xe8, 0xde, 0xb0, 0xb9, 0x4f, 0x68, 0x21, 0x8d, 0xda, 0x02,
	0xf9, 0x2c, 0x20, 0xcd, 0x26, 0x44, 0x3e, 0x6c, 0x47, 0x75, 0x36, 0xf0, 0x02, 0xbd, 0x2e, 0x3e,
	0x6a, 0xf0, 0xe2, 0x17, 0xd8, 0x23, 0xeb, 0x3b, 0xc4, 0xde, 0x08, 0x66, 0x7e, 0xd7, 0xd0, 0x62,
	0xbe, 0xfc, 0xcd, 0xda, 0xc4, 0xf7, 0xd0, 0xff, 0x61, 0x24, 0xc1, 0xe7, 0xa1, 0x3c, 0xae, 0x05,
	0x44, 0x04, 0xe5, 0x29, 0x75, 0xfa, 0x5f, 0x0f, 0x7d, 0x49, 0x44, 0x80, 0x17, 0x51, 0xc9, 0x0b,
	0xc0, 0x6b, 0x88, 0xa4, 0x25, 0xca, 0xc5, 0xca, 0xd4, 0xca, 0x8c, 0xd3, 0x07, 0xcc, 0xa3, 0xec,
	0x85, 0x38, 0x10, 0xb6, 0xdc, 0x84, 0x0b, 0x78, 0x9d, 0x30, 0x49, 0xba, 0x9d, 0x5a, 0x40, 0x25,
	0x37, 0xf1, 0x1a, 0x20, 0x6b, 0x21, 0x55, 0xf5, 0x16, 0x9d, 0x7f, 0x33, 0x60, 0x9b, 0xe2, 0x25,
	0x34, 0x0d, 0x47, 0x92, 0x93, 0xda, 0x61, 0x9a, 0xa2, 0x2a, 0x2b, 0x3a, 0x48, 0x41, 0x8a, 0x04,
	0xdf, 0x41, 0xe8, 0x18, 0x08, 0xaf, 0xb5, 0x58, 0x24, 0xb3, 0xda, 0x4a, 0x4e, 0x29, 0x45, 0x76,
	0x52, 0xc0, 0xdc, 0xcd, 0x2e, 0xfa, 0xb0, 0xf2, 0xf5, 0x9b, 0x64, 0x7e, 0xd1, 0xd0, 0x7d, 0x75,
	0xbb, 0x80, 0x26, 0x9e, 0x54, 0x7c, 0x9b, 0x8c, 0x6f, 0xa8, 0x82, 0x77, 0x42, 0x9f, 0x13, 0x09,
	0x97, 0x72, 0xb6, 0x8c, 0x66, 0xa8, 0xa2, 0x38, 0x67, 0x6d, 0x9a, 0xf6, 0x69, 0x27, 0x79, 0x3b,
	0x40, 0x0f, 0x26, 0x16, 0x72, 0x7d, 0xa3, 0xd5, 0x1f, 0x7f, 0xa3, 0xb9, 0xc1, 0x31, 0xda, 0x03,
	0xde, 0x0e, 0x3d, 0xc0, 0x1f, 0x11, 0x1e, 0xdd, 0x1d, 0x78, 0xcd, 0xca, 0x5d, 0x94, 0xd6, 0x85,
	0x2b, 0x4e, 0x7f, 0x7c, 0x85, 0x8c, 0xcc, 0x86, 0x59, 0xc0, 0x47, 0x68, 0x76, 0x64, 0xb4, 0xb1,
	0x7d, 0x09, 0xa6, 0xc1, 0xe5, 0xa3, 0xaf, 0x5d, 0x3e, 0xa1, 0xa7, 0xfc, 0x59, 0x43, 0xf3, 0x79,
	0x13, 0x87, 0xab, 0x63, 0xc8, 0x2e, 0xd8, 0x0e, 0xfa, 0xfa, 0x95, 0x72, 0x7a, 0x35, 0x74, 0x5a,
	0x7f, 0xfe, 0x36, 0x8f, 0x6d, 0x7d, 0xee, 0xc8, 0x8d, 0x6d, 0x7d, 0xfe, 0xa8, 0x98, 0x05, 0xfc,
	0x4d, 0x43, 0x4b, 0x13, 0xee, 0x1b, 0x7e, 0x32, 0xae, 0xb1, 0x13, 0x07, 0x46, 0x7f, 0x7a, 0xdd,
	0xf4, 0x6e, 0x91, 0x1b, 0x6f, 0x7f, 0x9e, 0x1a, 0xda, 0xc9, 0xa9, 0xa1, 0xfd, 0x3e, 0x35, 0xb4,
	0xaf, 0x67, 0x46, 0xe1, 0xe4, 0xcc, 0x28, 0xfc, 0x3a, 0x33, 0x0a, 0xfb, 0x9b, 0x7e, 0x28, 0x83,
	0xc4, 0xb5, 0x3c, 0xd6, 0xb2, 0xdd, 0xc8, 0x5d, 0xf5, 0x02, 0x12, 0x46, 0xb6, 0xcf, 0x01, 0xa2,
	0x7a, 0x08, 0x4d, 0xba, 0x2a, 0x24, 0xe3, 0xc4, 0x87, 0xd5, 0x98, 0xb3, 0x76, 0x48, 0x81, 0xdb,
	0xb9, 0xff, 0x0f, 0xdc, 0x7f, 0xd4, 0xaf, 0xf7, 0xfa, 0x9f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x0f,
	0x14, 0xb3, 0xfa, 0x3f, 0x08, 0x00, 0x00,
}

// Reference imports to suppress errors if they are not otherwise used.
var _ context.Context
var _ grpc.ClientConn

// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion4

// GfSpDownloadServiceClient is the client API for GfSpDownloadService service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type GfSpDownloadServiceClient interface {
	GfSpDownloadObject(ctx context.Context, in *GfSpDownloadObjectRequest, opts ...grpc.CallOption) (*GfSpDownloadObjectResponse, error)
	GfSpDownloadPiece(ctx context.Context, in *GfSpDownloadPieceRequest, opts ...grpc.CallOption) (*GfSpDownloadPieceResponse, error)
	GfSpGetChallengeInfo(ctx context.Context, in *GfSpGetChallengeInfoRequest, opts ...grpc.CallOption) (*GfSpGetChallengeInfoResponse, error)
	GfSpReimburseQuota(ctx context.Context, in *GfSpReimburseQuotaRequest, opts ...grpc.CallOption) (*GfSpReimburseQuotaResponse, error)
	GfSpDeductQuotaForBucketMigrate(ctx context.Context, in *GfSpDeductQuotaForBucketMigrateRequest, opts ...grpc.CallOption) (*GfSpDeductQuotaForBucketMigrateResponse, error)
}

type gfSpDownloadServiceClient struct {
	cc grpc1.ClientConn
}

func NewGfSpDownloadServiceClient(cc grpc1.ClientConn) GfSpDownloadServiceClient {
	return &gfSpDownloadServiceClient{cc}
}

func (c *gfSpDownloadServiceClient) GfSpDownloadObject(ctx context.Context, in *GfSpDownloadObjectRequest, opts ...grpc.CallOption) (*GfSpDownloadObjectResponse, error) {
	out := new(GfSpDownloadObjectResponse)
	err := c.cc.Invoke(ctx, "/base.types.gfspserver.GfSpDownloadService/GfSpDownloadObject", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *gfSpDownloadServiceClient) GfSpDownloadPiece(ctx context.Context, in *GfSpDownloadPieceRequest, opts ...grpc.CallOption) (*GfSpDownloadPieceResponse, error) {
	out := new(GfSpDownloadPieceResponse)
	err := c.cc.Invoke(ctx, "/base.types.gfspserver.GfSpDownloadService/GfSpDownloadPiece", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *gfSpDownloadServiceClient) GfSpGetChallengeInfo(ctx context.Context, in *GfSpGetChallengeInfoRequest, opts ...grpc.CallOption) (*GfSpGetChallengeInfoResponse, error) {
	out := new(GfSpGetChallengeInfoResponse)
	err := c.cc.Invoke(ctx, "/base.types.gfspserver.GfSpDownloadService/GfSpGetChallengeInfo", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *gfSpDownloadServiceClient) GfSpReimburseQuota(ctx context.Context, in *GfSpReimburseQuotaRequest, opts ...grpc.CallOption) (*GfSpReimburseQuotaResponse, error) {
	out := new(GfSpReimburseQuotaResponse)
	err := c.cc.Invoke(ctx, "/base.types.gfspserver.GfSpDownloadService/GfSpReimburseQuota", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *gfSpDownloadServiceClient) GfSpDeductQuotaForBucketMigrate(ctx context.Context, in *GfSpDeductQuotaForBucketMigrateRequest, opts ...grpc.CallOption) (*GfSpDeductQuotaForBucketMigrateResponse, error) {
	out := new(GfSpDeductQuotaForBucketMigrateResponse)
	err := c.cc.Invoke(ctx, "/base.types.gfspserver.GfSpDownloadService/GfSpDeductQuotaForBucketMigrate", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// GfSpDownloadServiceServer is the server API for GfSpDownloadService service.
type GfSpDownloadServiceServer interface {
	GfSpDownloadObject(context.Context, *GfSpDownloadObjectRequest) (*GfSpDownloadObjectResponse, error)
	GfSpDownloadPiece(context.Context, *GfSpDownloadPieceRequest) (*GfSpDownloadPieceResponse, error)
	GfSpGetChallengeInfo(context.Context, *GfSpGetChallengeInfoRequest) (*GfSpGetChallengeInfoResponse, error)
	GfSpReimburseQuota(context.Context, *GfSpReimburseQuotaRequest) (*GfSpReimburseQuotaResponse, error)
	GfSpDeductQuotaForBucketMigrate(context.Context, *GfSpDeductQuotaForBucketMigrateRequest) (*GfSpDeductQuotaForBucketMigrateResponse, error)
}

// UnimplementedGfSpDownloadServiceServer can be embedded to have forward compatible implementations.
type UnimplementedGfSpDownloadServiceServer struct {
}

func (*UnimplementedGfSpDownloadServiceServer) GfSpDownloadObject(ctx context.Context, req *GfSpDownloadObjectRequest) (*GfSpDownloadObjectResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GfSpDownloadObject not implemented")
}
func (*UnimplementedGfSpDownloadServiceServer) GfSpDownloadPiece(ctx context.Context, req *GfSpDownloadPieceRequest) (*GfSpDownloadPieceResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GfSpDownloadPiece not implemented")
}
func (*UnimplementedGfSpDownloadServiceServer) GfSpGetChallengeInfo(ctx context.Context, req *GfSpGetChallengeInfoRequest) (*GfSpGetChallengeInfoResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GfSpGetChallengeInfo not implemented")
}
func (*UnimplementedGfSpDownloadServiceServer) GfSpReimburseQuota(ctx context.Context, req *GfSpReimburseQuotaRequest) (*GfSpReimburseQuotaResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GfSpReimburseQuota not implemented")
}
func (*UnimplementedGfSpDownloadServiceServer) GfSpDeductQuotaForBucketMigrate(ctx context.Context, req *GfSpDeductQuotaForBucketMigrateRequest) (*GfSpDeductQuotaForBucketMigrateResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GfSpDeductQuotaForBucketMigrate not implemented")
}

func RegisterGfSpDownloadServiceServer(s grpc1.Server, srv GfSpDownloadServiceServer) {
	s.RegisterService(&_GfSpDownloadService_serviceDesc, srv)
}

func _GfSpDownloadService_GfSpDownloadObject_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GfSpDownloadObjectRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(GfSpDownloadServiceServer).GfSpDownloadObject(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/base.types.gfspserver.GfSpDownloadService/GfSpDownloadObject",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(GfSpDownloadServiceServer).GfSpDownloadObject(ctx, req.(*GfSpDownloadObjectRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _GfSpDownloadService_GfSpDownloadPiece_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GfSpDownloadPieceRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(GfSpDownloadServiceServer).GfSpDownloadPiece(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/base.types.gfspserver.GfSpDownloadService/GfSpDownloadPiece",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(GfSpDownloadServiceServer).GfSpDownloadPiece(ctx, req.(*GfSpDownloadPieceRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _GfSpDownloadService_GfSpGetChallengeInfo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GfSpGetChallengeInfoRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(GfSpDownloadServiceServer).GfSpGetChallengeInfo(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/base.types.gfspserver.GfSpDownloadService/GfSpGetChallengeInfo",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(GfSpDownloadServiceServer).GfSpGetChallengeInfo(ctx, req.(*GfSpGetChallengeInfoRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _GfSpDownloadService_GfSpReimburseQuota_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GfSpReimburseQuotaRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(GfSpDownloadServiceServer).GfSpReimburseQuota(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/base.types.gfspserver.GfSpDownloadService/GfSpReimburseQuota",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(GfSpDownloadServiceServer).GfSpReimburseQuota(ctx, req.(*GfSpReimburseQuotaRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _GfSpDownloadService_GfSpDeductQuotaForBucketMigrate_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GfSpDeductQuotaForBucketMigrateRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(GfSpDownloadServiceServer).GfSpDeductQuotaForBucketMigrate(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/base.types.gfspserver.GfSpDownloadService/GfSpDeductQuotaForBucketMigrate",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(GfSpDownloadServiceServer).GfSpDeductQuotaForBucketMigrate(ctx, req.(*GfSpDeductQuotaForBucketMigrateRequest))
	}
	return interceptor(ctx, in, info, handler)
}

var _GfSpDownloadService_serviceDesc = grpc.ServiceDesc{
	ServiceName: "base.types.gfspserver.GfSpDownloadService",
	HandlerType: (*GfSpDownloadServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "GfSpDownloadObject",
			Handler:    _GfSpDownloadService_GfSpDownloadObject_Handler,
		},
		{
			MethodName: "GfSpDownloadPiece",
			Handler:    _GfSpDownloadService_GfSpDownloadPiece_Handler,
		},
		{
			MethodName: "GfSpGetChallengeInfo",
			Handler:    _GfSpDownloadService_GfSpGetChallengeInfo_Handler,
		},
		{
			MethodName: "GfSpReimburseQuota",
			Handler:    _GfSpDownloadService_GfSpReimburseQuota_Handler,
		},
		{
			MethodName: "GfSpDeductQuotaForBucketMigrate",
			Handler:    _GfSpDownloadService_GfSpDeductQuotaForBucketMigrate_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "base/types/gfspserver/download.proto",
}

func (m *GfSpDownloadObjectRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *GfSpDownloadObjectRequest) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *GfSpDownloadObjectRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.DownloadObjectTask != nil {
		{
			size, err := m.DownloadObjectTask.MarshalToSizedBuffer(dAtA[:i])
			if err != nil {
				return 0, err
			}
			i -= size
			i = encodeVarintDownload(dAtA, i, uint64(size))
		}
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *GfSpDownloadObjectResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *GfSpDownloadObjectResponse) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *GfSpDownloadObjectResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if len(m.Data) > 0 {
		i -= len(m.Data)
		copy(dAtA[i:], m.Data)
		i = encodeVarintDownload(dAtA, i, uint64(len(m.Data)))
		i--
		dAtA[i] = 0x12
	}
	if m.Err != nil {
		{
			size, err := m.Err.MarshalToSizedBuffer(dAtA[:i])
			if err != nil {
				return 0, err
			}
			i -= size
			i = encodeVarintDownload(dAtA, i, uint64(size))
		}
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *GfSpDownloadPieceRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *GfSpDownloadPieceRequest) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *GfSpDownloadPieceRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.DownloadPieceTask != nil {
		{
			size, err := m.DownloadPieceTask.MarshalToSizedBuffer(dAtA[:i])
			if err != nil {
				return 0, err
			}
			i -= size
			i = encodeVarintDownload(dAtA, i, uint64(size))
		}
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *GfSpDownloadPieceResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *GfSpDownloadPieceResponse) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *GfSpDownloadPieceResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if len(m.Data) > 0 {
		i -= len(m.Data)
		copy(dAtA[i:], m.Data)
		i = encodeVarintDownload(dAtA, i, uint64(len(m.Data)))
		i--
		dAtA[i] = 0x12
	}
	if m.Err != nil {
		{
			size, err := m.Err.MarshalToSizedBuffer(dAtA[:i])
			if err != nil {
				return 0, err
			}
			i -= size
			i = encodeVarintDownload(dAtA, i, uint64(size))
		}
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *GfSpGetChallengeInfoRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *GfSpGetChallengeInfoRequest) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *GfSpGetChallengeInfoRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.ChallengePieceTask != nil {
		{
			size, err := m.ChallengePieceTask.MarshalToSizedBuffer(dAtA[:i])
			if err != nil {
				return 0, err
			}
			i -= size
			i = encodeVarintDownload(dAtA, i, uint64(size))
		}
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *GfSpGetChallengeInfoResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *GfSpGetChallengeInfoResponse) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *GfSpGetChallengeInfoResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if len(m.Checksums) > 0 {
		for iNdEx := len(m.Checksums) - 1; iNdEx >= 0; iNdEx-- {
			i -= len(m.Checksums[iNdEx])
			copy(dAtA[i:], m.Checksums[iNdEx])
			i = encodeVarintDownload(dAtA, i, uint64(len(m.Checksums[iNdEx])))
			i--
			dAtA[i] = 0x22
		}
	}
	if len(m.IntegrityHash) > 0 {
		i -= len(m.IntegrityHash)
		copy(dAtA[i:], m.IntegrityHash)
		i = encodeVarintDownload(dAtA, i, uint64(len(m.IntegrityHash)))
		i--
		dAtA[i] = 0x1a
	}
	if len(m.Data) > 0 {
		i -= len(m.Data)
		copy(dAtA[i:], m.Data)
		i = encodeVarintDownload(dAtA, i, uint64(len(m.Data)))
		i--
		dAtA[i] = 0x12
	}
	if m.Err != nil {
		{
			size, err := m.Err.MarshalToSizedBuffer(dAtA[:i])
			if err != nil {
				return 0, err
			}
			i -= size
			i = encodeVarintDownload(dAtA, i, uint64(size))
		}
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *GfSpReimburseQuotaRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *GfSpReimburseQuotaRequest) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *GfSpReimburseQuotaRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if len(m.YearMonth) > 0 {
		i -= len(m.YearMonth)
		copy(dAtA[i:], m.YearMonth)
		i = encodeVarintDownload(dAtA, i, uint64(len(m.YearMonth)))
		i--
		dAtA[i] = 0x1a
	}
	if m.ExtraQuota != 0 {
		i = encodeVarintDownload(dAtA, i, uint64(m.ExtraQuota))
		i--
		dAtA[i] = 0x10
	}
	if m.BucketId != 0 {
		i = encodeVarintDownload(dAtA, i, uint64(m.BucketId))
		i--
		dAtA[i] = 0x8
	}
	return len(dAtA) - i, nil
}

func (m *GfSpReimburseQuotaResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *GfSpReimburseQuotaResponse) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *GfSpReimburseQuotaResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.Err != nil {
		{
			size, err := m.Err.MarshalToSizedBuffer(dAtA[:i])
			if err != nil {
				return 0, err
			}
			i -= size
			i = encodeVarintDownload(dAtA, i, uint64(size))
		}
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *GfSpDeductQuotaForBucketMigrateRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *GfSpDeductQuotaForBucketMigrateRequest) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *GfSpDeductQuotaForBucketMigrateRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if len(m.YearMonth) > 0 {
		i -= len(m.YearMonth)
		copy(dAtA[i:], m.YearMonth)
		i = encodeVarintDownload(dAtA, i, uint64(len(m.YearMonth)))
		i--
		dAtA[i] = 0x1a
	}
	if m.DeductQuota != 0 {
		i = encodeVarintDownload(dAtA, i, uint64(m.DeductQuota))
		i--
		dAtA[i] = 0x10
	}
	if m.BucketId != 0 {
		i = encodeVarintDownload(dAtA, i, uint64(m.BucketId))
		i--
		dAtA[i] = 0x8
	}
	return len(dAtA) - i, nil
}

func (m *GfSpDeductQuotaForBucketMigrateResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *GfSpDeductQuotaForBucketMigrateResponse) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *GfSpDeductQuotaForBucketMigrateResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.Err != nil {
		{
			size, err := m.Err.MarshalToSizedBuffer(dAtA[:i])
			if err != nil {
				return 0, err
			}
			i -= size
			i = encodeVarintDownload(dAtA, i, uint64(size))
		}
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func encodeVarintDownload(dAtA []byte, offset int, v uint64) int {
	offset -= sovDownload(v)
	base := offset
	for v >= 1<<7 {
		dAtA[offset] = uint8(v&0x7f | 0x80)
		v >>= 7
		offset++
	}
	dAtA[offset] = uint8(v)
	return base
}
func (m *GfSpDownloadObjectRequest) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.DownloadObjectTask != nil {
		l = m.DownloadObjectTask.Size()
		n += 1 + l + sovDownload(uint64(l))
	}
	return n
}

func (m *GfSpDownloadObjectResponse) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.Err != nil {
		l = m.Err.Size()
		n += 1 + l + sovDownload(uint64(l))
	}
	l = len(m.Data)
	if l > 0 {
		n += 1 + l + sovDownload(uint64(l))
	}
	return n
}

func (m *GfSpDownloadPieceRequest) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.DownloadPieceTask != nil {
		l = m.DownloadPieceTask.Size()
		n += 1 + l + sovDownload(uint64(l))
	}
	return n
}

func (m *GfSpDownloadPieceResponse) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.Err != nil {
		l = m.Err.Size()
		n += 1 + l + sovDownload(uint64(l))
	}
	l = len(m.Data)
	if l > 0 {
		n += 1 + l + sovDownload(uint64(l))
	}
	return n
}

func (m *GfSpGetChallengeInfoRequest) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.ChallengePieceTask != nil {
		l = m.ChallengePieceTask.Size()
		n += 1 + l + sovDownload(uint64(l))
	}
	return n
}

func (m *GfSpGetChallengeInfoResponse) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.Err != nil {
		l = m.Err.Size()
		n += 1 + l + sovDownload(uint64(l))
	}
	l = len(m.Data)
	if l > 0 {
		n += 1 + l + sovDownload(uint64(l))
	}
	l = len(m.IntegrityHash)
	if l > 0 {
		n += 1 + l + sovDownload(uint64(l))
	}
	if len(m.Checksums) > 0 {
		for _, b := range m.Checksums {
			l = len(b)
			n += 1 + l + sovDownload(uint64(l))
		}
	}
	return n
}

func (m *GfSpReimburseQuotaRequest) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.BucketId != 0 {
		n += 1 + sovDownload(uint64(m.BucketId))
	}
	if m.ExtraQuota != 0 {
		n += 1 + sovDownload(uint64(m.ExtraQuota))
	}
	l = len(m.YearMonth)
	if l > 0 {
		n += 1 + l + sovDownload(uint64(l))
	}
	return n
}

func (m *GfSpReimburseQuotaResponse) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.Err != nil {
		l = m.Err.Size()
		n += 1 + l + sovDownload(uint64(l))
	}
	return n
}

func (m *GfSpDeductQuotaForBucketMigrateRequest) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.BucketId != 0 {
		n += 1 + sovDownload(uint64(m.BucketId))
	}
	if m.DeductQuota != 0 {
		n += 1 + sovDownload(uint64(m.DeductQuota))
	}
	l = len(m.YearMonth)
	if l > 0 {
		n += 1 + l + sovDownload(uint64(l))
	}
	return n
}

func (m *GfSpDeductQuotaForBucketMigrateResponse) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.Err != nil {
		l = m.Err.Size()
		n += 1 + l + sovDownload(uint64(l))
	}
	return n
}

func sovDownload(x uint64) (n int) {
	return (math_bits.Len64(x|1) + 6) / 7
}
func sozDownload(x uint64) (n int) {
	return sovDownload(uint64((x << 1) ^ uint64((int64(x) >> 63))))
}
func (m *GfSpDownloadObjectRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowDownload
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: GfSpDownloadObjectRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: GfSpDownloadObjectRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field DownloadObjectTask", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.DownloadObjectTask == nil {
				m.DownloadObjectTask = &gfsptask.GfSpDownloadObjectTask{}
			}
			if err := m.DownloadObjectTask.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipDownload(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthDownload
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *GfSpDownloadObjectResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowDownload
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: GfSpDownloadObjectResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: GfSpDownloadObjectResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Err", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.Err == nil {
				m.Err = &gfsperrors.GfSpError{}
			}
			if err := m.Err.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
			if m.Data == nil {
				m.Data = []byte{}
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipDownload(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthDownload
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *GfSpDownloadPieceRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowDownload
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: GfSpDownloadPieceRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: GfSpDownloadPieceRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field DownloadPieceTask", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.DownloadPieceTask == nil {
				m.DownloadPieceTask = &gfsptask.GfSpDownloadPieceTask{}
			}
			if err := m.DownloadPieceTask.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipDownload(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthDownload
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *GfSpDownloadPieceResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowDownload
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: GfSpDownloadPieceResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: GfSpDownloadPieceResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Err", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.Err == nil {
				m.Err = &gfsperrors.GfSpError{}
			}
			if err := m.Err.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
			if m.Data == nil {
				m.Data = []byte{}
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipDownload(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthDownload
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *GfSpGetChallengeInfoRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowDownload
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: GfSpGetChallengeInfoRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: GfSpGetChallengeInfoRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ChallengePieceTask", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ChallengePieceTask == nil {
				m.ChallengePieceTask = &gfsptask.GfSpChallengePieceTask{}
			}
			if err := m.ChallengePieceTask.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipDownload(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthDownload
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *GfSpGetChallengeInfoResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowDownload
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: GfSpGetChallengeInfoResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: GfSpGetChallengeInfoResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Err", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.Err == nil {
				m.Err = &gfsperrors.GfSpError{}
			}
			if err := m.Err.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
			if m.Data == nil {
				m.Data = []byte{}
			}
			iNdEx = postIndex
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field IntegrityHash", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.IntegrityHash = append(m.IntegrityHash[:0], dAtA[iNdEx:postIndex]...)
			if m.IntegrityHash == nil {
				m.IntegrityHash = []byte{}
			}
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Checksums", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Checksums = append(m.Checksums, make([]byte, postIndex-iNdEx))
			copy(m.Checksums[len(m.Checksums)-1], dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipDownload(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthDownload
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *GfSpReimburseQuotaRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowDownload
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: GfSpReimburseQuotaRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: GfSpReimburseQuotaRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field BucketId", wireType)
			}
			m.BucketId = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.BucketId |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field ExtraQuota", wireType)
			}
			m.ExtraQuota = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.ExtraQuota |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field YearMonth", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.YearMonth = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipDownload(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthDownload
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *GfSpReimburseQuotaResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowDownload
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: GfSpReimburseQuotaResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: GfSpReimburseQuotaResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Err", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.Err == nil {
				m.Err = &gfsperrors.GfSpError{}
			}
			if err := m.Err.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipDownload(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthDownload
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *GfSpDeductQuotaForBucketMigrateRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowDownload
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: GfSpDeductQuotaForBucketMigrateRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: GfSpDeductQuotaForBucketMigrateRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field BucketId", wireType)
			}
			m.BucketId = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.BucketId |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field DeductQuota", wireType)
			}
			m.DeductQuota = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.DeductQuota |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field YearMonth", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.YearMonth = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipDownload(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthDownload
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *GfSpDeductQuotaForBucketMigrateResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowDownload
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: GfSpDeductQuotaForBucketMigrateResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: GfSpDeductQuotaForBucketMigrateResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Err", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthDownload
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthDownload
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.Err == nil {
				m.Err = &gfsperrors.GfSpError{}
			}
			if err := m.Err.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipDownload(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthDownload
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func skipDownload(dAtA []byte) (n int, err error) {
	l := len(dAtA)
	iNdEx := 0
	depth := 0
	for iNdEx < l {
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return 0, ErrIntOverflowDownload
			}
			if iNdEx >= l {
				return 0, io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		wireType := int(wire & 0x7)
		switch wireType {
		case 0:
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return 0, ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return 0, io.ErrUnexpectedEOF
				}
				iNdEx++
				if dAtA[iNdEx-1] < 0x80 {
					break
				}
			}
		case 1:
			iNdEx += 8
		case 2:
			var length int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return 0, ErrIntOverflowDownload
				}
				if iNdEx >= l {
					return 0, io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				length |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if length < 0 {
				return 0, ErrInvalidLengthDownload
			}
			iNdEx += length
		case 3:
			depth++
		case 4:
			if depth == 0 {
				return 0, ErrUnexpectedEndOfGroupDownload
			}
			depth--
		case 5:
			iNdEx += 4
		default:
			return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
		}
		if iNdEx < 0 {
			return 0, ErrInvalidLengthDownload
		}
		if depth == 0 {
			return iNdEx, nil
		}
	}
	return 0, io.ErrUnexpectedEOF
}

var (
	ErrInvalidLengthDownload        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowDownload          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupDownload = fmt.Errorf("proto: unexpected end of group")
)
