Documentation ¶
Overview ¶
Package review is a reverse proxy.
It translates gRPC into GraphQL.
Index ¶
- func RegisterGQLObjectTypes(mux *runtime.ServeMux)
- func RegisterReviewServiceFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterReviewServiceHandler(mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterReviewServiceHandlerClient(mux *runtime.ServeMux, client ReviewServiceClient) error
- func RegisterReviewServiceServer(s *grpc.Server, srv ReviewServiceServer)
- type ListProductReviewsRequest
- func (*ListProductReviewsRequest) Descriptor() ([]byte, []int)
- func (m *ListProductReviewsRequest) GetProductId() string
- func (*ListProductReviewsRequest) ProtoMessage()
- func (m *ListProductReviewsRequest) Reset()
- func (m *ListProductReviewsRequest) String() string
- func (m *ListProductReviewsRequest) XXX_DiscardUnknown()
- func (m *ListProductReviewsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ListProductReviewsRequest) XXX_Merge(src proto.Message)
- func (m *ListProductReviewsRequest) XXX_Size() int
- func (m *ListProductReviewsRequest) XXX_Unmarshal(b []byte) error
- type ListProductReviewsResponse
- func (*ListProductReviewsResponse) Descriptor() ([]byte, []int)
- func (m *ListProductReviewsResponse) GetReviews() []*Review
- func (*ListProductReviewsResponse) ProtoMessage()
- func (m *ListProductReviewsResponse) Reset()
- func (m *ListProductReviewsResponse) String() string
- func (m *ListProductReviewsResponse) XXX_DiscardUnknown()
- func (m *ListProductReviewsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ListProductReviewsResponse) XXX_Merge(src proto.Message)
- func (m *ListProductReviewsResponse) XXX_Size() int
- func (m *ListProductReviewsResponse) XXX_Unmarshal(b []byte) error
- type ListUserReviewsRequest
- func (*ListUserReviewsRequest) Descriptor() ([]byte, []int)
- func (m *ListUserReviewsRequest) GetFirst() int32
- func (m *ListUserReviewsRequest) GetUserId() string
- func (*ListUserReviewsRequest) ProtoMessage()
- func (m *ListUserReviewsRequest) Reset()
- func (m *ListUserReviewsRequest) String() string
- func (m *ListUserReviewsRequest) XXX_DiscardUnknown()
- func (m *ListUserReviewsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ListUserReviewsRequest) XXX_Merge(src proto.Message)
- func (m *ListUserReviewsRequest) XXX_Size() int
- func (m *ListUserReviewsRequest) XXX_Unmarshal(b []byte) error
- type ListUserReviewsResponse
- func (*ListUserReviewsResponse) Descriptor() ([]byte, []int)
- func (m *ListUserReviewsResponse) GetReviews() []*Review
- func (*ListUserReviewsResponse) ProtoMessage()
- func (m *ListUserReviewsResponse) Reset()
- func (m *ListUserReviewsResponse) String() string
- func (m *ListUserReviewsResponse) XXX_DiscardUnknown()
- func (m *ListUserReviewsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ListUserReviewsResponse) XXX_Merge(src proto.Message)
- func (m *ListUserReviewsResponse) XXX_Size() int
- func (m *ListUserReviewsResponse) XXX_Unmarshal(b []byte) error
- type Review
- func (*Review) Descriptor() ([]byte, []int)
- func (m *Review) GetAuthorId() string
- func (m *Review) GetBody() string
- func (m *Review) GetId() string
- func (m *Review) GetProductId() string
- func (*Review) ProtoMessage()
- func (m *Review) Reset()
- func (m *Review) String() string
- func (m *Review) XXX_DiscardUnknown()
- func (m *Review) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Review) XXX_Merge(src proto.Message)
- func (m *Review) XXX_Size() int
- func (m *Review) XXX_Unmarshal(b []byte) error
- type ReviewServiceClient
- type ReviewServiceServer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterGQLObjectTypes ¶
func RegisterReviewServiceHandler ¶
func RegisterReviewServiceHandler(mux *runtime.ServeMux, conn *grpc.ClientConn) error
func RegisterReviewServiceHandlerClient ¶
func RegisterReviewServiceHandlerClient(mux *runtime.ServeMux, client ReviewServiceClient) error
func RegisterReviewServiceServer ¶
func RegisterReviewServiceServer(s *grpc.Server, srv ReviewServiceServer)
Types ¶
type ListProductReviewsRequest ¶
type ListProductReviewsRequest struct { ProductId string `protobuf:"bytes,1,opt,name=product_id,json=productId,proto3" json:"product_id,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*ListProductReviewsRequest) Descriptor ¶
func (*ListProductReviewsRequest) Descriptor() ([]byte, []int)
func (*ListProductReviewsRequest) GetProductId ¶
func (m *ListProductReviewsRequest) GetProductId() string
func (*ListProductReviewsRequest) ProtoMessage ¶
func (*ListProductReviewsRequest) ProtoMessage()
func (*ListProductReviewsRequest) Reset ¶
func (m *ListProductReviewsRequest) Reset()
func (*ListProductReviewsRequest) String ¶
func (m *ListProductReviewsRequest) String() string
func (*ListProductReviewsRequest) XXX_DiscardUnknown ¶
func (m *ListProductReviewsRequest) XXX_DiscardUnknown()
func (*ListProductReviewsRequest) XXX_Marshal ¶
func (m *ListProductReviewsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ListProductReviewsRequest) XXX_Merge ¶
func (m *ListProductReviewsRequest) XXX_Merge(src proto.Message)
func (*ListProductReviewsRequest) XXX_Size ¶
func (m *ListProductReviewsRequest) XXX_Size() int
func (*ListProductReviewsRequest) XXX_Unmarshal ¶
func (m *ListProductReviewsRequest) XXX_Unmarshal(b []byte) error
type ListProductReviewsResponse ¶
type ListProductReviewsResponse struct { Reviews []*Review `protobuf:"bytes,1,rep,name=reviews,proto3" json:"reviews,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*ListProductReviewsResponse) Descriptor ¶
func (*ListProductReviewsResponse) Descriptor() ([]byte, []int)
func (*ListProductReviewsResponse) GetReviews ¶
func (m *ListProductReviewsResponse) GetReviews() []*Review
func (*ListProductReviewsResponse) ProtoMessage ¶
func (*ListProductReviewsResponse) ProtoMessage()
func (*ListProductReviewsResponse) Reset ¶
func (m *ListProductReviewsResponse) Reset()
func (*ListProductReviewsResponse) String ¶
func (m *ListProductReviewsResponse) String() string
func (*ListProductReviewsResponse) XXX_DiscardUnknown ¶
func (m *ListProductReviewsResponse) XXX_DiscardUnknown()
func (*ListProductReviewsResponse) XXX_Marshal ¶
func (m *ListProductReviewsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ListProductReviewsResponse) XXX_Merge ¶
func (m *ListProductReviewsResponse) XXX_Merge(src proto.Message)
func (*ListProductReviewsResponse) XXX_Size ¶
func (m *ListProductReviewsResponse) XXX_Size() int
func (*ListProductReviewsResponse) XXX_Unmarshal ¶
func (m *ListProductReviewsResponse) XXX_Unmarshal(b []byte) error
type ListUserReviewsRequest ¶
type ListUserReviewsRequest struct { UserId string `protobuf:"bytes,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` First int32 `protobuf:"varint,2,opt,name=first,proto3" json:"first,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*ListUserReviewsRequest) Descriptor ¶
func (*ListUserReviewsRequest) Descriptor() ([]byte, []int)
func (*ListUserReviewsRequest) GetFirst ¶
func (m *ListUserReviewsRequest) GetFirst() int32
func (*ListUserReviewsRequest) GetUserId ¶
func (m *ListUserReviewsRequest) GetUserId() string
func (*ListUserReviewsRequest) ProtoMessage ¶
func (*ListUserReviewsRequest) ProtoMessage()
func (*ListUserReviewsRequest) Reset ¶
func (m *ListUserReviewsRequest) Reset()
func (*ListUserReviewsRequest) String ¶
func (m *ListUserReviewsRequest) String() string
func (*ListUserReviewsRequest) XXX_DiscardUnknown ¶
func (m *ListUserReviewsRequest) XXX_DiscardUnknown()
func (*ListUserReviewsRequest) XXX_Marshal ¶
func (m *ListUserReviewsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ListUserReviewsRequest) XXX_Merge ¶
func (m *ListUserReviewsRequest) XXX_Merge(src proto.Message)
func (*ListUserReviewsRequest) XXX_Size ¶
func (m *ListUserReviewsRequest) XXX_Size() int
func (*ListUserReviewsRequest) XXX_Unmarshal ¶
func (m *ListUserReviewsRequest) XXX_Unmarshal(b []byte) error
type ListUserReviewsResponse ¶
type ListUserReviewsResponse struct { Reviews []*Review `protobuf:"bytes,1,rep,name=reviews,proto3" json:"reviews,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*ListUserReviewsResponse) Descriptor ¶
func (*ListUserReviewsResponse) Descriptor() ([]byte, []int)
func (*ListUserReviewsResponse) GetReviews ¶
func (m *ListUserReviewsResponse) GetReviews() []*Review
func (*ListUserReviewsResponse) ProtoMessage ¶
func (*ListUserReviewsResponse) ProtoMessage()
func (*ListUserReviewsResponse) Reset ¶
func (m *ListUserReviewsResponse) Reset()
func (*ListUserReviewsResponse) String ¶
func (m *ListUserReviewsResponse) String() string
func (*ListUserReviewsResponse) XXX_DiscardUnknown ¶
func (m *ListUserReviewsResponse) XXX_DiscardUnknown()
func (*ListUserReviewsResponse) XXX_Marshal ¶
func (m *ListUserReviewsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ListUserReviewsResponse) XXX_Merge ¶
func (m *ListUserReviewsResponse) XXX_Merge(src proto.Message)
func (*ListUserReviewsResponse) XXX_Size ¶
func (m *ListUserReviewsResponse) XXX_Size() int
func (*ListUserReviewsResponse) XXX_Unmarshal ¶
func (m *ListUserReviewsResponse) XXX_Unmarshal(b []byte) error
type Review ¶
type Review struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` Body string `protobuf:"bytes,2,opt,name=body,proto3" json:"body,omitempty"` AuthorId string `protobuf:"bytes,3,opt,name=author_id,json=authorId,proto3" json:"author_id,omitempty"` ProductId string `protobuf:"bytes,4,opt,name=product_id,json=productId,proto3" json:"product_id,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*Review) Descriptor ¶
func (*Review) GetAuthorId ¶
func (*Review) GetProductId ¶
func (*Review) ProtoMessage ¶
func (*Review) ProtoMessage()
func (*Review) XXX_DiscardUnknown ¶
func (m *Review) XXX_DiscardUnknown()
func (*Review) XXX_Marshal ¶
func (*Review) XXX_Unmarshal ¶
type ReviewServiceClient ¶
type ReviewServiceClient interface { ListUserReviews(ctx context.Context, in *ListUserReviewsRequest, opts ...grpc.CallOption) (*ListUserReviewsResponse, error) ListProductReviews(ctx context.Context, in *ListProductReviewsRequest, opts ...grpc.CallOption) (*ListProductReviewsResponse, error) }
ReviewServiceClient is the client API for ReviewService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewReviewServiceClient ¶
func NewReviewServiceClient(cc *grpc.ClientConn) ReviewServiceClient
type ReviewServiceServer ¶
type ReviewServiceServer interface { ListUserReviews(context.Context, *ListUserReviewsRequest) (*ListUserReviewsResponse, error) ListProductReviews(context.Context, *ListProductReviewsRequest) (*ListProductReviewsResponse, error) }
ReviewServiceServer is the server API for ReviewService service.
Click to show internal directories.
Click to hide internal directories.