luci: go.chromium.org/luci/common/proto/gitiles Index | Files

package gitiles

import "go.chromium.org/luci/common/proto/gitiles"

Package gitiles contains Gitiles service definition.

Package gitiles is a generated GoMock package.

Index

Package Files

const.go generate.go gitiles.mock.pb.go gitiles.pb.go gitiles_fake.go pb.discovery.go validation.go

Constants

const (
    // AllRefs instructs the client to fetch all refs.
    AllRefs = "refs"
    // Branches instructs the client to fetch all branches.
    Branches = "refs/heads"
    // Tags instructs the client to fetch all tags.
    Tags = "refs/tags"
)

These constants are possible values for RefsRequest.RefsPath field. Not an exhaustive list.

Variables

var (
    ArchiveRequest_Format_name = map[int32]string{
        0:  "Invalid",
        1:  "GZIP",
        2:  "TAR",
        3:  "BZIP2",
        4:  "XZ",
    }
    ArchiveRequest_Format_value = map[string]int32{
        "Invalid": 0,
        "GZIP":    1,
        "TAR":     2,
        "BZIP2":   3,
        "XZ":      4,
    }
)

Enum value maps for ArchiveRequest_Format.

var (
    DownloadFileRequest_Format_name = map[int32]string{
        0:  "FormatInvalid",
        1:  "TEXT",
    }
    DownloadFileRequest_Format_value = map[string]int32{
        "FormatInvalid": 0,
        "TEXT":          1,
    }
)

Enum value maps for DownloadFileRequest_Format.

var File_go_chromium_org_luci_common_proto_gitiles_gitiles_proto protoreflect.FileDescriptor

func FileDescriptorSet Uses

func FileDescriptorSet() *descriptor.FileDescriptorSet

FileDescriptorSet returns a descriptor set for this proto package, which includes all defined services, and all transitive dependencies.

Will not return nil.

Do NOT modify the returned descriptor.

func RegisterGitilesServer Uses

func RegisterGitilesServer(s prpc.Registrar, srv GitilesServer)

type ArchiveRequest Uses

type ArchiveRequest struct {

    // Gitiles project, e.g. "chromium/src" part in
    // https://chromium.googlesource.com/chromium/src/+/master
    // Required.
    Project string `protobuf:"bytes,1,opt,name=project,proto3" json:"project,omitempty"`
    // The ref at which to generate the project archive for.
    //
    // viz refs/for/branch or just branch
    Ref string `protobuf:"bytes,2,opt,name=ref,proto3" json:"ref,omitempty"`
    // Format of the returned project archive.
    Format ArchiveRequest_Format `protobuf:"varint,3,opt,name=format,proto3,enum=gitiles.ArchiveRequest_Format" json:"format,omitempty"`
    // contains filtered or unexported fields
}

ArchiveRequest is a request message of the Gitiles.Archive RPC.

func (*ArchiveRequest) Descriptor Uses

func (*ArchiveRequest) Descriptor() ([]byte, []int)

Deprecated: Use ArchiveRequest.ProtoReflect.Descriptor instead.

func (*ArchiveRequest) GetFormat Uses

func (x *ArchiveRequest) GetFormat() ArchiveRequest_Format

func (*ArchiveRequest) GetProject Uses

func (x *ArchiveRequest) GetProject() string

func (*ArchiveRequest) GetRef Uses

func (x *ArchiveRequest) GetRef() string

func (*ArchiveRequest) ProtoMessage Uses

func (*ArchiveRequest) ProtoMessage()

func (*ArchiveRequest) ProtoReflect Uses

func (x *ArchiveRequest) ProtoReflect() protoreflect.Message

func (*ArchiveRequest) Reset Uses

func (x *ArchiveRequest) Reset()

func (*ArchiveRequest) String Uses

func (x *ArchiveRequest) String() string

func (*ArchiveRequest) Validate Uses

func (r *ArchiveRequest) Validate() error

Validate returns an error if r is invalid.

type ArchiveRequest_Format Uses

type ArchiveRequest_Format int32

