// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.11
// 	protoc        (unknown)
// source: gitmirror/v1/gitmirror.proto

package gitmirrorv1

import (
	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
	timestamppb "google.golang.org/protobuf/types/known/timestamppb"
	reflect "reflect"
	sync "sync"
	unsafe "unsafe"
)

const (
	// Verify that this generated code is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
	// Verify that runtime/protoimpl is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)

type DiffRequest_ComparisonType int32

const (
	DiffRequest_COMPARISON_TYPE_UNSPECIFIED DiffRequest_ComparisonType = 0
	// Corresponds to the BASE..HEAD syntax that only returns any commits that
	// are in HEAD but not in BASE.
	DiffRequest_COMPARISON_TYPE_ONLY_IN_HEAD DiffRequest_ComparisonType = 1
	// Corresponds to the BASE...HEAD syntax that returns any commits that are
	// not in both BASE and HEAD.
	DiffRequest_COMPARISON_TYPE_INTERSECTION DiffRequest_ComparisonType = 2
)

// Enum value maps for DiffRequest_ComparisonType.
var (
	DiffRequest_ComparisonType_name = map[int32]string{
		0: "COMPARISON_TYPE_UNSPECIFIED",
		1: "COMPARISON_TYPE_ONLY_IN_HEAD",
		2: "COMPARISON_TYPE_INTERSECTION",
	}
	DiffRequest_ComparisonType_value = map[string]int32{
		"COMPARISON_TYPE_UNSPECIFIED":  0,
		"COMPARISON_TYPE_ONLY_IN_HEAD": 1,
		"COMPARISON_TYPE_INTERSECTION": 2,
	}
)

func (x DiffRequest_ComparisonType) Enum() *DiffRequest_ComparisonType {
	p := new(DiffRequest_ComparisonType)
	*p = x
	return p
}

func (x DiffRequest_ComparisonType) String() string {
	return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}

func (DiffRequest_ComparisonType) Descriptor() protoreflect.EnumDescriptor {
	return file_gitmirror_v1_gitmirror_proto_enumTypes[0].Descriptor()
}

func (DiffRequest_ComparisonType) Type() protoreflect.EnumType {
	return &file_gitmirror_v1_gitmirror_proto_enumTypes[0]
}

func (x DiffRequest_ComparisonType) Number() protoreflect.EnumNumber {
	return protoreflect.EnumNumber(x)
}

// Deprecated: Use DiffRequest_ComparisonType.Descriptor instead.
func (DiffRequest_ComparisonType) EnumDescriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{4, 0}
}

type CommitLogRequest struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// repo DID
	Repo string `protobuf:"bytes,1,opt,name=repo,proto3" json:"repo,omitempty"`
	// Ranges to include in the git log (revspec, "A..B", "A...B", etc.).
	// At least one range, or all_refs must be specified.
	Ranges [][]byte `protobuf:"bytes,2,rep,name=ranges,proto3" json:"ranges,omitempty"`
	// If true, all refs are searched for commits.
	// Must not be true when ranges are given.
	AllRefs bool `protobuf:"varint,3,opt,name=all_refs,json=allRefs,proto3" json:"all_refs,omitempty"`
	// After is an optional parameter to specify the earliest commit to consider.
	After *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=after,proto3" json:"after,omitempty"`
	// Before is an optional parameter to specify the latest commit to consider.
	Before *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=before,proto3" json:"before,omitempty"`
	// MaxCommits is an optional parameter to specify the maximum number of commits
	// to return. If max_commits is 0, all commits that match the criteria will be
	// returned.
	MaxCommits uint32 `protobuf:"varint,6,opt,name=max_commits,json=maxCommits,proto3" json:"max_commits,omitempty"`
	// Skip is an optional parameter to specify the number of commits to skip.
	// This can be used to implement a poor mans pagination.
	Skip          uint32 `protobuf:"varint,7,opt,name=skip,proto3" json:"skip,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *CommitLogRequest) Reset() {
	*x = CommitLogRequest{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[0]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *CommitLogRequest) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*CommitLogRequest) ProtoMessage() {}

func (x *CommitLogRequest) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[0]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use CommitLogRequest.ProtoReflect.Descriptor instead.
func (*CommitLogRequest) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{0}
}

func (x *CommitLogRequest) GetRepo() string {
	if x != nil {
		return x.Repo
	}
	return ""
}

func (x *CommitLogRequest) GetRanges() [][]byte {
	if x != nil {
		return x.Ranges
	}
	return nil
}

func (x *CommitLogRequest) GetAllRefs() bool {
	if x != nil {
		return x.AllRefs
	}
	return false
}

func (x *CommitLogRequest) GetAfter() *timestamppb.Timestamp {
	if x != nil {
		return x.After
	}
	return nil
}

func (x *CommitLogRequest) GetBefore() *timestamppb.Timestamp {
	if x != nil {
		return x.Before
	}
	return nil
}

func (x *CommitLogRequest) GetMaxCommits() uint32 {
	if x != nil {
		return x.MaxCommits
	}
	return 0
}

func (x *CommitLogRequest) GetSkip() uint32 {
	if x != nil {
		return x.Skip
	}
	return 0
}

type CommitLogResponse struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Commits       []*GitCommit           `protobuf:"bytes,1,rep,name=commits,proto3" json:"commits,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *CommitLogResponse) Reset() {
	*x = CommitLogResponse{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[1]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *CommitLogResponse) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*CommitLogResponse) ProtoMessage() {}

func (x *CommitLogResponse) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[1]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use CommitLogResponse.ProtoReflect.Descriptor instead.
func (*CommitLogResponse) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{1}
}

func (x *CommitLogResponse) GetCommits() []*GitCommit {
	if x != nil {
		return x.Commits
	}
	return nil
}

type GetBlobRequest struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// repo carries the DID as a string.
	Repo string `protobuf:"bytes,1,opt,name=repo,proto3" json:"repo,omitempty"`
	// oid is the blob object id (hex).
	Oid           string `protobuf:"bytes,2,opt,name=oid,proto3" json:"oid,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *GetBlobRequest) Reset() {
	*x = GetBlobRequest{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[2]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *GetBlobRequest) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*GetBlobRequest) ProtoMessage() {}

func (x *GetBlobRequest) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[2]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use GetBlobRequest.ProtoReflect.Descriptor instead.
func (*GetBlobRequest) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{2}
}

func (x *GetBlobRequest) GetRepo() string {
	if x != nil {
		return x.Repo
	}
	return ""
}

func (x *GetBlobRequest) GetOid() string {
	if x != nil {
		return x.Oid
	}
	return ""
}

type BlobChunk struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Data          []byte                 `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *BlobChunk) Reset() {
	*x = BlobChunk{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[3]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *BlobChunk) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*BlobChunk) ProtoMessage() {}

func (x *BlobChunk) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[3]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use BlobChunk.ProtoReflect.Descriptor instead.
func (*BlobChunk) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{3}
}

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

type DiffRequest struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// repo carries the DID as a string; parsing/validation is an impl detail.
	Repo string `protobuf:"bytes,1,opt,name=repo,proto3" json:"repo,omitempty"`
	// base_rev_spec/head_rev_spec are commit-ish ref strings.
	// base_rev_spec is optional; when unset, diff head against head's first parent.
	BaseRevSpec    []byte                     `protobuf:"bytes,2,opt,name=base_rev_spec,json=baseRevSpec,proto3,oneof" json:"base_rev_spec,omitempty"`
	HeadRevSpec    []byte                     `protobuf:"bytes,3,opt,name=head_rev_spec,json=headRevSpec,proto3" json:"head_rev_spec,omitempty"`
	ComparisonType DiffRequest_ComparisonType `protobuf:"varint,4,opt,name=comparison_type,json=comparisonType,proto3,enum=gitmirror.v1.DiffRequest_ComparisonType" json:"comparison_type,omitempty"`
	unknownFields  protoimpl.UnknownFields
	sizeCache      protoimpl.SizeCache
}

func (x *DiffRequest) Reset() {
	*x = DiffRequest{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[4]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *DiffRequest) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*DiffRequest) ProtoMessage() {}

func (x *DiffRequest) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[4]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use DiffRequest.ProtoReflect.Descriptor instead.
func (*DiffRequest) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{4}
}

func (x *DiffRequest) GetRepo() string {
	if x != nil {
		return x.Repo
	}
	return ""
}

func (x *DiffRequest) GetBaseRevSpec() []byte {
	if x != nil {
		return x.BaseRevSpec
	}
	return nil
}

func (x *DiffRequest) GetHeadRevSpec() []byte {
	if x != nil {
		return x.HeadRevSpec
	}
	return nil
}

