api_pb

package
v0.0.0-...-8a92d6a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 9, 2019 License: MIT Imports: 16 Imported by: 0

Documentation

Overview

Package api_pb is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterGitcrowServiceHandler

func RegisterGitcrowServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterGitcrowServiceHandler registers the http handlers for service GitcrowService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterGitcrowServiceHandlerClient

func RegisterGitcrowServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client GitcrowServiceClient) error

RegisterGitcrowServiceHandlerClient registers the http handlers for service GitcrowService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "GitcrowServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "GitcrowServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "GitcrowServiceClient" to call the correct interceptors.

func RegisterGitcrowServiceHandlerFromEndpoint

func RegisterGitcrowServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterGitcrowServiceHandlerFromEndpoint is same as RegisterGitcrowServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterGitcrowServiceServer

func RegisterGitcrowServiceServer(s *grpc.Server, srv GitcrowServiceServer)

Types

type CloneRepositoriesRequest

type CloneRepositoriesRequest struct {
	Username             string        `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"`
	AccessToken          string        `protobuf:"bytes,2,opt,name=access_token,json=accessToken,proto3" json:"access_token,omitempty"`
	ProjectName          string        `protobuf:"bytes,3,opt,name=project_name,json=projectName,proto3" json:"project_name,omitempty"`
	Repos                []*Repository `protobuf:"bytes,4,rep,name=repos,proto3" json:"repos,omitempty"`
	XXX_NoUnkeyedLiteral struct{}      `json:"-"`
	XXX_unrecognized     []byte        `json:"-"`
	XXX_sizecache        int32         `json:"-"`
}

func (*CloneRepositoriesRequest) Descriptor

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

func (*CloneRepositoriesRequest) GetAccessToken

func (m *CloneRepositoriesRequest) GetAccessToken() string

func (*CloneRepositoriesRequest) GetProjectName

func (m *CloneRepositoriesRequest) GetProjectName() string

func (*CloneRepositoriesRequest) GetRepos

func (m *CloneRepositoriesRequest) GetRepos() []*Repository

func (*CloneRepositoriesRequest) GetUsername

func (m *CloneRepositoriesRequest) GetUsername() string

func (*CloneRepositoriesRequest) ProtoMessage

func (*CloneRepositoriesRequest) ProtoMessage()

func (*CloneRepositoriesRequest) Reset

func (m *CloneRepositoriesRequest) Reset()

func (*CloneRepositoriesRequest) String

func (m *CloneRepositoriesRequest) String() string

func (*CloneRepositoriesRequest) XXX_DiscardUnknown

func (m *CloneRepositoriesRequest) XXX_DiscardUnknown()

func (*CloneRepositoriesRequest) XXX_Marshal

func (m *CloneRepositoriesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*CloneRepositoriesRequest) XXX_Merge

func (dst *CloneRepositoriesRequest) XXX_Merge(src proto.Message)

func (*CloneRepositoriesRequest) XXX_Size

func (m *CloneRepositoriesRequest) XXX_Size() int

func (*CloneRepositoriesRequest) XXX_Unmarshal

func (m *CloneRepositoriesRequest) XXX_Unmarshal(b []byte) error

type CloneRepositoriesResponse

type CloneRepositoriesResponse struct {
	Message              string   `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*CloneRepositoriesResponse) Descriptor

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

func (*CloneRepositoriesResponse) GetMessage

func (m *CloneRepositoriesResponse) GetMessage() string

func (*CloneRepositoriesResponse) ProtoMessage

func (*CloneRepositoriesResponse) ProtoMessage()

func (*CloneRepositoriesResponse) Reset

func (m *CloneRepositoriesResponse) Reset()

func (*CloneRepositoriesResponse) String

func (m *CloneRepositoriesResponse) String() string

func (*CloneRepositoriesResponse) XXX_DiscardUnknown

func (m *CloneRepositoriesResponse) XXX_DiscardUnknown()

func (*CloneRepositoriesResponse) XXX_Marshal

func (m *CloneRepositoriesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*CloneRepositoriesResponse) XXX_Merge

func (dst *CloneRepositoriesResponse) XXX_Merge(src proto.Message)

func (*CloneRepositoriesResponse) XXX_Size

func (m *CloneRepositoriesResponse) XXX_Size() int

func (*CloneRepositoriesResponse) XXX_Unmarshal

func (m *CloneRepositoriesResponse) XXX_Unmarshal(b []byte) error

type DownloadRepositoriesRequest

type DownloadRepositoriesRequest struct {
	Username             string        `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"`
	AccessToken          string        `protobuf:"bytes,2,opt,name=access_token,json=accessToken,proto3" json:"access_token,omitempty"`
	ProjectName          string        `protobuf:"bytes,3,opt,name=project_name,json=projectName,proto3" json:"project_name,omitempty"`
	Repos                []*Repository `protobuf:"bytes,4,rep,name=repos,proto3" json:"repos,omitempty"`
	XXX_NoUnkeyedLiteral struct{}      `json:"-"`
	XXX_unrecognized     []byte        `json:"-"`
	XXX_sizecache        int32         `json:"-"`
}

func (*DownloadRepositoriesRequest) Descriptor

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

