Documentation ¶
Index ¶
- func RegisterInboundConnectionHandlerFactory(name string, factory InboundConnectionHandlerFactory) error
- func RegisterOutboundConnectionHandlerFactory(name string, factory OutboundConnectionHandlerFactory) error
- type InboundConnectionHandler
- type InboundConnectionHandlerFactory
- type OutboundConnectionHandler
- type OutboundConnectionHandlerFactory
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterInboundConnectionHandlerFactory ¶
func RegisterInboundConnectionHandlerFactory(name string, factory InboundConnectionHandlerFactory) error
func RegisterOutboundConnectionHandlerFactory ¶
func RegisterOutboundConnectionHandlerFactory(name string, factory OutboundConnectionHandlerFactory) error
Types ¶
type InboundConnectionHandler ¶
type InboundConnectionHandler interface { // Listen starts a InboundConnectionHandler by listen on a specific port. This method is called // exactly once during runtime. Listen(port v2net.Port) error }
A InboundConnectionHandler handles inbound network connections to V2Ray.
type InboundConnectionHandlerFactory ¶
type InboundConnectionHandlerFactory interface { // Create creates a new InboundConnectionHandler with given configuration. Create(space app.Space, config interface{}) (InboundConnectionHandler, error) }
A InboundConnectionHandlerFactory creates InboundConnectionHandler on demand.
func GetInboundConnectionHandlerFactory ¶
func GetInboundConnectionHandlerFactory(name string) InboundConnectionHandlerFactory
type OutboundConnectionHandler ¶
type OutboundConnectionHandler interface { // Dispatch sends one or more Packets to its destination. Dispatch(firstPacket v2net.Packet, ray ray.OutboundRay) error }
An OutboundConnectionHandler handles outbound network connection for V2Ray.
type OutboundConnectionHandlerFactory ¶
type OutboundConnectionHandlerFactory interface { // Create creates a new OutboundConnectionHandler with given config. Create(space app.Space, config interface{}) (OutboundConnectionHandler, error) }
An OutboundConnectionHandlerFactory creates OutboundConnectionHandler on demand.
func GetOutboundConnectionHandlerFactory ¶
func GetOutboundConnectionHandlerFactory(name string) OutboundConnectionHandlerFactory
Click to show internal directories.
Click to hide internal directories.