func (x *DiffRequest) GetComparisonType() DiffRequest_ComparisonType {
	if x != nil {
		return x.ComparisonType
	}
	return DiffRequest_COMPARISON_TYPE_UNSPECIFIED
}

type InterdiffRequest struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// repo carries the DID as a string.
	Repo string `protobuf:"bytes,1,opt,name=repo,proto3" json:"repo,omitempty"`
	// Old patch range (from_base..from_head) and new patch range (to_base..to_head).
	FromBase      []byte `protobuf:"bytes,2,opt,name=from_base,json=fromBase,proto3" json:"from_base,omitempty"`
	FromHead      []byte `protobuf:"bytes,3,opt,name=from_head,json=fromHead,proto3" json:"from_head,omitempty"`
	ToBase        []byte `protobuf:"bytes,4,opt,name=to_base,json=toBase,proto3" json:"to_base,omitempty"`
	ToHead        []byte `protobuf:"bytes,5,opt,name=to_head,json=toHead,proto3" json:"to_head,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *InterdiffRequest) Reset() {
	*x = InterdiffRequest{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[5]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *InterdiffRequest) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*InterdiffRequest) ProtoMessage() {}

func (x *InterdiffRequest) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[5]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use InterdiffRequest.ProtoReflect.Descriptor instead.
func (*InterdiffRequest) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{5}
}

func (x *InterdiffRequest) GetRepo() string {
	if x != nil {
		return x.Repo
	}
	return ""
}

func (x *InterdiffRequest) GetFromBase() []byte {
	if x != nil {
		return x.FromBase
	}
	return nil
}

func (x *InterdiffRequest) GetFromHead() []byte {
	if x != nil {
		return x.FromHead
	}
	return nil
}

func (x *InterdiffRequest) GetToBase() []byte {
	if x != nil {
		return x.ToBase
	}
	return nil
}

func (x *InterdiffRequest) GetToHead() []byte {
	if x != nil {
		return x.ToHead
	}
	return nil
}

type FileContent struct {
	state       protoimpl.MessageState `protogen:"open.v1"`
	Path        string                 `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
	Oid         string                 `protobuf:"bytes,2,opt,name=oid,proto3" json:"oid,omitempty"`
	Size        uint64                 `protobuf:"varint,3,opt,name=size,proto3" json:"size,omitempty"`
	IsBinary    bool                   `protobuf:"varint,4,opt,name=is_binary,json=isBinary,proto3" json:"is_binary,omitempty"`
	IsSubmodule bool                   `protobuf:"varint,5,opt,name=is_submodule,json=isSubmodule,proto3" json:"is_submodule,omitempty"`
	// Raw file bytes, inlined when the oid is not fetchable by the client
	// (e.g. interdiff)
	Content       []byte `protobuf:"bytes,6,opt,name=content,proto3,oneof" json:"content,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *FileContent) Reset() {
	*x = FileContent{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[6]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *FileContent) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*FileContent) ProtoMessage() {}

func (x *FileContent) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[6]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use FileContent.ProtoReflect.Descriptor instead.
func (*FileContent) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{6}
}

func (x *FileContent) GetPath() string {
	if x != nil {
		return x.Path
	}
	return ""
}

func (x *FileContent) GetOid() string {
	if x != nil {
		return x.Oid
	}
	return ""
}

func (x *FileContent) GetSize() uint64 {
	if x != nil {
		return x.Size
	}
	return 0
}

func (x *FileContent) GetIsBinary() bool {
	if x != nil {
		return x.IsBinary
	}
	return false
}

func (x *FileContent) GetIsSubmodule() bool {
	if x != nil {
		return x.IsSubmodule
	}
	return false
}

func (x *FileContent) GetContent() []byte {
	if x != nil {
		return x.Content
	}
	return nil
}

// One aligned line pair; a side is absent (None) when unset.
type LinePair struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Lhs           *uint32                `protobuf:"varint,1,opt,name=lhs,proto3,oneof" json:"lhs,omitempty"`
	Rhs           *uint32                `protobuf:"varint,2,opt,name=rhs,proto3,oneof" json:"rhs,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *LinePair) Reset() {
	*x = LinePair{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[7]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *LinePair) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*LinePair) ProtoMessage() {}

func (x *LinePair) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[7]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use LinePair.ProtoReflect.Descriptor instead.
func (*LinePair) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{7}
}

func (x *LinePair) GetLhs() uint32 {
	if x != nil && x.Lhs != nil {
		return *x.Lhs
	}
	return 0
}

