Click here to Skip to main content
15,888,527 members
Articles / Web Development / ASP.NET

Open Source Extensible Enterprise n-tier Application Framework with Multilayered Architecture

Rate me:
Please Sign up or sign in to vote.
4.67/5 (2 votes)
3 Dec 2010MIT3 min read 36.9K   770   41  
Xenta architecture overview
using System;
using SiberTek.Xenta.Managers;

namespace SiberTek.Xenta.Entities
{
    /// <summary>
    /// Represents an forum private message entity
    /// </summary>
    public class ForumPrivateMessageInfo : BusinessEntityBase
    {
        #region Fields
        private int _privateMessageID;
        private int _authorID;
        private int _recipientID;
        private string _subject;
        private string _text;
        private bool _isActive;
        private bool _isRead;
        private bool _isDeletedByAuthor;
        private bool _isDeletedByRecipient;
        private DateTime _createdOn;
        private DateTime _updatedOn;
        #endregion

        #region Constructors
        public ForumPrivateMessageInfo() : this(0, 0, 0, String.Empty, String.Empty, false, false, false, false, DateTime.UtcNow, DateTime.UtcNow)
        {
        }

        public ForumPrivateMessageInfo(int privateMessageID, int authorID, int recipientID, string subject, string text, bool isRead, bool isDeletedByAuthor, bool isDeletedByRecipient, bool isActive, DateTime createdOn, DateTime updatedOn)
        {
            _privateMessageID = privateMessageID;
            _authorID = authorID;
            _recipientID = recipientID;
            _subject = subject;
            _text = text;
            _isRead = isRead;
            _isDeletedByAuthor = isDeletedByAuthor;
            _isDeletedByRecipient = isDeletedByRecipient;
            _isActive = isActive;
            _createdOn = createdOn;
            _updatedOn = updatedOn;
        }
        #endregion

        #region Properties
        public int PrivateMessageID
        {
            get
            {
                return _privateMessageID;
            }
            set
            {
                _privateMessageID = value;
            }
        }

        public int AuthorID
        {
            get
            {
                return _authorID;
            }
            set
            {
                _authorID = value;
            }
        }

        public UserInfo Author
        {
            get
            {
                return UserManager.Instance.GetUser(AuthorID);
            }
        }

        public int RecipientID
        {
            get
            {
                return _recipientID;
            }
            set
            {
                _recipientID = value;
            }
        }

        public UserInfo Recipient
        {
            get
            {
                return UserManager.Instance.GetUser(RecipientID);
            }
        }

        public string Subject
        {
            get
            {
                return _subject;
            }
            set
            {
                _subject = value;
            }
        }

        public string Text
        {
            get
            {
                return _text;
            }
            set
            {
                _text = value;
            }
        }

        public bool IsActive
        {
            get
            {
                return _isActive;
            }
            set
            {
                _isActive = value;
            }
        }

        public bool IsRead
        {
            get
            {
                return _isRead;
            }
            set
            {
                _isRead = value;
            }
        }

        public bool IsDeletedByAuthor
        {
            get
            {
                return _isDeletedByAuthor;
            }
            set
            {
                _isDeletedByAuthor = value;
            }
        }

        public bool IsDeletedByRecipient
        {
            get
            {
                return _isDeletedByRecipient;
            }
            set
            {
                _isDeletedByRecipient = value;
            }
        }

        public DateTime CreatedOn
        {
            get
            {
                return _createdOn;
            }
            set
            {
                _createdOn = value;
            }
        }

        public DateTime UpdatedOn
        {
            get
            {
                return _updatedOn;
            }
            set
            {
                _updatedOn = value;
            }
        }
        #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 MIT License


Written By
Russian Federation Russian Federation
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions