Documentation ¶
Index ¶
- type Client
- func (c *Client) Close() error
- func (c *Client) LocalAddr() net.Addr
- func (c *Client) Read(p []byte) (int, error)
- func (c *Client) RemoteAddr() net.Addr
- func (c *Client) SetDeadline(t time.Time) error
- func (c *Client) SetReadDeadline(t time.Time) error
- func (c *Client) SetWriteDeadline(t time.Time) error
- func (c *Client) Write(b []byte) (int, error)
- type Server
- func (s *Server) Close(ctx context.Context, req *emptypb.Empty) (*emptypb.Empty, error)
- func (s *Server) Read(ctx context.Context, req *gconnproto.ReadRequest) (*gconnproto.ReadResponse, error)
- func (s *Server) SetDeadline(ctx context.Context, req *gconnproto.SetDeadlineRequest) (*emptypb.Empty, error)
- func (s *Server) SetReadDeadline(ctx context.Context, req *gconnproto.SetDeadlineRequest) (*emptypb.Empty, error)
- func (s *Server) SetWriteDeadline(ctx context.Context, req *gconnproto.SetDeadlineRequest) (*emptypb.Empty, error)
- func (s *Server) Write(ctx context.Context, req *gconnproto.WriteRequest) (*gconnproto.WriteResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is an implementation of a connection that talks over RPC.
func NewClient ¶
func NewClient(client gconnproto.ConnClient, local, remote net.Addr, toClose ...io.Closer) *Client
NewClient returns a connection connected to a remote connection
func (*Client) RemoteAddr ¶
type Server ¶
type Server struct { gconnproto.UnimplementedConnServer // contains filtered or unexported fields }
Server is an http.Conn that is managed over RPC.
func NewServer ¶
func NewServer(conn net.Conn, closer *grpcutils.ServerCloser) *Server
NewServer returns an http.Conn managed remotely
func (*Server) Read ¶
func (s *Server) Read(ctx context.Context, req *gconnproto.ReadRequest) (*gconnproto.ReadResponse, error)
func (*Server) SetDeadline ¶
func (s *Server) SetDeadline(ctx context.Context, req *gconnproto.SetDeadlineRequest) (*emptypb.Empty, error)
func (*Server) SetReadDeadline ¶
func (s *Server) SetReadDeadline(ctx context.Context, req *gconnproto.SetDeadlineRequest) (*emptypb.Empty, error)
func (*Server) SetWriteDeadline ¶
func (s *Server) SetWriteDeadline(ctx context.Context, req *gconnproto.SetDeadlineRequest) (*emptypb.Empty, error)
func (*Server) Write ¶
func (s *Server) Write(ctx context.Context, req *gconnproto.WriteRequest) (*gconnproto.WriteResponse, error)
Click to show internal directories.
Click to hide internal directories.