func (x *LinePair) GetRhs() uint32 {
	if x != nil && x.Rhs != nil {
		return *x.Rhs
	}
	return 0
}

type Hunk struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// LineNumber (u32) sets containing novel content per side.
	NovelLhs      []uint32    `protobuf:"varint,1,rep,packed,name=novel_lhs,json=novelLhs,proto3" json:"novel_lhs,omitempty"`
	NovelRhs      []uint32    `protobuf:"varint,2,rep,packed,name=novel_rhs,json=novelRhs,proto3" json:"novel_rhs,omitempty"`
	Lines         []*LinePair `protobuf:"bytes,3,rep,name=lines,proto3" json:"lines,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *Hunk) Reset() {
	*x = Hunk{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[8]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *Hunk) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*Hunk) ProtoMessage() {}

func (x *Hunk) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[8]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use Hunk.ProtoReflect.Descriptor instead.
func (*Hunk) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{8}
}

func (x *Hunk) GetNovelLhs() []uint32 {
	if x != nil {
		return x.NovelLhs
	}
	return nil
}

func (x *Hunk) GetNovelRhs() []uint32 {
	if x != nil {
		return x.NovelRhs
	}
	return nil
}

func (x *Hunk) GetLines() []*LinePair {
	if x != nil {
		return x.Lines
	}
	return nil
}

// Number of bytes per side when the files differ (Rust Option<(usize, usize)>).
type ByteChanges struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Lhs           uint64                 `protobuf:"varint,1,opt,name=lhs,proto3" json:"lhs,omitempty"`
	Rhs           uint64                 `protobuf:"varint,2,opt,name=rhs,proto3" json:"rhs,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *ByteChanges) Reset() {
	*x = ByteChanges{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[9]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *ByteChanges) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*ByteChanges) ProtoMessage() {}

func (x *ByteChanges) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[9]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use ByteChanges.ProtoReflect.Descriptor instead.
func (*ByteChanges) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{9}
}

func (x *ByteChanges) GetLhs() uint64 {
	if x != nil {
		return x.Lhs
	}
	return 0
}

func (x *ByteChanges) GetRhs() uint64 {
	if x != nil {
		return x.Rhs
	}
	return 0
}

type FileDiff struct {
	state               protoimpl.MessageState `protogen:"open.v1"`
	LhsSrc              *FileContent           `protobuf:"bytes,1,opt,name=lhs_src,json=lhsSrc,proto3" json:"lhs_src,omitempty"`
	RhsSrc              *FileContent           `protobuf:"bytes,2,opt,name=rhs_src,json=rhsSrc,proto3" json:"rhs_src,omitempty"`
	Hunks               []*Hunk                `protobuf:"bytes,3,rep,name=hunks,proto3" json:"hunks,omitempty"`
	HasByteChanges      *ByteChanges           `protobuf:"bytes,4,opt,name=has_byte_changes,json=hasByteChanges,proto3,oneof" json:"has_byte_changes,omitempty"`
	HasSyntacticChanges bool                   `protobuf:"varint,5,opt,name=has_syntactic_changes,json=hasSyntacticChanges,proto3" json:"has_syntactic_changes,omitempty"` // TODO: lhs_positions & rhs_positions
	unknownFields       protoimpl.UnknownFields
	sizeCache           protoimpl.SizeCache
}

func (x *FileDiff) Reset() {
	*x = FileDiff{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[10]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *FileDiff) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*FileDiff) ProtoMessage() {}

func (x *FileDiff) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[10]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use FileDiff.ProtoReflect.Descriptor instead.
func (*FileDiff) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{10}
}

func (x *FileDiff) GetLhsSrc() *FileContent {
	if x != nil {
		return x.LhsSrc
	}
	return nil
}

func (x *FileDiff) GetRhsSrc() *FileContent {
	if x != nil {
		return x.RhsSrc
	}
	return nil
}

func (x *FileDiff) GetHunks() []*Hunk {
	if x != nil {
		return x.Hunks
	}
	return nil
}

func (x *FileDiff) GetHasByteChanges() *ByteChanges {
	if x != nil {
		return x.HasByteChanges
	}
	return nil
}

func (x *FileDiff) GetHasSyntacticChanges() bool {
	if x != nil {
		return x.HasSyntacticChanges
	}
	return false
}

type GitCommit struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Oid           string                 `protobuf:"bytes,1,opt,name=oid,proto3" json:"oid,omitempty"`
	Author        *GitSignature          `protobuf:"bytes,2,opt,name=author,proto3" json:"author,omitempty"`
	Committer     *GitSignature          `protobuf:"bytes,3,opt,name=committer,proto3" json:"committer,omitempty"`
	Message       []byte                 `protobuf:"bytes,4,opt,name=message,proto3" json:"message,omitempty"`
	Parents       []string               `protobuf:"bytes,5,rep,name=parents,proto3" json:"parents,omitempty"`
	ExtraHeaders  map[string]string      `protobuf:"bytes,6,rep,name=extra_headers,json=extraHeaders,proto3" json:"extra_headers,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *GitCommit) Reset() {
	*x = GitCommit{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[11]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *GitCommit) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*GitCommit) ProtoMessage() {}

func (x *GitCommit) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[11]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use GitCommit.ProtoReflect.Descriptor instead.
func (*GitCommit) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{11}
}

func (x *GitCommit) GetOid() string {
	if x != nil {
		return x.Oid
	}
	return ""
}

func (x *GitCommit) GetAuthor() *GitSignature {
	if x != nil {
		return x.Author
	}
	return nil
}

func (x *GitCommit) GetCommitter() *GitSignature {
	if x != nil {
		return x.Committer
	}
	return nil
}

func (x *GitCommit) GetMessage() []byte {
	if x != nil {
		return x.Message
	}
	return nil
}

func (x *GitCommit) GetParents() []string {
	if x != nil {
		return x.Parents
	}
	return nil
}

func (x *GitCommit) GetExtraHeaders() map[string]string {
	if x != nil {
		return x.ExtraHeaders
	}
	return nil
}

type GitSignature struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Name          []byte                 `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Email         []byte                 `protobuf:"bytes,2,opt,name=email,proto3" json:"email,omitempty"`
	Date          *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=date,proto3" json:"date,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *GitSignature) Reset() {
	*x = GitSignature{}
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[12]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *GitSignature) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*GitSignature) ProtoMessage() {}

func (x *GitSignature) ProtoReflect() protoreflect.Message {
	mi := &file_gitmirror_v1_gitmirror_proto_msgTypes[12]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use GitSignature.ProtoReflect.Descriptor instead.
func (*GitSignature) Descriptor() ([]byte, []int) {
	return file_gitmirror_v1_gitmirror_proto_rawDescGZIP(), []int{12}
}

func (x *GitSignature) GetName() []byte {
	if x != nil {
		return x.Name
	}
	return nil
}

func (x *GitSignature) GetEmail() []byte {
	if x != nil {
		return x.Email
	}
	return nil
}

func (x *GitSignature) GetDate() *timestamppb.Timestamp {
	if x != nil {
		return x.Date
	}
	return nil
}

var File_gitmirror_v1_gitmirror_proto protoreflect.FileDescriptor

const file_gitmirror_v1_gitmirror_proto_rawDesc = "" +
	"\n" +
	"\x1cgitmirror/v1/gitmirror.proto\x12\fgitmirror.v1\x1a\x1fgoogle/protobuf/timestamp.proto\"\xf4\x01\n" +
	"\x10CommitLogRequest\x12\x12\n" +
	"\x04repo\x18\x01 \x01(\tR\x04repo\x12\x16\n" +
	"\x06ranges\x18\x02 \x03(\fR\x06ranges\x12\x19\n" +
	"\ball_refs\x18\x03 \x01(\bR\aallRefs\x120\n" +
	"\x05after\x18\x04 \x01(\v2\x1a.google.protobuf.TimestampR\x05after\x122\n" +
	"\x06before\x18\x05 \x01(\v2\x1a.google.protobuf.TimestampR\x06before\x12\x1f\n" +
	"\vmax_commits\x18\x06 \x01(\rR\n" +
	"maxCommits\x12\x12\n" +
	"\x04skip\x18\a \x01(\rR\x04skip\"F\n" +
	"\x11CommitLogResponse\x121\n" +
	"\acommits\x18\x01 \x03(\v2\x17.gitmirror.v1.GitCommitR\acommits\"6\n" +
	"\x0eGetBlobRequest\x12\x12\n" +
	"\x04repo\x18\x01 \x01(\tR\x04repo\x12\x10\n" +
	"\x03oid\x18\x02 \x01(\tR\x03oid\"\x1f\n" +
	"\tBlobChunk\x12\x12\n" +
	"\x04data\x18\x01 \x01(\fR\x04data\"\xca\x02\n" +
	"\vDiffRequest\x12\x12\n" +
	"\x04repo\x18\x01 \x01(\tR\x04repo\x12'\n" +
	"\rbase_rev_spec\x18\x02 \x01(\fH\x00R\vbaseRevSpec\x88\x01\x01\x12\"\n" +
	"\rhead_rev_spec\x18\x03 \x01(\fR\vheadRevSpec\x12Q\n" +
	"\x0fcomparison_type\x18\x04 \x01(\x0e2(.gitmirror.v1.DiffRequest.ComparisonTypeR\x0ecomparisonType\"u\n" +
	"\x0eComparisonType\x12\x1f\n" +
	"\x1bCOMPARISON_TYPE_UNSPECIFIED\x10\x00\x12 \n" +
	"\x1cCOMPARISON_TYPE_ONLY_IN_HEAD\x10\x01\x12 \n" +
	"\x1cCOMPARISON_TYPE_INTERSECTION\x10\x02B\x10\n" +
	"\x0e_base_rev_spec\"\x92\x01\n" +
	"\x10InterdiffRequest\x12\x12\n" +
	"\x04repo\x18\x01 \x01(\tR\x04repo\x12\x1b\n" +
	"\tfrom_base\x18\x02 \x01(\fR\bfromBase\x12\x1b\n" +
	"\tfrom_head\x18\x03 \x01(\fR\bfromHead\x12\x17\n" +
	"\ato_base\x18\x04 \x01(\fR\x06toBase\x12\x17\n" +
	"\ato_head\x18\x05 \x01(\fR\x06toHead\"\xb2\x01\n" +
	"\vFileContent\x12\x12\n" +
	"\x04path\x18\x01 \x01(\tR\x04path\x12\x10\n" +
	"\x03oid\x18\x02 \x01(\tR\x03oid\x12\x12\n" +
	"\x04size\x18\x03 \x01(\x04R\x04size\x12\x1b\n" +
	"\tis_binary\x18\x04 \x01(\bR\bisBinary\x12!\n" +
	"\fis_submodule\x18\x05 \x01(\bR\visSubmodule\x12\x1d\n" +
	"\acontent\x18\x06 \x01(\fH\x00R\acontent\x88\x01\x01B\n" +
	"\n" +
	"\b_content\"H\n" +
	"\bLinePair\x12\x15\n" +
	"\x03lhs\x18\x01 \x01(\rH\x00R\x03lhs\x88\x01\x01\x12\x15\n" +
	"\x03rhs\x18\x02 \x01(\rH\x01R\x03rhs\x88\x01\x01B\x06\n" +
	"\x04_lhsB\x06\n" +
	"\x04_rhs\"n\n" +
	"\x04Hunk\x12\x1b\n" +
	"\tnovel_lhs\x18\x01 \x03(\rR\bnovelLhs\x12\x1b\n" +
	"\tnovel_rhs\x18\x02 \x03(\rR\bnovelRhs\x12,\n" +
	"\x05lines\x18\x03 \x03(\v2\x16.gitmirror.v1.LinePairR\x05lines\"1\n" +
	"\vByteChanges\x12\x10\n" +
	"\x03lhs\x18\x01 \x01(\x04R\x03lhs\x12\x10\n" +
	"\x03rhs\x18\x02 \x01(\x04R\x03rhs\"\xaf\x02\n" +
	"\bFileDiff\x122\n" +
	"\alhs_src\x18\x01 \x01(\v2\x19.gitmirror.v1.FileContentR\x06lhsSrc\x122\n" +
	"\arhs_src\x18\x02 \x01(\v2\x19.gitmirror.v1.FileContentR\x06rhsSrc\x12(\n" +
	"\x05hunks\x18\x03 \x03(\v2\x12.gitmirror.v1.HunkR\x05hunks\x12H\n" +
	"\x10has_byte_changes\x18\x04 \x01(\v2\x19.gitmirror.v1.ByteChangesH\x00R\x0ehasByteChanges\x88\x01\x01\x122\n" +
	"\x15has_syntactic_changes\x18\x05 \x01(\bR\x13hasSyntacticChangesB\x13\n" +
	"\x11_has_byte_changes\"\xd0\x02\n" +
	"\tGitCommit\x12\x10\n" +
	"\x03oid\x18\x01 \x01(\tR\x03oid\x122\n" +
	"\x06author\x18\x02 \x01(\v2\x1a.gitmirror.v1.GitSignatureR\x06author\x128\n" +
	"\tcommitter\x18\x03 \x01(\v2\x1a.gitmirror.v1.GitSignatureR\tcommitter\x12\x18\n" +
	"\amessage\x18\x04 \x01(\fR\amessage\x12\x18\n" +
	"\aparents\x18\x05 \x03(\tR\aparents\x12N\n" +
	"\rextra_headers\x18\x06 \x03(\v2).gitmirror.v1.GitCommit.ExtraHeadersEntryR\fextraHeaders\x1a?\n" +
	"\x11ExtraHeadersEntry\x12\x10\n" +
	"\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" +
	"\x05value\x18\x02 \x01(\tR\x05value:\x028\x01\"h\n" +
	"\fGitSignature\x12\x12\n" +
	"\x04name\x18\x01 \x01(\fR\x04name\x12\x14\n" +
	"\x05email\x18\x02 \x01(\fR\x05email\x12.\n" +
	"\x04date\x18\x03 \x01(\v2\x1a.google.protobuf.TimestampR\x04date2\xaa\x02\n" +
	"\x10GitMirrorService\x12N\n" +
	"\tCommitLog\x12\x1e.gitmirror.v1.CommitLogRequest\x1a\x1f.gitmirror.v1.CommitLogResponse0\x01\x12B\n" +
	"\aGetBlob\x12\x1c.gitmirror.v1.GetBlobRequest\x1a\x17.gitmirror.v1.BlobChunk0\x01\x12;\n" +
	"\x04Diff\x12\x19.gitmirror.v1.DiffRequest\x1a\x16.gitmirror.v1.FileDiff0\x01\x12E\n" +
	"\tInterdiff\x12\x1e.gitmirror.v1.InterdiffRequest\x1a\x16.gitmirror.v1.FileDiff0\x01B2Z0tangled.org/core/gitmirror/proto/gen;gitmirrorv1b\x06proto3"

var (
	file_gitmirror_v1_gitmirror_proto_rawDescOnce sync.Once
	file_gitmirror_v1_gitmirror_proto_rawDescData []byte
)

func file_gitmirror_v1_gitmirror_proto_rawDescGZIP() []byte {
	file_gitmirror_v1_gitmirror_proto_rawDescOnce.Do(func() {
		file_gitmirror_v1_gitmirror_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_gitmirror_v1_gitmirror_proto_rawDesc), len(file_gitmirror_v1_gitmirror_proto_rawDesc)))
	})
	return file_gitmirror_v1_gitmirror_proto_rawDescData
}

var file_gitmirror_v1_gitmirror_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
var file_gitmirror_v1_gitmirror_proto_msgTypes = make([]protoimpl.MessageInfo, 14)
var file_gitmirror_v1_gitmirror_proto_goTypes = []any{
	(DiffRequest_ComparisonType)(0), // 0: gitmirror.v1.DiffRequest.ComparisonType
	(*CommitLogRequest)(nil),        // 1: gitmirror.v1.CommitLogRequest
	(*CommitLogResponse)(nil),       // 2: gitmirror.v1.CommitLogResponse
	(*GetBlobRequest)(nil),          // 3: gitmirror.v1.GetBlobRequest
	(*BlobChunk)(nil),               // 4: gitmirror.v1.BlobChunk
	(*DiffRequest)(nil),             // 5: gitmirror.v1.DiffRequest
	(*InterdiffRequest)(nil),        // 6: gitmirror.v1.InterdiffRequest
	(*FileContent)(nil),             // 7: gitmirror.v1.FileContent
	(*LinePair)(nil),                // 8: gitmirror.v1.LinePair
	(*Hunk)(nil),                    // 9: gitmirror.v1.Hunk
	(*ByteChanges)(nil),             // 10: gitmirror.v1.ByteChanges
	(*FileDiff)(nil),                // 11: gitmirror.v1.FileDiff
	(*GitCommit)(nil),               // 12: gitmirror.v1.GitCommit
	(*GitSignature)(nil),            // 13: gitmirror.v1.GitSignature
	nil,                             // 14: gitmirror.v1.GitCommit.ExtraHeadersEntry
	(*timestamppb.Timestamp)(nil),   // 15: google.protobuf.Timestamp
}
var file_gitmirror_v1_gitmirror_proto_depIdxs = []int32{
	15, // 0: gitmirror.v1.CommitLogRequest.after:type_name -> google.protobuf.Timestamp
	15, // 1: gitmirror.v1.CommitLogRequest.before:type_name -> google.protobuf.Timestamp
	12, // 2: gitmirror.v1.CommitLogResponse.commits:type_name -> gitmirror.v1.GitCommit
	0,  // 3: gitmirror.v1.DiffRequest.comparison_type:type_name -> gitmirror.v1.DiffRequest.ComparisonType
	8,  // 4: gitmirror.v1.Hunk.lines:type_name -> gitmirror.v1.LinePair
	7,  // 5: gitmirror.v1.FileDiff.lhs_src:type_name -> gitmirror.v1.FileContent
	7,  // 6: gitmirror.v1.FileDiff.rhs_src:type_name -> gitmirror.v1.FileContent
	9,  // 7: gitmirror.v1.FileDiff.hunks:type_name -> gitmirror.v1.Hunk
	10, // 8: gitmirror.v1.FileDiff.has_byte_changes:type_name -> gitmirror.v1.ByteChanges
	13, // 9: gitmirror.v1.GitCommit.author:type_name -> gitmirror.v1.GitSignature
	13, // 10: gitmirror.v1.GitCommit.committer:type_name -> gitmirror.v1.GitSignature
	14, // 11: gitmirror.v1.GitCommit.extra_headers:type_name -> gitmirror.v1.GitCommit.ExtraHeadersEntry
	15, // 12: gitmirror.v1.GitSignature.date:type_name -> google.protobuf.Timestamp
	1,  // 13: gitmirror.v1.GitMirrorService.CommitLog:input_type -> gitmirror.v1.CommitLogRequest
	3,  // 14: gitmirror.v1.GitMirrorService.GetBlob:input_type -> gitmirror.v1.GetBlobRequest
	5,  // 15: gitmirror.v1.GitMirrorService.Diff:input_type -> gitmirror.v1.DiffRequest
	6,  // 16: gitmirror.v1.GitMirrorService.Interdiff:input_type -> gitmirror.v1.InterdiffRequest
	2,  // 17: gitmirror.v1.GitMirrorService.CommitLog:output_type -> gitmirror.v1.CommitLogResponse
	4,  // 18: gitmirror.v1.GitMirrorService.GetBlob:output_type -> gitmirror.v1.BlobChunk
	11, // 19: gitmirror.v1.GitMirrorService.Diff:output_type -> gitmirror.v1.FileDiff
	11, // 20: gitmirror.v1.GitMirrorService.Interdiff:output_type -> gitmirror.v1.FileDiff
	17, // [17:21] is the sub-list for method output_type
	13, // [13:17] is the sub-list for method input_type
	13, // [13:13] is the sub-list for extension type_name
	13, // [13:13] is the sub-list for extension extendee
	0,  // [0:13] is the sub-list for field type_name
}

func init() { file_gitmirror_v1_gitmirror_proto_init() }
func file_gitmirror_v1_gitmirror_proto_init() {
	if File_gitmirror_v1_gitmirror_proto != nil {
		return
	}
	file_gitmirror_v1_gitmirror_proto_msgTypes[4].OneofWrappers = []any{}
	file_gitmirror_v1_gitmirror_proto_msgTypes[6].OneofWrappers = []any{}
	file_gitmirror_v1_gitmirror_proto_msgTypes[7].OneofWrappers = []any{}
	file_gitmirror_v1_gitmirror_proto_msgTypes[10].OneofWrappers = []any{}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_gitmirror_v1_gitmirror_proto_rawDesc), len(file_gitmirror_v1_gitmirror_proto_rawDesc)),
			NumEnums:      1,
			NumMessages:   14,
			NumExtensions: 0,
			NumServices:   1,
		},
		GoTypes:           file_gitmirror_v1_gitmirror_proto_goTypes,
		DependencyIndexes: file_gitmirror_v1_gitmirror_proto_depIdxs,
		EnumInfos:         file_gitmirror_v1_gitmirror_proto_enumTypes,
		MessageInfos:      file_gitmirror_v1_gitmirror_proto_msgTypes,
	}.Build()
	File_gitmirror_v1_gitmirror_proto = out.File
	file_gitmirror_v1_gitmirror_proto_goTypes = nil
	file_gitmirror_v1_gitmirror_proto_depIdxs = nil
}
