Class Client
Assembly: Netly.dll
View Source
Declaration
public abstract class Client
Derived:
Netly.TcpClient
Properties
Framing
View Source
Declaration
public bool Framing { get; protected set; }
UUID
View Source
Declaration
public string UUID { get; protected set; }
Host
View Source
Declaration
public Host Host { get; protected set; }
IsOpened
View Source
Declaration
public bool IsOpened { get; }
Fields
m_socket
View Source
Declaration
protected Socket m_socket
m_stream
View Source
Declaration
protected NetworkStream m_stream
m_sslStream
View Source
Declaration
protected SslStream m_sslStream
m_closed
View Source
Declaration
protected bool m_closed
m_closing
View Source
Declaration
protected bool m_closing
m_connecting
View Source
Declaration
protected bool m_connecting
m_serverMode
View Source
Declaration
protected bool m_serverMode
Methods
IsConnected()
View Source
Declaration
protected virtual bool IsConnected()
Returns
System.Boolean
Open(Host)
View Source
Declaration
public virtual void Open(Host host)
Parameters
Type | Name |
---|---|
Netly.Core.Host | host |
Receive()
View Source
Declaration
protected virtual void Receive()
Close()
View Source
Declaration
public virtual void Close()
ToData(byte[])
View Source
Declaration
public virtual void ToData(byte[] data)
Parameters
Type | Name |
---|---|
System.Byte[] | data |
ToData(string)
View Source
Declaration
public virtual void ToData(string data)
Parameters
Type | Name |
---|---|
System.String | data |
ToEvent(string, byte[])
View Source
Declaration
public virtual void ToEvent(string name, byte[] data)
Parameters
Type | Name |
---|---|
System.String | name |
System.Byte[] | data |
ToEvent(string, string)
View Source
Declaration
public virtual void ToEvent(string name, string data)
Parameters
Type | Name |
---|---|
System.String | name |
System.String | data |
Destroy()
View Source
Declaration
protected virtual void Destroy()
OnError(Action<Exception>)
View Source
Declaration
public virtual void OnError(Action<Exception> callback)
Parameters
Type | Name |
---|---|
System.Action<System.Exception> | callback |
OnOpen(Action)
View Source
Declaration
public virtual void OnOpen(Action callback)
Parameters
Type | Name |
---|---|
System.Action | callback |
OnClose(Action)
View Source
Declaration
public virtual void OnClose(Action callback)
Parameters
Type | Name |
---|---|
System.Action | callback |
OnData(Action<byte[]>)
View Source
Declaration
public virtual void OnData(Action<byte[]> callback)
Parameters
Type | Name |
---|---|
System.Action<System.Byte[]> | callback |
OnEvent(Action<string, byte[]>)
View Source
Declaration
public virtual void OnEvent(Action<string, byte[]> callback)
Parameters
Type | Name |
---|---|
System.Action<System.String,System.Byte[]> | callback |
OnModify(Action<Socket>)
View Source
Declaration
public virtual void OnModify(Action<Socket> callback)
Parameters
Type | Name |
---|---|
System.Action<System.Net.Sockets.Socket> | callback |