List copied from https://github.com/google/gitiles/blob/65edbe49f2b3882a5979f602383ef0c7b2b8ee0c/java/com/google/gitiles/ArchiveFormat.java

const (
    ArchiveRequest_Invalid ArchiveRequest_Format = 0
    ArchiveRequest_GZIP    ArchiveRequest_Format = 1
    ArchiveRequest_TAR     ArchiveRequest_Format = 2
    ArchiveRequest_BZIP2   ArchiveRequest_Format = 3
    ArchiveRequest_XZ      ArchiveRequest_Format = 4
)

func (ArchiveRequest_Format) Descriptor Uses

func (ArchiveRequest_Format) Descriptor() protoreflect.EnumDescriptor

func (ArchiveRequest_Format) Enum Uses

func (x ArchiveRequest_Format) Enum() *ArchiveRequest_Format

func (ArchiveRequest_Format) EnumDescriptor Uses

func (ArchiveRequest_Format) EnumDescriptor() ([]byte, []int)

Deprecated: Use ArchiveRequest_Format.Descriptor instead.

func (ArchiveRequest_Format) Number Uses

func (x ArchiveRequest_Format) Number() protoreflect.EnumNumber

func (ArchiveRequest_Format) String Uses

func (x ArchiveRequest_Format) String() string

func (ArchiveRequest_Format) Type Uses

func (ArchiveRequest_Format) Type() protoreflect.EnumType

type ArchiveResponse Uses

type ArchiveResponse struct {

    // Suggested name of the returned archive.
    Filename string `protobuf:"bytes,1,opt,name=filename,proto3" json:"filename,omitempty"`
    // Contents of the archive streamed from gitiles.
    //
    // The underlying server RPC streams back the contents. This API simplifies
    // the RPC to a non-streaming response.
    Contents []byte `protobuf:"bytes,2,opt,name=contents,proto3" json:"contents,omitempty"`
    // contains filtered or unexported fields
}

func (*ArchiveResponse) Descriptor Uses

func (*ArchiveResponse) Descriptor() ([]byte, []int)

Deprecated: Use ArchiveResponse.ProtoReflect.Descriptor instead.

func (*ArchiveResponse) GetContents Uses

func (x *ArchiveResponse) GetContents() []byte

func (*ArchiveResponse) GetFilename Uses

func (x *ArchiveResponse) GetFilename() string

func (*ArchiveResponse) ProtoMessage Uses

func (*ArchiveResponse) ProtoMessage()

func (*ArchiveResponse) ProtoReflect Uses

func (x *ArchiveResponse) ProtoReflect() protoreflect.Message

func (*ArchiveResponse) Reset Uses

func (x *ArchiveResponse) Reset()

func (*ArchiveResponse) String Uses

func (x *ArchiveResponse) String() string

type DownloadFileRequest Uses

type DownloadFileRequest struct {

    // Gitiles project, e.g. "chromium/src" part in
    // https://chromium.googlesource.com/chromium/src/+/master
    // Required.
    Project string `protobuf:"bytes,1,opt,name=project,proto3" json:"project,omitempty"`
    // The commit where to start the listing from.
    // The value can be:
    //   - a git revision as 40-char string or its prefix so long as its unique in repo.
    //   - a ref such as "refs/heads/branch"
    //   - a ref defined as n-th parent of R in the form "R~n".
    //     For example, "master~2" or "deadbeef~1".
    // Required.
    Committish string `protobuf:"bytes,2,opt,name=committish,proto3" json:"committish,omitempty"`
    // Path relative to the project root to the file to download.
    Path string `protobuf:"bytes,3,opt,name=path,proto3" json:"path,omitempty"`
    // Format to download file in.
    Format DownloadFileRequest_Format `protobuf:"varint,4,opt,name=format,proto3,enum=gitiles.DownloadFileRequest_Format" json:"format,omitempty"`
    // contains filtered or unexported fields
}

func (*DownloadFileRequest) Descriptor Uses

func (*DownloadFileRequest) Descriptor() ([]byte, []int)

Deprecated: Use DownloadFileRequest.ProtoReflect.Descriptor instead.

func (*DownloadFileRequest) GetCommittish Uses

func (x *DownloadFileRequest) GetCommittish() string

func (*DownloadFileRequest) GetFormat Uses

func (x *DownloadFileRequest) GetFormat() DownloadFileRequest_Format

func (*DownloadFileRequest) GetPath Uses

func (x *DownloadFileRequest) GetPath() string

func (*DownloadFileRequest) GetProject Uses

func (x *DownloadFileRequest) GetProject() string

func (*DownloadFileRequest) ProtoMessage Uses

func (*DownloadFileRequest) ProtoMessage()

func (*DownloadFileRequest) ProtoReflect Uses

func (x *DownloadFileRequest) ProtoReflect() protoreflect.Message

func (*DownloadFileRequest) Reset Uses

func (x *DownloadFileRequest) Reset()

func (*DownloadFileRequest) String Uses

func (x *DownloadFileRequest) String() string

func (*DownloadFileRequest) Validate Uses

func (r *DownloadFileRequest) Validate() error

Validate returns an error if r is invalid.

type DownloadFileRequest_Format Uses

type DownloadFileRequest_Format int32
const (
    DownloadFileRequest_FormatInvalid DownloadFileRequest_Format = 0
    DownloadFileRequest_TEXT          DownloadFileRequest_Format = 1
)

func (DownloadFileRequest_Format) Descriptor Uses

func (DownloadFileRequest_Format) Descriptor() protoreflect.EnumDescriptor

func (DownloadFileRequest_Format) Enum Uses

func (x DownloadFileRequest_Format) Enum() *DownloadFileRequest_Format

func (DownloadFileRequest_Format) EnumDescriptor Uses

func (DownloadFileRequest_Format) EnumDescriptor() ([]byte, []int)

Deprecated: Use DownloadFileRequest_Format.Descriptor instead.

func (DownloadFileRequest_Format) Number Uses

func (x DownloadFileRequest_Format) Number() protoreflect.EnumNumber

func (DownloadFileRequest_Format) String Uses

func (x DownloadFileRequest_Format) String() string

func (DownloadFileRequest_Format) Type Uses

func (DownloadFileRequest_Format) Type() protoreflect.EnumType

type DownloadFileResponse Uses

type DownloadFileResponse struct {

    // Decoded contents of the downloaded file.
    //
    // The underlying server RPC streams back the contents. This API simplifies
    // the RPC to a non-streaming response.
    Contents string `protobuf:"bytes,1,opt,name=contents,proto3" json:"contents,omitempty"`
    // contains filtered or unexported fields
}

func (*DownloadFileResponse) Descriptor Uses

func (*DownloadFileResponse) Descriptor() ([]byte, []int)

Deprecated: Use DownloadFileResponse.ProtoReflect.Descriptor instead.

func (*DownloadFileResponse) GetContents Uses

func (x *DownloadFileResponse) GetContents() string

func (*DownloadFileResponse) ProtoMessage Uses

func (*DownloadFileResponse) ProtoMessage()

func (*DownloadFileResponse) ProtoReflect Uses

func (x *DownloadFileResponse) ProtoReflect() protoreflect.Message

func (*DownloadFileResponse) Reset Uses

func (x *DownloadFileResponse) Reset()

func (*DownloadFileResponse) String Uses

func (x *DownloadFileResponse) String() string

type GitilesClient Uses

type GitilesClient interface {
    // Log retrieves commit log.
    Log(ctx context.Context, in *LogRequest, opts ...grpc.CallOption) (*LogResponse, error)
    // Refs retrieves repo refs.
    Refs(ctx context.Context, in *RefsRequest, opts ...grpc.CallOption) (*RefsResponse, error)
    // Archive retrieves archived contents of the project.
    //
    // An archive is a shallow bundle of the contents of a repository.
    //
    // DEPRECATED: Use DownloadFile to obtain plain text files.
    // TODO(pprabhu): Migrate known users to DownloadFile and delete this RPC.
    Archive(ctx context.Context, in *ArchiveRequest, opts ...grpc.CallOption) (*ArchiveResponse, error)
    // DownloadFile retrieves a file from the project.
    DownloadFile(ctx context.Context, in *DownloadFileRequest, opts ...grpc.CallOption) (*DownloadFileResponse, error)
    // Projects retrieves list of available Gitiles projects
    Projects(ctx context.Context, in *ProjectsRequest, opts ...grpc.CallOption) (*ProjectsResponse, error)
}

