ghttpproto

package
v0.99.99-test-ignore Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2021 License: BSD-3-Clause Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterHTTPServer

func RegisterHTTPServer(s *grpc.Server, srv HTTPServer)

Types

type Certificates

type Certificates struct {
	Cert                 [][]byte `protobuf:"bytes,1,rep,name=cert,proto3" json:"cert,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Certificates) Descriptor

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

func (*Certificates) GetCert

func (m *Certificates) GetCert() [][]byte

func (*Certificates) ProtoMessage

func (*Certificates) ProtoMessage()

func (*Certificates) Reset

func (m *Certificates) Reset()

func (*Certificates) String

func (m *Certificates) String() string

func (*Certificates) XXX_DiscardUnknown

func (m *Certificates) XXX_DiscardUnknown()

func (*Certificates) XXX_Marshal

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

func (*Certificates) XXX_Merge

func (m *Certificates) XXX_Merge(src proto.Message)

func (*Certificates) XXX_Size

func (m *Certificates) XXX_Size() int

func (*Certificates) XXX_Unmarshal

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

type ConnectionState

type ConnectionState struct {
	Version                     uint32          `protobuf:"varint,1,opt,name=version,proto3" json:"version,omitempty"`
	HandshakeComplete           bool            `protobuf:"varint,2,opt,name=handshakeComplete,proto3" json:"handshakeComplete,omitempty"`
	DidResume                   bool            `protobuf:"varint,3,opt,name=didResume,proto3" json:"didResume,omitempty"`
	CipherSuite                 uint32          `protobuf:"varint,4,opt,name=cipherSuite,proto3" json:"cipherSuite,omitempty"`
	NegotiatedProtocol          string          `protobuf:"bytes,5,opt,name=negotiatedProtocol,proto3" json:"negotiatedProtocol,omitempty"`
	NegotiatedProtocolIsMutual  bool            `protobuf:"varint,6,opt,name=negotiatedProtocolIsMutual,proto3" json:"negotiatedProtocolIsMutual,omitempty"`
	ServerName                  string          `protobuf:"bytes,7,opt,name=serverName,proto3" json:"serverName,omitempty"`
	PeerCertificates            *Certificates   `protobuf:"bytes,8,opt,name=peerCertificates,proto3" json:"peerCertificates,omitempty"`
	VerifiedChains              []*Certificates `protobuf:"bytes,9,rep,name=verifiedChains,proto3" json:"verifiedChains,omitempty"`
	SignedCertificateTimestamps [][]byte        `protobuf:"bytes,10,rep,name=signedCertificateTimestamps,proto3" json:"signedCertificateTimestamps,omitempty"`
	OcspResponse                []byte          `protobuf:"bytes,11,opt,name=ocspResponse,proto3" json:"ocspResponse,omitempty"`
	TlsUnique                   []byte          `protobuf:"bytes,12,opt,name=tlsUnique,proto3" json:"tlsUnique,omitempty"`
	XXX_NoUnkeyedLiteral        struct{}        `json:"-"`
	XXX_unrecognized            []byte          `json:"-"`
	XXX_sizecache               int32           `json:"-"`
}

func (*ConnectionState) Descriptor

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

func (*ConnectionState) GetCipherSuite

func (m *ConnectionState) GetCipherSuite() uint32

func (*ConnectionState) GetDidResume

func (m *ConnectionState) GetDidResume() bool

func (*ConnectionState) GetHandshakeComplete

func (m *ConnectionState) GetHandshakeComplete() bool

func (*ConnectionState) GetNegotiatedProtocol

func (m *ConnectionState) GetNegotiatedProtocol() string

func (*ConnectionState) GetNegotiatedProtocolIsMutual

func (m *ConnectionState) GetNegotiatedProtocolIsMutual() bool

func (*ConnectionState) GetOcspResponse

func (m *ConnectionState) GetOcspResponse() []byte

func (*ConnectionState) GetPeerCertificates

func (m *ConnectionState) GetPeerCertificates() *Certificates

func (*ConnectionState) GetServerName

func (m *ConnectionState) GetServerName() string

func (*ConnectionState) GetSignedCertificateTimestamps

func (m *ConnectionState) GetSignedCertificateTimestamps() [][]byte

func (*ConnectionState) GetTlsUnique

func (m *ConnectionState) GetTlsUnique() []byte

func (*ConnectionState) GetVerifiedChains

func (m *ConnectionState) GetVerifiedChains() []*Certificates

func (*ConnectionState) GetVersion

func (m *ConnectionState) GetVersion() uint32

func (*ConnectionState) ProtoMessage

func (*ConnectionState) ProtoMessage()

func (*ConnectionState) Reset

func (m *ConnectionState) Reset()

func (*ConnectionState) String

func (m *ConnectionState) String() string

func (*ConnectionState) XXX_DiscardUnknown

func (m *ConnectionState) XXX_DiscardUnknown()

func (*ConnectionState) XXX_Marshal

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

func (*ConnectionState) XXX_Merge

func (m *ConnectionState) XXX_Merge(src proto.Message)

func (*ConnectionState) XXX_Size

func (m *ConnectionState) XXX_Size() int

func (*ConnectionState) XXX_Unmarshal

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

type Element

type Element struct {
	Key                  string   `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	Values               []string `protobuf:"bytes,2,rep,name=values,proto3" json:"values,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Element) Descriptor

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

func (*Element) GetKey

func (m *Element) GetKey() string

func (*Element) GetValues

func (m *Element) GetValues() []string

func (*Element) ProtoMessage

func (*Element) ProtoMessage()

func (*Element) Reset

func (m *Element) Reset()

func (*Element) String

func (m *Element) String() string

func (*Element) XXX_DiscardUnknown

func (m *Element) XXX_DiscardUnknown()

func (*Element) XXX_Marshal

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

func (*Element) XXX_Merge

func (m *Element) XXX_Merge(src proto.Message)

func (*Element) XXX_Size

func (m *Element) XXX_Size() int

func (*Element) XXX_Unmarshal

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

type HTTPClient

type HTTPClient interface {
	Handle(ctx context.Context, in *HTTPRequest, opts ...grpc.CallOption) (*HTTPResponse, error)
}

HTTPClient is the client API for HTTP service.

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

func NewHTTPClient

func NewHTTPClient(cc grpc.ClientConnInterface) HTTPClient

type HTTPRequest

type HTTPRequest struct {
	ResponseWriter       *ResponseWriter `protobuf:"bytes,1,opt,name=responseWriter,proto3" json:"responseWriter,omitempty"`
	Request              *Request        `protobuf:"bytes,2,opt,name=request,proto3" json:"request,omitempty"`
	XXX_NoUnkeyedLiteral struct{}        `json:"-"`
	XXX_unrecognized     []byte          `json:"-"`
	XXX_sizecache        int32           `json:"-"`
}

func (*HTTPRequest) Descriptor

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

func (*HTTPRequest) GetRequest

func (m *HTTPRequest) GetRequest() *Request

func (*HTTPRequest) GetResponseWriter

func (m *HTTPRequest) GetResponseWriter() *ResponseWriter

func (*HTTPRequest) ProtoMessage

func (*HTTPRequest) ProtoMessage()

func (*HTTPRequest) Reset

func (m *HTTPRequest) Reset()

func (*HTTPRequest) String

func (m *HTTPRequest) String() string

func (*HTTPRequest) XXX_DiscardUnknown

func (m *HTTPRequest) XXX_DiscardUnknown()

func (*HTTPRequest) XXX_Marshal

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

func (*HTTPRequest) XXX_Merge

func (m *HTTPRequest) XXX_Merge(src proto.Message)

func (*HTTPRequest) XXX_Size

func (m *HTTPRequest) XXX_Size() int

func (*HTTPRequest) XXX_Unmarshal

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

type HTTPResponse

type HTTPResponse struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*HTTPResponse) Descriptor

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

func (*HTTPResponse) ProtoMessage

func (*HTTPResponse) ProtoMessage()

func (*HTTPResponse) Reset

func (m *HTTPResponse) Reset()

func (*HTTPResponse) String

func (m *HTTPResponse) String() string

func (*HTTPResponse) XXX_DiscardUnknown

func (m *HTTPResponse) XXX_DiscardUnknown()

func (*HTTPResponse) XXX_Marshal

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

func (*HTTPResponse) XXX_Merge

func (m *HTTPResponse) XXX_Merge(src proto.Message)

func (*HTTPResponse) XXX_Size

func (m *HTTPResponse) XXX_Size() int

func (*HTTPResponse) XXX_Unmarshal

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

type HTTPServer

type HTTPServer interface {
	Handle(context.Context, *HTTPRequest) (*HTTPResponse, error)
}

HTTPServer is the server API for HTTP service.

type Request

type Request struct {
	Method               string           `protobuf:"bytes,1,opt,name=method,proto3" json:"method,omitempty"`
	Url                  *URL             `protobuf:"bytes,2,opt,name=url,proto3" json:"url,omitempty"`
	Proto                string           `protobuf:"bytes,3,opt,name=proto,proto3" json:"proto,omitempty"`
	ProtoMajor           int32            `protobuf:"varint,4,opt,name=protoMajor,proto3" json:"protoMajor,omitempty"`
	ProtoMinor           int32            `protobuf:"varint,5,opt,name=protoMinor,proto3" json:"protoMinor,omitempty"`
	Header               []*Element       `protobuf:"bytes,6,rep,name=header,proto3" json:"header,omitempty"`
	Body                 uint32           `protobuf:"varint,7,opt,name=body,proto3" json:"body,omitempty"`
	ContentLength        int64            `protobuf:"varint,8,opt,name=contentLength,proto3" json:"contentLength,omitempty"`
	TransferEncoding     []string         `protobuf:"bytes,9,rep,name=transferEncoding,proto3" json:"transferEncoding,omitempty"`
	Host                 string           `protobuf:"bytes,10,opt,name=host,proto3" json:"host,omitempty"`
	Form                 []*Element       `protobuf:"bytes,11,rep,name=form,proto3" json:"form,omitempty"`
	PostForm             []*Element       `protobuf:"bytes,12,rep,name=postForm,proto3" json:"postForm,omitempty"`
	TrailerKeys          []string         `protobuf:"bytes,13,rep,name=trailerKeys,proto3" json:"trailerKeys,omitempty"`
	RemoteAddr           string           `protobuf:"bytes,14,opt,name=remoteAddr,proto3" json:"remoteAddr,omitempty"`
	RequestURI           string           `protobuf:"bytes,15,opt,name=requestURI,proto3" json:"requestURI,omitempty"`
	Tls                  *ConnectionState `protobuf:"bytes,16,opt,name=tls,proto3" json:"tls,omitempty"`
	XXX_NoUnkeyedLiteral struct{}         `json:"-"`
	XXX_unrecognized     []byte           `json:"-"`
	XXX_sizecache        int32            `json:"-"`
}

func (*Request) Descriptor

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

func (*Request) GetBody

func (m *Request) GetBody() uint32

func (*Request) GetContentLength

func (m *Request) GetContentLength() int64

func (*Request) GetForm

func (m *Request) GetForm() []*Element

func (*Request) GetHeader

func (m *Request) GetHeader() []*Element

func (*Request) GetHost

func (m *Request) GetHost() string

func (*Request) GetMethod

func (m *Request) GetMethod() string

func (*Request) GetPostForm

func (m *Request) GetPostForm() []*Element

func (*Request) GetProto

func (m *Request) GetProto() string

func (*Request) GetProtoMajor

func (m *Request) GetProtoMajor() int32

func (*Request) GetProtoMinor

func (m *Request) GetProtoMinor() int32

func (*Request) GetRemoteAddr

func (m *Request) GetRemoteAddr() string

func (*Request) GetRequestURI

func (m *Request) GetRequestURI() string

func (*Request) GetTls

func (m *Request) GetTls() *ConnectionState

func (*Request) GetTrailerKeys

func (m *Request) GetTrailerKeys() []string

func (*Request) GetTransferEncoding

func (m *Request) GetTransferEncoding() []string

func (*Request) GetUrl

func (m *Request) GetUrl() *URL

func (*Request) ProtoMessage

func (*Request) ProtoMessage()

func (*Request) Reset

func (m *Request) Reset()

func (*Request) String

func (m *Request) String() string

func (*Request) XXX_DiscardUnknown

func (m *Request) XXX_DiscardUnknown()

func (*Request) XXX_Marshal

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

func (*Request) XXX_Merge

func (m *Request) XXX_Merge(src proto.Message)

func (*Request) XXX_Size

func (m *Request) XXX_Size() int

func (*Request) XXX_Unmarshal

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

type ResponseWriter added in v1.0.2

type ResponseWriter struct {
	Id                   uint32     `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Header               []*Element `protobuf:"bytes,2,rep,name=header,proto3" json:"header,omitempty"`
	XXX_NoUnkeyedLiteral struct{}   `json:"-"`
	XXX_unrecognized     []byte     `json:"-"`
	XXX_sizecache        int32      `json:"-"`
}

func (*ResponseWriter) Descriptor added in v1.0.2

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

func (*ResponseWriter) GetHeader added in v1.0.2

func (m *ResponseWriter) GetHeader() []*Element

func (*ResponseWriter) GetId added in v1.0.2

func (m *ResponseWriter) GetId() uint32

func (*ResponseWriter) ProtoMessage added in v1.0.2

func (*ResponseWriter) ProtoMessage()

func (*ResponseWriter) Reset added in v1.0.2

func (m *ResponseWriter) Reset()

func (*ResponseWriter) String added in v1.0.2

func (m *ResponseWriter) String() string

func (*ResponseWriter) XXX_DiscardUnknown added in v1.0.2

func (m *ResponseWriter) XXX_DiscardUnknown()

func (*ResponseWriter) XXX_Marshal added in v1.0.2

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

func (*ResponseWriter) XXX_Merge added in v1.0.2

func (m *ResponseWriter) XXX_Merge(src proto.Message)

func (*ResponseWriter) XXX_Size added in v1.0.2

func (m *ResponseWriter) XXX_Size() int

func (*ResponseWriter) XXX_Unmarshal added in v1.0.2

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

type URL

type URL struct {
	Scheme               string    `protobuf:"bytes,1,opt,name=scheme,proto3" json:"scheme,omitempty"`
	Opaque               string    `protobuf:"bytes,2,opt,name=opaque,proto3" json:"opaque,omitempty"`
	User                 *Userinfo `protobuf:"bytes,3,opt,name=user,proto3" json:"user,omitempty"`
	Host                 string    `protobuf:"bytes,4,opt,name=host,proto3" json:"host,omitempty"`
	Path                 string    `protobuf:"bytes,5,opt,name=path,proto3" json:"path,omitempty"`
	RawPath              string    `protobuf:"bytes,6,opt,name=rawPath,proto3" json:"rawPath,omitempty"`
	ForceQuery           bool      `protobuf:"varint,7,opt,name=forceQuery,proto3" json:"forceQuery,omitempty"`
	RawQuery             string    `protobuf:"bytes,8,opt,name=rawQuery,proto3" json:"rawQuery,omitempty"`
	Fragment             string    `protobuf:"bytes,9,opt,name=fragment,proto3" json:"fragment,omitempty"`
	XXX_NoUnkeyedLiteral struct{}  `json:"-"`
	XXX_unrecognized     []byte    `json:"-"`
	XXX_sizecache        int32     `json:"-"`
}

func (*URL) Descriptor

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

func (*URL) GetForceQuery

func (m *URL) GetForceQuery() bool

func (*URL) GetFragment

func (m *URL) GetFragment() string

func (*URL) GetHost

func (m *URL) GetHost() string

func (*URL) GetOpaque

func (m *URL) GetOpaque() string

func (*URL) GetPath

func (m *URL) GetPath() string

func (*URL) GetRawPath

func (m *URL) GetRawPath() string

func (*URL) GetRawQuery

func (m *URL) GetRawQuery() string

func (*URL) GetScheme

func (m *URL) GetScheme() string

func (*URL) GetUser

func (m *URL) GetUser() *Userinfo

func (*URL) ProtoMessage

func (*URL) ProtoMessage()

func (*URL) Reset

func (m *URL) Reset()

func (*URL) String

func (m *URL) String() string

func (*URL) XXX_DiscardUnknown

func (m *URL) XXX_DiscardUnknown()

func (*URL) XXX_Marshal

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

func (*URL) XXX_Merge

func (m *URL) XXX_Merge(src proto.Message)

func (*URL) XXX_Size

func (m *URL) XXX_Size() int

func (*URL) XXX_Unmarshal

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

type UnimplementedHTTPServer

type UnimplementedHTTPServer struct {
}

UnimplementedHTTPServer can be embedded to have forward compatible implementations.

func (*UnimplementedHTTPServer) Handle

type Userinfo

type Userinfo struct {
	Username             string   `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"`
	Password             string   `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"`
	PasswordSet          bool     `protobuf:"varint,3,opt,name=passwordSet,proto3" json:"passwordSet,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Userinfo) Descriptor

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

func (*Userinfo) GetPassword

func (m *Userinfo) GetPassword() string

func (*Userinfo) GetPasswordSet

func (m *Userinfo) GetPasswordSet() bool

func (*Userinfo) GetUsername

func (m *Userinfo) GetUsername() string

func (*Userinfo) ProtoMessage

func (*Userinfo) ProtoMessage()

func (*Userinfo) Reset

func (m *Userinfo) Reset()

func (*Userinfo) String

func (m *Userinfo) String() string

func (*Userinfo) XXX_DiscardUnknown

func (m *Userinfo) XXX_DiscardUnknown()

func (*Userinfo) XXX_Marshal

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

func (*Userinfo) XXX_Merge

func (m *Userinfo) XXX_Merge(src proto.Message)

func (*Userinfo) XXX_Size

func (m *Userinfo) XXX_Size() int

func (*Userinfo) XXX_Unmarshal

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

Jump to

Keyboard shortcuts

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