Documentation ¶
Index ¶
- func ByteToCodeString(b byte) string
- func CodeToString(code IOCode) string
- type IOCode
- type Telnet
- func (t *Telnet) BuildCommand(codes ...IOCode) []byte
- func (t *Telnet) Close() error
- func (t *Telnet) Data(code IOCode) []byte
- func (t *Telnet) DoTerminalType()
- func (t *Telnet) DoWindowSize()
- func (t *Telnet) LocalAddr() net.Addr
- func (t *Telnet) Read(p []byte) (int, error)
- func (t *Telnet) RemoteAddr() net.Addr
- func (t *Telnet) SendCommand(codes ...IOCode)
- func (t *Telnet) SetDeadline(dl time.Time) error
- func (t *Telnet) SetListenFunc(listenFunc func(IOCode, []byte))
- func (t *Telnet) SetReadDeadline(dl time.Time) error
- func (t *Telnet) SetWriteDeadline(dl time.Time) error
- func (t *Telnet) WillEcho()
- func (t *Telnet) WillSga()
- func (t *Telnet) WontEcho()
- func (t *Telnet) Write(p []byte) (int, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ByteToCodeString ¶
func CodeToString ¶
Types ¶
type IOCode ¶
type IOCode int
const ( NUL IOCode = iota // NULL, no operation ECHO IOCode = iota // Echo SGA IOCode = iota // Suppress go ahead ST IOCode = iota // Status TM IOCode = iota // Timing mark BEL IOCode = iota // Bell BS IOCode = iota // Backspace HT IOCode = iota // Horizontal tab LF IOCode = iota // Line feed FF IOCode = iota // Form feed CR IOCode = iota // Carriage return TT IOCode = iota // Terminal type WS IOCode = iota // Window size TS IOCode = iota // Terminal speed RFC IOCode = iota // Remote flow control LM IOCode = iota // Line mode EV IOCode = iota // Environment variables SE IOCode = iota // End of sub negotiation parameters. NOP IOCode = iota // No operation. DM IOCode = iota // Data Mark. The data stream portion of a Sync. This should always be accompanied by a TCP Urgent notification. BRK IOCode = iota // Break. NVT character BRK. IP IOCode = iota // Interrupt Process AO IOCode = iota // Abort output AYT IOCode = iota // Are you there EC IOCode = iota // Erase character EL IOCode = iota // Erase line GA IOCode = iota // Go ahead signal SB IOCode = iota // Indicates that what follows is sub negotiation of the indicated option. WILL IOCode = iota // Indicates the desire to begin performing, or confirmation that you are now performing, the indicated option. WONT IOCode = iota // Indicates the refusal to perform, or continue performing, the indicated option. DO IOCode = iota // Indicates the request that the other party perform, or confirmation that you are expecting the other party to perform, the indicated option. DONT IOCode = iota // Indicates the demand that the other party stop performing, or confirmation that you are no longer expecting the other party to perform, the indicated option. IAC IOCode = iota // Interpret as command // Non-standard codes: CMP1 IOCode = iota // MCCP Compress CMP2 IOCode = iota // MCCP Compress2 AARD IOCode = iota // Aardwolf MUD out of band communication, http://www.aardwolf.com/blog/2008/07/10/telnet-negotiation-control-mud-client-interaction/ ATCP IOCode = iota // Achaea Telnet Client Protocol, http://www.ironrealms.com/rapture/manual/files/FeatATCP-txt.html GMCP IOCode = iota // Generic Mud Communication Protocol )
type Telnet ¶
type Telnet struct {
// contains filtered or unexported fields
}
func (*Telnet) BuildCommand ¶
func (*Telnet) DoTerminalType ¶
func (t *Telnet) DoTerminalType()
func (*Telnet) DoWindowSize ¶
func (t *Telnet) DoWindowSize()
func (*Telnet) RemoteAddr ¶
func (*Telnet) SendCommand ¶
func (*Telnet) SetListenFunc ¶
Click to show internal directories.
Click to hide internal directories.