GitilesClient is the client API for Gitiles service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewGitilesClient Uses

func NewGitilesClient(cc grpc.ClientConnInterface) GitilesClient

func NewGitilesPRPCClient Uses

func NewGitilesPRPCClient(client *prpc.Client) GitilesClient

type GitilesFake Uses

type GitilesFake struct {
    // contains filtered or unexported fields
}

GitilesFake allows testing of Gitiles API without using actual Gitiles server. User can set data using SetRepository method.

func (*GitilesFake) Archive Uses

func (g *GitilesFake) Archive(ctx context.Context, in *ArchiveRequest, opts ...grpc.CallOption) (*ArchiveResponse, error)

Archive retrieves archived contents of the project. This is not implemented.

An archive is a shallow bundle of the contents of a repository.

DEPRECATED: Use DownloadFile to obtain plain text files. TODO(pprabhu): Migrate known users to DownloadFile and delete this RPC.

func (*GitilesFake) DownloadFile Uses

func (g *GitilesFake) DownloadFile(ctx context.Context, in *DownloadFileRequest, opts ...grpc.CallOption) (*DownloadFileResponse, error)

DownloadFile retrieves a file from the project. This is not implemented.

func (*GitilesFake) GetCallLogs Uses

func (g *GitilesFake) GetCallLogs() []interface{}

func (*GitilesFake) Log Uses

func (g *GitilesFake) Log(ctx context.Context, in *LogRequest, opts ...grpc.CallOption) (*LogResponse, error)

Log retrieves commit log. Merge commits are supported, but it implements simple logic and likely won't return results in the same order as Gitiles.

func (*GitilesFake) Projects Uses

func (g *GitilesFake) Projects(ctx context.Context, in *ProjectsRequest, opts ...grpc.CallOption) (*ProjectsResponse, error)

Projects retrieves list of available Gitiles projects

func (*GitilesFake) Refs Uses

func (g *GitilesFake) Refs(ctx context.Context, in *RefsRequest, opts ...grpc.CallOption) (*RefsResponse, error)

Refs retrieves repo refs.

func (*GitilesFake) SetRepository Uses

func (g *GitilesFake) SetRepository(repository string, refs map[string]string, commits []*git.Commit)

SetRepository stores provided references and commits to desired repository. If repository is previously set, it will override it.

refs keys are references, keys are revisions. Example: g.SetRepository(

"foo",
[]string{"refs/heads/master", "rev1"},
[]*git.Commit{ {Id: "rev1", Parents: []string{"rev0"}}, {Id: "rev0"} }

) Represents following repository: name: foo references: * refs/heads/master points to rev1 commits: rev1 --> rev0 (root commit)

type GitilesServer Uses

type GitilesServer interface {
    // Log retrieves commit log.
    Log(context.Context, *LogRequest) (*LogResponse, error)
    // Refs retrieves repo refs.
    Refs(context.Context, *RefsRequest) (*RefsResponse, error)
    // Archive retrieves archived contents of the project.
    //
    // An archive is a shallow bundle of the contents of a repository.
    //
    // DEPRECATED: Use DownloadFile to obtain plain text files.
    // TODO(pprabhu): Migrate known users to DownloadFile and delete this RPC.
    Archive(context.Context, *ArchiveRequest) (*ArchiveResponse, error)
    // DownloadFile retrieves a file from the project.
    DownloadFile(context.Context, *DownloadFileRequest) (*DownloadFileResponse, error)
    // Projects retrieves list of available Gitiles projects
    Projects(context.Context, *ProjectsRequest) (*ProjectsResponse, error)
}

GitilesServer is the server API for Gitiles service.

type LogRequest Uses

