Click here to Skip to main content
11,640,297 members (60,587 online)
Click here to Skip to main content
Articles » Languages » C# » General » Downloads
Add your own
alternative version

STUN Client

, 20 Apr 2007 CPOL 146.4K 8.2K 65
STUN client C# implementation with sample application
Stun.zip
Stun
Net
docs
dns
dns_records.jpg
dns_records.vsd
Net
_junk
_Obsolete
_Stuff
AUTH
bin
Release
LumiSoft.Net.dll
Data
Dns
Client
FTP
Client
Server
HTTP
Server
ICMP
IMAP
Client
Server
IO
Log
LumiSoft.Net
Mime
vCard
Net.csproj.user
Net.suo
NNTP
Client
POP3
Client
Server
SDP
ServersCore
SIP
Client
Message
Proxy
Stack
SMTP
Client
Server
STUN
Client
Message
STUN_Client_app
STUN_Client_app.suo
STUN_Client_app
bin
Debug
LumiSoft.Net.dll
STUN_Client_app.exe
STUN_Client_app.vshost.exe
dep
LumiSoft.Net.dll
Properties
Settings.settings
using System;
using System.Net;

namespace LumiSoft.Net
{
	/// <summary>
	/// Common interface for socket server sessions.
	/// </summary>
	public interface ISocketServerSession
    {
        #region method Kill

        /// <summary>
        /// Kills session.
        /// </summary>
        void Kill();

        #endregion

        #region method OnSessionTimeout

        /// <summary>
		/// For internal use only !
		/// </summary>
		void OnSessionTimeout();

        #endregion


        #region Properties Implemtation

        /// <summary>
		/// Gets session ID.
		/// </summary>
		string SessionID
		{
			get;
		}

        /// <summary>
		/// Gets session start time.
		/// </summary>
		DateTime SessionStartTime
		{
			get;
		}

        /// <summary>
        /// Gets how many seconds has left before timout is triggered.
        /// </summary>
        int ExpectedTimeout
        {
            get;
        }

        /// <summary>
		/// Gets last data activity time.
		/// </summary>
		DateTime SessionLastDataTime
		{
			get;
        }

        /// <summary>
		/// Gets loggded in user name (session owner).
		/// </summary>
		string UserName
		{
			get;
		}

        /// <summary>
		/// Gets EndPoint which accepted conection.
		/// </summary>
		IPEndPoint LocalEndPoint
		{
			get;
		}

		/// <summary>
		/// Gets connected Host(client) EndPoint.
		/// </summary>
		IPEndPoint RemoteEndPoint
		{
			get;
		}
		
		/// <summary>
		/// Gets or sets custom user data.
		/// </summary>
		object Tag
		{
			get;

			set;
		}

        /// <summary>
        /// Gets log entries that are currently in log buffer.
        /// </summary>
        SocketLogger SessionActiveLog
        {
            get;
        }

        /// <summary>
        /// Gets how many bytes are readed through this session.
        /// </summary>
        long ReadedCount
        {
            get;
        }
        
        /// <summary>
        /// Gets how many bytes are written through this session.
        /// </summary>
        long WrittenCount
        {
            get;
        }
        
        /// <summary>
        /// Gets if the connection is an SSL connection.
        /// </summary>
        bool IsSecureConnection
        {
            get;
        }

        #endregion
    }
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Ivar Lumi
Estonia Estonia
No Biography provided

You may also be interested in...

| Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.150731.1 | Last Updated 20 Apr 2007
Article Copyright 2007 by Ivar Lumi
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid