telnet

package
v0.0.0-...-4f83aec Latest Latest
Warning

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

Go to latest
Published: Apr 6, 2016 License: MIT Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TelnetLogin

func TelnetLogin(conn net.Conn, rooms *room.RoomList, chl io.Writer, cd clientdata.ClientData)

TelnetLogin is used to initiate clients.

func TelnetRegister

func TelnetRegister(conn net.Conn, cd clientdata.ClientData)

TelnetRegister is used to create new accounts using a telnet connection.

Types

type Connection

type Connection struct {
	// contains filtered or unexported fields
}

Connection is used to connect the user to the server.

func New

func New(name string, roomlist *room.RoomList, chatlog io.Writer, data clientdata.ClientData, conn net.Conn) *Connection

New creates a new connection and associated client.

func (*Connection) Close

func (c *Connection) Close()

Close closes out the telnet connection.

func (*Connection) SendMessage

func (c *Connection) SendMessage(m message.Message)

SendMessage is used by the client package to forward messages to the connection so they can be send to the user. This version appends a \r\n and sends the message out the conn.

Jump to

Keyboard shortcuts

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