type LogRequest struct {

    // Gitiles project, e.g. "chromium/src" part in
    // https://chromium.googlesource.com/chromium/src/+/master
    // Required.
    Project string `protobuf:"bytes,1,opt,name=project,proto3" json:"project,omitempty"`
    // The commit where to start the listing from.
    // The value can be:
    //   - a git revision as 40-char string or its prefix so long as its unique in repo.
    //   - a ref such as "refs/heads/branch"
    //   - a ref defined as n-th parent of R in the form "R~n".
    //     For example, "master~2" or "deadbeef~1".
    // Required.
    Committish string `protobuf:"bytes,3,opt,name=committish,proto3" json:"committish,omitempty"`
    // If specified, only commits not reachable from this commit (inclusive)
    // will be returned.
    //
    // In git's notation, this is
    //   $ git log ^exclude_ancestors_of committish
    //  OR
    //   $ git log exclude_ancestors_of..committish
    // https://git-scm.com/docs/gitrevisions#gitrevisions-Theememtwo-dotRangeNotation
    //
    // For example, given this repo
    //
    //     base -> A -> B -> C == refs/heads/master
    //        \
    //         X -> Y -> Z  == refs/heads/release
    //
    // calling Log(committish='refs/heads/release',
    //             exclude_ancestors_of='refs/heads/master')
    // will return ['Z', Y', 'X'].
    ExcludeAncestorsOf string `protobuf:"bytes,2,opt,name=exclude_ancestors_of,json=excludeAncestorsOf,proto3" json:"exclude_ancestors_of,omitempty"`
    // If true, include tree diff in commits.
    TreeDiff bool `protobuf:"varint,4,opt,name=tree_diff,json=treeDiff,proto3" json:"tree_diff,omitempty"`
    // Value of next_page_token in LogResponse to continue.
    PageToken string `protobuf:"bytes,10,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
    // If > 0, number of commits to retrieve.
    PageSize int32 `protobuf:"varint,11,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
    // contains filtered or unexported fields
}

LogRequest is request message for Gitiles.Log rpc.

func (*LogRequest) Descriptor Uses

func (*LogRequest) Descriptor() ([]byte, []int)

Deprecated: Use LogRequest.ProtoReflect.Descriptor instead.

func (*LogRequest) GetCommittish Uses

func (x *LogRequest) GetCommittish() string

func (*LogRequest) GetExcludeAncestorsOf Uses

func (x *LogRequest) GetExcludeAncestorsOf() string

func (*LogRequest) GetPageSize Uses

func (x *LogRequest) GetPageSize() int32

func (*LogRequest) GetPageToken Uses

func (x *LogRequest) GetPageToken() string

func (*LogRequest) GetProject Uses

func (x *LogRequest) GetProject() string

func (*LogRequest) GetTreeDiff Uses

func (x *LogRequest) GetTreeDiff() bool

func (*LogRequest) ProtoMessage Uses

func (*LogRequest) ProtoMessage()

func (*LogRequest) ProtoReflect Uses

func (x *LogRequest) ProtoReflect() protoreflect.Message

func (*LogRequest) Reset Uses

func (x *LogRequest) Reset()

func (*LogRequest) String Uses

func (x *LogRequest) String() string

func (*LogRequest) Validate Uses

func (r *LogRequest) Validate() error

Validate returns an error if r is invalid.

type LogResponse Uses

type LogResponse struct {

    // Retrieved commits.
    Log []*git.Commit `protobuf:"bytes,1,rep,name=log,proto3" json:"log,omitempty"`
    // A page token for next LogRequest to fetch next page of commits.
    NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
    // contains filtered or unexported fields
}

LogRequest is response message for Gitiles.Log rpc.

func (*LogResponse) Descriptor Uses

func (*LogResponse) Descriptor() ([]byte, []int)

Deprecated: Use LogResponse.ProtoReflect.Descriptor instead.

func (*LogResponse) GetLog Uses

func (x *LogResponse) GetLog() []*git.Commit

func (*LogResponse) GetNextPageToken Uses

func (x *LogResponse) GetNextPageToken() string

func (*LogResponse) ProtoMessage Uses

func (*LogResponse) ProtoMessage()

func (*LogResponse) ProtoReflect Uses

func (x *LogResponse) ProtoReflect() protoreflect.Message

func (*LogResponse) Reset Uses

func (x *LogResponse) Reset()

func (*LogResponse) String Uses

func (x *LogResponse) String() string

type MockGitilesClient Uses

type MockGitilesClient struct {
    // contains filtered or unexported fields
}

MockGitilesClient is a mock of GitilesClient interface.

func NewMockGitilesClient Uses

func NewMockGitilesClient(ctrl *gomock.Controller) *MockGitilesClient

NewMockGitilesClient creates a new mock instance.

func (*MockGitilesClient) Archive Uses

func (m *MockGitilesClient) Archive(ctx context.Context, in *ArchiveRequest, opts ...grpc.CallOption) (*ArchiveResponse, error)

Archive mocks base method.

func (*MockGitilesClient) DownloadFile Uses

func (m *MockGitilesClient) DownloadFile(ctx context.Context, in *DownloadFileRequest, opts ...grpc.CallOption) (*DownloadFileResponse, error)

DownloadFile mocks base method.

func (*MockGitilesClient) EXPECT Uses

func (m *MockGitilesClient) EXPECT() *MockGitilesClientMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockGitilesClient) Log Uses

func (m *MockGitilesClient) Log(ctx context.Context, in *LogRequest, opts ...grpc.CallOption) (*LogResponse, error)

Log mocks base method.

func (*MockGitilesClient) Projects Uses

func (m *MockGitilesClient) Projects(ctx context.Context, in *ProjectsRequest, opts ...grpc.CallOption) (*ProjectsResponse, error)

Projects mocks base method.

func (*MockGitilesClient) Refs Uses

func (m *MockGitilesClient) Refs(ctx context.Context, in *RefsRequest, opts ...grpc.CallOption) (*RefsResponse, error)

Refs mocks base method.

type MockGitilesClientMockRecorder Uses

type MockGitilesClientMockRecorder struct {
    // contains filtered or unexported fields
}

MockGitilesClientMockRecorder is the mock recorder for MockGitilesClient.

func (*MockGitilesClientMockRecorder) Archive Uses

func (mr *MockGitilesClientMockRecorder) Archive(ctx, in interface{}, opts ...interface{}) *gomock.Call

Archive indicates an expected call of Archive.

func (*MockGitilesClientMockRecorder) DownloadFile Uses

func (mr *MockGitilesClientMockRecorder) DownloadFile(ctx, in interface{}, opts ...interface{}) *gomock.Call

DownloadFile indicates an expected call of DownloadFile.

func (*MockGitilesClientMockRecorder) Log Uses

func (mr *MockGitilesClientMockRecorder) Log(ctx, in interface{}, opts ...interface{}) *gomock.Call

Log indicates an expected call of Log.

func (*MockGitilesClientMockRecorder) Projects Uses

func (mr *MockGitilesClientMockRecorder) Projects(ctx, in interface{}, opts ...interface{}) *gomock.Call

Projects indicates an expected call of Projects.

func (*MockGitilesClientMockRecorder) Refs Uses

func (mr *MockGitilesClientMockRecorder) Refs(ctx, in interface{}, opts ...interface{}) *gomock.Call

Refs indicates an expected call of Refs.

type MockGitilesServer Uses

type MockGitilesServer struct {
    // contains filtered or unexported fields
}

MockGitilesServer is a mock of GitilesServer interface.

func NewMockGitilesServer Uses

func NewMockGitilesServer(ctrl *gomock.Controller) *MockGitilesServer

NewMockGitilesServer creates a new mock instance.

func (*MockGitilesServer) Archive Uses

func (m *MockGitilesServer) Archive(arg0 context.Context, arg1 *ArchiveRequest) (*ArchiveResponse, error)

Archive mocks base method.

func (*MockGitilesServer) DownloadFile Uses

func (m *MockGitilesServer) DownloadFile(arg0 context.Context, arg1 *DownloadFileRequest) (*DownloadFileResponse, error)

DownloadFile mocks base method.

func (*MockGitilesServer) EXPECT Uses

func (m *MockGitilesServer) EXPECT() *MockGitilesServerMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockGitilesServer) Log Uses