func (*DownloadRepositoriesRequest) GetAccessToken

func (m *DownloadRepositoriesRequest) GetAccessToken() string

func (*DownloadRepositoriesRequest) GetProjectName

func (m *DownloadRepositoriesRequest) GetProjectName() string

func (*DownloadRepositoriesRequest) GetRepos

func (m *DownloadRepositoriesRequest) GetRepos() []*Repository

func (*DownloadRepositoriesRequest) GetUsername

func (m *DownloadRepositoriesRequest) GetUsername() string

func (*DownloadRepositoriesRequest) ProtoMessage

func (*DownloadRepositoriesRequest) ProtoMessage()

func (*DownloadRepositoriesRequest) Reset

func (m *DownloadRepositoriesRequest) Reset()

func (*DownloadRepositoriesRequest) String

func (m *DownloadRepositoriesRequest) String() string

func (*DownloadRepositoriesRequest) XXX_DiscardUnknown

func (m *DownloadRepositoriesRequest) XXX_DiscardUnknown()

func (*DownloadRepositoriesRequest) XXX_Marshal

func (m *DownloadRepositoriesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DownloadRepositoriesRequest) XXX_Merge

func (dst *DownloadRepositoriesRequest) XXX_Merge(src proto.Message)

func (*DownloadRepositoriesRequest) XXX_Size

func (m *DownloadRepositoriesRequest) XXX_Size() int

func (*DownloadRepositoriesRequest) XXX_Unmarshal

func (m *DownloadRepositoriesRequest) XXX_Unmarshal(b []byte) error

type DownloadRepositoriesResponse

type DownloadRepositoriesResponse struct {
	Message              string   `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*DownloadRepositoriesResponse) Descriptor

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

func (*DownloadRepositoriesResponse) GetMessage

func (m *DownloadRepositoriesResponse) GetMessage() string

func (*DownloadRepositoriesResponse) ProtoMessage

func (*DownloadRepositoriesResponse) ProtoMessage()

func (*DownloadRepositoriesResponse) Reset

func (m *DownloadRepositoriesResponse) Reset()

func (*DownloadRepositoriesResponse) String

func (*DownloadRepositoriesResponse) XXX_DiscardUnknown

func (m *DownloadRepositoriesResponse) XXX_DiscardUnknown()

func (*DownloadRepositoriesResponse) XXX_Marshal

func (m *DownloadRepositoriesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DownloadRepositoriesResponse) XXX_Merge

func (dst *DownloadRepositoriesResponse) XXX_Merge(src proto.Message)

func (*DownloadRepositoriesResponse) XXX_Size

func (m *DownloadRepositoriesResponse) XXX_Size() int

func (*DownloadRepositoriesResponse) XXX_Unmarshal

func (m *DownloadRepositoriesResponse) XXX_Unmarshal(b []byte) error

type GitcrowServiceClient

type GitcrowServiceClient interface {
	CloneRepositories(ctx context.Context, in *CloneRepositoriesRequest, opts ...grpc.CallOption) (*CloneRepositoriesResponse, error)
	DownloadRepositories(ctx context.Context, in *DownloadRepositoriesRequest, opts ...grpc.CallOption) (*DownloadRepositoriesResponse, error)
}

GitcrowServiceClient is the client API for GitcrowService service.

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

func NewGitcrowServiceClient

func NewGitcrowServiceClient(cc *grpc.ClientConn) GitcrowServiceClient

type GitcrowServiceServer

type GitcrowServiceServer interface {
	CloneRepositories(context.Context, *CloneRepositoriesRequest) (*CloneRepositoriesResponse, error)
	DownloadRepositories(context.Context, *DownloadRepositoriesRequest) (*DownloadRepositoriesResponse, error)
}

GitcrowServiceServer is the server API for GitcrowService service.

type Repository

type Repository struct {
	Owner                string                `protobuf:"bytes,1,opt,name=owner,proto3" json:"owner,omitempty"`
	Repo                 string                `protobuf:"bytes,2,opt,name=repo,proto3" json:"repo,omitempty"`
	Tag                  *wrappers.StringValue `protobuf:"bytes,3,opt,name=tag,proto3" json:"tag,omitempty"`
	XXX_NoUnkeyedLiteral struct{}              `json:"-"`
	XXX_unrecognized     []byte                `json:"-"`
	XXX_sizecache        int32                 `json:"-"`
}

func (*Repository) Descriptor

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

func (*Repository) GetOwner

func (m *Repository) GetOwner() string

func (*Repository) GetRepo

func (m *Repository) GetRepo() string

func (*Repository) GetTag

func (m *Repository) GetTag() *wrappers.StringValue

func (*Repository) ProtoMessage

func (*Repository) ProtoMessage()

func (*Repository) Reset

func (m *Repository) Reset()

func (*Repository) String

func (m *Repository) String() string

func (*Repository) XXX_DiscardUnknown

func (m *Repository) XXX_DiscardUnknown()

func (*Repository) XXX_Marshal

func (m *Repository) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Repository) XXX_Merge

func (dst *Repository) XXX_Merge(src proto.Message)

func (*Repository) XXX_Size

func (m *Repository) XXX_Size() int

func (*Repository) XXX_Unmarshal

func (m *Repository) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL