Click here to Skip to main content
15,893,486 members
Articles / Web Development / HTML

My own Mailinator in 5 minutes

Rate me:
Please Sign up or sign in to vote.
5.00/5 (6 votes)
19 Nov 2012CPOL6 min read 31.7K   405   13  
A simple Mailinator clone developed in five minutes with the NetFluid framework
using System;

namespace LumiSoft.Net.DNS
{
	/// <summary>
	/// This is base class for DNS records.
	/// </summary>
	public abstract class DNS_rr
	{
        private readonly string    m_Name = "";
		private readonly DNS_QType m_Type = DNS_QType.A;
		private readonly int       m_TTL  = -1;

		/// <summary>
		/// Default constructor.
		/// </summary>
        /// <param name="name">DNS domain name that owns a resource record.</param>
		/// <param name="recordType">Record type (A,MX, ...).</param>
		/// <param name="ttl">TTL (time to live) value in seconds.</param>
		protected DNS_rr(string name,DNS_QType recordType,int ttl)
		{
            m_Name = name;
			m_Type = recordType;
			m_TTL  = ttl;
        }


        #region Properties Implementation

        /// <summary>
        /// Gets DNS domain name that owns a resource record.
        /// </summary>
        public string Name
        {
            get{ return m_Name; }
        }

        /// <summary>
		/// Gets record type (A,MX,...).
		/// </summary>
		public DNS_QType RecordType
		{
			get{ return m_Type; }
		}

		/// <summary>
		/// Gets TTL (time to live) value in seconds.
		/// </summary>
		public int TTL
		{
			get{ return m_TTL; }
		}

		#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)


Written By
Chief Technology Officer Genny Mobility
Italy Italy
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions