|
||
class CTelnetSession : public CBase;
The main Symbian telnet class.
Consists of a connection interface and a protocol interface. The connection interface comprises member functions that: connect to, read from, write to and disconnect from a telnet server.
The protocol interface includes member functions that get and set telnet configuration.
CBase
-
Base class for all classes to be instantiated on the heap.
CTelnetSession
- The main Symbian telnet class.
Defined in CTelnetSession
:
Connect(const TDesC &)
Connects to aSeverName on the standard telnet port (port 23). Connect(const TDesC &,TUint)
Connects to aServerName on user specified port. Connect(const TInetAddr &)
Connects to aNetAddr on the standard telnet port (port 23). Connect(const TInetAddr &,TUint)
Connects to aNetAddr on user specified port. ConstructL(const TTelnetConfig &,const MTelnetNotification *)
Second-phase protected constructor, called by CTelnetSession::NewL(const TTelnet...Disconnect()
Disconnects current connection. DoForceLogout()
Forces a logout from the server.DoModifyConfig(TTelnetConfig &)
Sets the telnet connection configuration.NewL(const TTelnetConfig &,const MTelnetNotification *)
Allocates and constructs a new telnet session object.OptionStatus(TOptionStatus &)
Gets the status of the supported RFC-defined options.Read()
Read data received over telnet buffer. Write(TTelnetUserControl &)
Writes NVT code to stream. Prepends <IAC> code (255). Write(const TDesC8 &)
Writes a byte stream over the open telnet connection. Inherited from CBase
:
Delete(CBase *)
Deletes the specified object.Extension_(TUint,TAny *&,TAny *)
Extension function operator new(TUint)
Allocates the object from the heap and then initialises its contents to binary z...operator new(TUint,TAny *)
Initialises the object to binary zeroes.operator new(TUint,TLeave)
Allocates the object from the heap and then initialises its contents to binary z...operator new(TUint,TLeave,TUint)
Allocates the object from the heap and then initialises its contents to binary z...operator new(TUint,TUint)
Allocates the object from the heap and then initialises its contents to binary z...IMPORT_C static CTelnetSession* NewL(const TTelnetConfig &aConfig, const MTelnetNotification *aNotifier);
Allocates and constructs a new telnet session object.
|
|
protected: IMPORT_C void ConstructL(const TTelnetConfig &aConfig, const MTelnetNotification *aNotifier);
Second-phase protected constructor, called by CTelnetSession::NewL(const TTelnetConfig &,const MTelnetNotification *)
.
|
CTelnetSession::NewL(const TTelnetConfig &,const MTelnetNotification *)
Allocates and constructs a new telnet session object.IMPORT_C TInt Connect(const TInetAddr &aNetAddr);
Connects to aNetAddr on the standard telnet port (port 23).
Initiates connection to the specified IP address on the standard telnet port (port 23).
The client is asynchronously notified of successful connection by the MTelnetNotification::Connected()
function.
|
|
IMPORT_C TInt Connect(const TInetAddr &aNetAddr, TUint aPort);
Connects to aNetAddr on user specified port.
Initiates connection to the specified IP address and telnet port.
The client is asynchronously notified of successful connection by the MTelnetNotification::Connected()
function.
|
|
IMPORT_C TInt Connect(const TDesC &aServerName);
Connects to aSeverName on the standard telnet port (port 23).
Connects to the specified server on the standard telnet port (port 23).
The client is asynchronously notified of successful connection by the MTelnetNotification::Connected()
function.
|
|
IMPORT_C TInt Connect(const TDesC &aServerName, TUint aPort);
Connects to aServerName on user specified port.
Connects to the specified server on the specified port.
The client is asynchronously notified of successful connection by the MTelnetNotification::Connected()
function.
|
|
IMPORT_C TInt Disconnect();
Disconnects current connection.
Requests disconnection from the server.
|
IMPORT_C TInt Write(const TDesC8 &aBuffer);
Writes a byte stream over the open telnet connection.
Writes a byte stream over the open telnet connection to the telnet server.
The client is notified asynchronously by the:
MTelnetNotification::WriteComplete()
function, if the write is successful
MTelnetNotification::Error(TInt)
function, if the write is not successful.
|
|
IMPORT_C TInt Write(TTelnetUserControl &aControlCode);
Writes NVT code to stream. Prepends <IAC> code (255).
Writes telnet-defined code over the open telnet connection to the telnet server.
The client is asynchronously notified by the:
MTelnetNotification::WriteComplete()
function, if the write is successful
MTelnetNotification::Error(TInt)
function, if the write is not successful.
|
|
IMPORT_C TInt Read();
Read data received over telnet buffer.
Reads the data received over the telnet buffer.
The client is asynchronously notified by the:*
MTelnetNotification::ReadComplete(const TDesC8 &)
function, if the read is successful*
MTelnetNotification::Error(TInt)
function, if the read is not successful.
|
IMPORT_C TInt DoModifyConfig(TTelnetConfig &aConfig);
Sets the telnet connection configuration.
If any options change status as a result, the client is notified through an OptionsChanged() call.
|
|
IMPORT_C TInt OptionStatus(TOptionStatus &aStatus);
Gets the status of the supported RFC-defined options.
See TOptionStatus
for a description of options.
|
|