func (m *MockGitilesServer) Log(arg0 context.Context, arg1 *LogRequest) (*LogResponse, error)

Log mocks base method.

func (*MockGitilesServer) Projects Uses

func (m *MockGitilesServer) Projects(arg0 context.Context, arg1 *ProjectsRequest) (*ProjectsResponse, error)

Projects mocks base method.

func (*MockGitilesServer) Refs Uses

func (m *MockGitilesServer) Refs(arg0 context.Context, arg1 *RefsRequest) (*RefsResponse, error)

Refs mocks base method.

type MockGitilesServerMockRecorder Uses

type MockGitilesServerMockRecorder struct {
    // contains filtered or unexported fields
}

MockGitilesServerMockRecorder is the mock recorder for MockGitilesServer.

func (*MockGitilesServerMockRecorder) Archive Uses

func (mr *MockGitilesServerMockRecorder) Archive(arg0, arg1 interface{}) *gomock.Call

Archive indicates an expected call of Archive.

func (*MockGitilesServerMockRecorder) DownloadFile Uses

func (mr *MockGitilesServerMockRecorder) DownloadFile(arg0, arg1 interface{}) *gomock.Call

DownloadFile indicates an expected call of DownloadFile.

func (*MockGitilesServerMockRecorder) Log Uses

func (mr *MockGitilesServerMockRecorder) Log(arg0, arg1 interface{}) *gomock.Call

Log indicates an expected call of Log.

func (*MockGitilesServerMockRecorder) Projects Uses

func (mr *MockGitilesServerMockRecorder) Projects(arg0, arg1 interface{}) *gomock.Call

Projects indicates an expected call of Projects.

func (*MockGitilesServerMockRecorder) Refs Uses

func (mr *MockGitilesServerMockRecorder) Refs(arg0, arg1 interface{}) *gomock.Call

Refs indicates an expected call of Refs.

type ProjectsRequest Uses

type ProjectsRequest struct {
    // contains filtered or unexported fields
}

func (*ProjectsRequest) Descriptor Uses

func (*ProjectsRequest) Descriptor() ([]byte, []int)

Deprecated: Use ProjectsRequest.ProtoReflect.Descriptor instead.

func (*ProjectsRequest) ProtoMessage Uses

func (*ProjectsRequest) ProtoMessage()

func (*ProjectsRequest) ProtoReflect Uses

func (x *ProjectsRequest) ProtoReflect() protoreflect.Message

func (*ProjectsRequest) Reset Uses

func (x *ProjectsRequest) Reset()

func (*ProjectsRequest) String Uses

func (x *ProjectsRequest) String() string

type ProjectsResponse Uses

type ProjectsResponse struct {

    // List of available Gitiles projects
    Projects []string `protobuf:"bytes,1,rep,name=projects,proto3" json:"projects,omitempty"`
    // contains filtered or unexported fields
}

func (*ProjectsResponse) Descriptor Uses

func (*ProjectsResponse) Descriptor() ([]byte, []int)

Deprecated: Use ProjectsResponse.ProtoReflect.Descriptor instead.

func (*ProjectsResponse) GetProjects Uses

func (x *ProjectsResponse) GetProjects() []string

func (*ProjectsResponse) ProtoMessage Uses

func (*ProjectsResponse) ProtoMessage()

func (*ProjectsResponse) ProtoReflect Uses

func (x *ProjectsResponse) ProtoReflect() protoreflect.Message

func (*ProjectsResponse) Reset Uses

func (x *ProjectsResponse) Reset()

func (*ProjectsResponse) String Uses

func (x *ProjectsResponse) String() string

type RefsRequest Uses

type RefsRequest struct {

    // Gitiles project, e.g. "chromium/src" part in
    // https://chromium.googlesource.com/chromium/src/+/master
    // Required.
    Project string `protobuf:"bytes,1,opt,name=project,proto3" json:"project,omitempty"`
    // Limits which refs to resolve to only those matching {refsPath}/*.
    //
    // Must be "refs" or start with "refs/".
    // Must not include glob '*'.
    // Use "refs/heads" to retrieve all branches.
    //
    // To fetch **all** refs in a repo, specify just "refs" but beware of two
    // caveats:
    //  * refs returned include a ref for each patchset for each Gerrit change
    //    associated with the repo.
    //  * returned map will contain special "HEAD" ref whose value in resulting map
    //    will be name of the actual ref to which "HEAD" points, which is typically
    //    "refs/heads/master".
    //
    // Thus, if you are looking for all tags and all branches of repo, it's
    // recommended to issue two Refs calls limited to "refs/tags" and "refs/heads"
    // instead of one call for "refs".
    //
    // Since Gerrit allows per-ref ACLs, it is possible that some refs matching
    // refPrefix would not be present in results because current user isn't granted
    // read permission on them.
    RefsPath string `protobuf:"bytes,2,opt,name=refs_path,json=refsPath,proto3" json:"refs_path,omitempty"`
    // contains filtered or unexported fields
}

RefsRequest is a request message of Gitiles.Refs RPC.

func (*RefsRequest) Descriptor Uses

func (*RefsRequest) Descriptor() ([]byte, []int)

Deprecated: Use RefsRequest.ProtoReflect.Descriptor instead.

func (*RefsRequest) GetProject Uses

func (x *RefsRequest) GetProject() string

func (*RefsRequest) GetRefsPath Uses

func (x *RefsRequest) GetRefsPath() string

func (*RefsRequest) ProtoMessage Uses

func (*RefsRequest) ProtoMessage()

func (*RefsRequest) ProtoReflect Uses

func (x *RefsRequest) ProtoReflect() protoreflect.Message

func (*RefsRequest) Reset Uses

func (x *RefsRequest) Reset()

func (*RefsRequest) String Uses

func (x *RefsRequest) String() string

func (*RefsRequest) Validate Uses

func (r *RefsRequest) Validate() error

Validate returns an error if r is invalid.

type RefsResponse Uses

type RefsResponse struct {

    // revisions maps a ref to a revision.
    // Git branches have keys start with "refs/heads/".
    Revisions map[string]string `protobuf:"bytes,2,rep,name=revisions,proto3" json:"revisions,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
    // contains filtered or unexported fields
}

RefsResponse is a response message of Gitiles.Refs RPC.

func (*RefsResponse) Descriptor Uses

func (*RefsResponse) Descriptor() ([]byte, []int)

Deprecated: Use RefsResponse.ProtoReflect.Descriptor instead.

func (*RefsResponse) GetRevisions Uses

func (x *RefsResponse) GetRevisions() map[string]string

func (*RefsResponse) ProtoMessage Uses

func (*RefsResponse) ProtoMessage()

func (*RefsResponse) ProtoReflect Uses

func (x *RefsResponse) ProtoReflect() protoreflect.Message

func (*RefsResponse) Reset Uses

func (x *RefsResponse) Reset()

func (*RefsResponse) String Uses

func (x *RefsResponse) String() string

type UnimplementedGitilesServer Uses

type UnimplementedGitilesServer struct {
}

UnimplementedGitilesServer can be embedded to have forward compatible implementations.

func (*UnimplementedGitilesServer) Archive Uses

func (*UnimplementedGitilesServer) Archive(context.Context, *ArchiveRequest) (*ArchiveResponse, error)

func (*UnimplementedGitilesServer) DownloadFile Uses

func (*UnimplementedGitilesServer) DownloadFile(context.Context, *DownloadFileRequest) (*DownloadFileResponse, error)

func (*UnimplementedGitilesServer) Log Uses

func (*UnimplementedGitilesServer) Log(context.Context, *LogRequest) (*LogResponse, error)

func (*UnimplementedGitilesServer) Projects Uses

func (*UnimplementedGitilesServer) Projects(context.Context, *ProjectsRequest) (*ProjectsResponse, error)

func (*UnimplementedGitilesServer) Refs Uses

func (*UnimplementedGitilesServer) Refs(context.Context, *RefsRequest) (*RefsResponse, error)

Package gitiles imports 17 packages (graph) and is imported by 13 packages. Updated 2020-09-22. Refresh now. Tools for package owners.