Documentation ¶
Index ¶
- Variables
- func RegisterHTTPOverGRPCServiceServer(s grpc.ServiceRegistrar, srv HTTPOverGRPCServiceServer)
- type HTTPHeader
- type HTTPOverGRPCServiceClient
- type HTTPOverGRPCServiceServer
- type HTTPOverGRPCService_HTTPClient
- type HTTPOverGRPCService_HTTPServer
- type HTTPRequest
- func (*HTTPRequest) Descriptor() ([]byte, []int)deprecated
- func (x *HTTPRequest) GetBodyData() []byte
- func (x *HTTPRequest) GetHeaders() []*HTTPHeader
- func (x *HTTPRequest) GetMethod() string
- func (x *HTTPRequest) GetProto() string
- func (x *HTTPRequest) GetRemoteAddr() string
- func (x *HTTPRequest) GetUrl() string
- func (*HTTPRequest) ProtoMessage()
- func (x *HTTPRequest) ProtoReflect() protoreflect.Message
- func (x *HTTPRequest) Reset()
- func (x *HTTPRequest) String() string
- type HTTPResponse
- func (*HTTPResponse) Descriptor() ([]byte, []int)deprecated
- func (x *HTTPResponse) GetBodyData() []byte
- func (x *HTTPResponse) GetHeaders() []*HTTPHeader
- func (x *HTTPResponse) GetStatusCode() int32
- func (*HTTPResponse) ProtoMessage()
- func (x *HTTPResponse) ProtoReflect() protoreflect.Message
- func (x *HTTPResponse) Reset()
- func (x *HTTPResponse) String() string
- type UnimplementedHTTPOverGRPCServiceServer
- type UnsafeHTTPOverGRPCServiceServer
Constants ¶
This section is empty.
Variables ¶
var File_http_proto protoreflect.FileDescriptor
var HTTPOverGRPCService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "com.github.jille.httpovergrpc.HTTPOverGRPCService", HandlerType: (*HTTPOverGRPCServiceServer)(nil), Methods: []grpc.MethodDesc{}, Streams: []grpc.StreamDesc{ { StreamName: "HTTP", Handler: _HTTPOverGRPCService_HTTP_Handler, ServerStreams: true, ClientStreams: true, }, }, Metadata: "http.proto", }
HTTPOverGRPCService_ServiceDesc is the grpc.ServiceDesc for HTTPOverGRPCService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterHTTPOverGRPCServiceServer ¶
func RegisterHTTPOverGRPCServiceServer(s grpc.ServiceRegistrar, srv HTTPOverGRPCServiceServer)
Types ¶
type HTTPHeader ¶
type HTTPHeader struct { Header string `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"` Values []string `protobuf:"bytes,2,rep,name=values,proto3" json:"values,omitempty"` // contains filtered or unexported fields }
func (*HTTPHeader) Descriptor
deprecated
func (*HTTPHeader) Descriptor() ([]byte, []int)
Deprecated: Use HTTPHeader.ProtoReflect.Descriptor instead.
func (*HTTPHeader) GetHeader ¶
func (x *HTTPHeader) GetHeader() string
func (*HTTPHeader) GetValues ¶
func (x *HTTPHeader) GetValues() []string
func (*HTTPHeader) ProtoMessage ¶
func (*HTTPHeader) ProtoMessage()
func (*HTTPHeader) ProtoReflect ¶
func (x *HTTPHeader) ProtoReflect() protoreflect.Message
func (*HTTPHeader) Reset ¶
func (x *HTTPHeader) Reset()
func (*HTTPHeader) String ¶
func (x *HTTPHeader) String() string
type HTTPOverGRPCServiceClient ¶
type HTTPOverGRPCServiceClient interface {
HTTP(ctx context.Context, opts ...grpc.CallOption) (HTTPOverGRPCService_HTTPClient, error)
}
HTTPOverGRPCServiceClient is the client API for HTTPOverGRPCService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewHTTPOverGRPCServiceClient ¶
func NewHTTPOverGRPCServiceClient(cc grpc.ClientConnInterface) HTTPOverGRPCServiceClient
type HTTPOverGRPCServiceServer ¶
type HTTPOverGRPCServiceServer interface {
HTTP(HTTPOverGRPCService_HTTPServer) error
}
HTTPOverGRPCServiceServer is the server API for HTTPOverGRPCService service. All implementations should embed UnimplementedHTTPOverGRPCServiceServer for forward compatibility
type HTTPOverGRPCService_HTTPClient ¶
type HTTPOverGRPCService_HTTPClient interface { Send(*HTTPRequest) error Recv() (*HTTPResponse, error) grpc.ClientStream }
type HTTPOverGRPCService_HTTPServer ¶
type HTTPOverGRPCService_HTTPServer interface { Send(*HTTPResponse) error Recv() (*HTTPRequest, error) grpc.ServerStream }
type HTTPRequest ¶
type HTTPRequest struct { Method string `protobuf:"bytes,1,opt,name=method,proto3" json:"method,omitempty"` Url string `protobuf:"bytes,2,opt,name=url,proto3" json:"url,omitempty"` Proto string `protobuf:"bytes,3,opt,name=proto,proto3" json:"proto,omitempty"` Headers []*HTTPHeader `protobuf:"bytes,4,rep,name=headers,proto3" json:"headers,omitempty"` RemoteAddr string `protobuf:"bytes,5,opt,name=remote_addr,json=remoteAddr,proto3" json:"remote_addr,omitempty"` BodyData []byte `protobuf:"bytes,6,opt,name=body_data,json=bodyData,proto3" json:"body_data,omitempty"` // contains filtered or unexported fields }
func (*HTTPRequest) Descriptor
deprecated
func (*HTTPRequest) Descriptor() ([]byte, []int)
Deprecated: Use HTTPRequest.ProtoReflect.Descriptor instead.
func (*HTTPRequest) GetBodyData ¶
func (x *HTTPRequest) GetBodyData() []byte
func (*HTTPRequest) GetHeaders ¶
func (x *HTTPRequest) GetHeaders() []*HTTPHeader
func (*HTTPRequest) GetMethod ¶
func (x *HTTPRequest) GetMethod() string
func (*HTTPRequest) GetProto ¶
func (x *HTTPRequest) GetProto() string
func (*HTTPRequest) GetRemoteAddr ¶
func (x *HTTPRequest) GetRemoteAddr() string
func (*HTTPRequest) GetUrl ¶
func (x *HTTPRequest) GetUrl() string
func (*HTTPRequest) ProtoMessage ¶
func (*HTTPRequest) ProtoMessage()
func (*HTTPRequest) ProtoReflect ¶
func (x *HTTPRequest) ProtoReflect() protoreflect.Message
func (*HTTPRequest) Reset ¶
func (x *HTTPRequest) Reset()
func (*HTTPRequest) String ¶
func (x *HTTPRequest) String() string
type HTTPResponse ¶
type HTTPResponse struct { StatusCode int32 `protobuf:"varint,1,opt,name=status_code,json=statusCode,proto3" json:"status_code,omitempty"` Headers []*HTTPHeader `protobuf:"bytes,2,rep,name=headers,proto3" json:"headers,omitempty"` BodyData []byte `protobuf:"bytes,3,opt,name=body_data,json=bodyData,proto3" json:"body_data,omitempty"` // contains filtered or unexported fields }
func (*HTTPResponse) Descriptor
deprecated
func (*HTTPResponse) Descriptor() ([]byte, []int)
Deprecated: Use HTTPResponse.ProtoReflect.Descriptor instead.
func (*HTTPResponse) GetBodyData ¶
func (x *HTTPResponse) GetBodyData() []byte
func (*HTTPResponse) GetHeaders ¶
func (x *HTTPResponse) GetHeaders() []*HTTPHeader
func (*HTTPResponse) GetStatusCode ¶
func (x *HTTPResponse) GetStatusCode() int32
func (*HTTPResponse) ProtoMessage ¶
func (*HTTPResponse) ProtoMessage()
func (*HTTPResponse) ProtoReflect ¶
func (x *HTTPResponse) ProtoReflect() protoreflect.Message
func (*HTTPResponse) Reset ¶
func (x *HTTPResponse) Reset()
func (*HTTPResponse) String ¶
func (x *HTTPResponse) String() string
type UnimplementedHTTPOverGRPCServiceServer ¶
type UnimplementedHTTPOverGRPCServiceServer struct { }
UnimplementedHTTPOverGRPCServiceServer should be embedded to have forward compatible implementations.
type UnsafeHTTPOverGRPCServiceServer ¶
type UnsafeHTTPOverGRPCServiceServer interface {
// contains filtered or unexported methods
}
UnsafeHTTPOverGRPCServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to HTTPOverGRPCServiceServer will result in compilation errors.