Пример #1
0
        public virtual Inbox GetInbox()
        {
            var inbox = new Inbox();
            ISet<Comment> comments = GetAllProfileComments();

            foreach (var comment in comments){
                var message = new Message(comment);

                inbox.addMessage(message);
            }

            foreach (var group in Groups){
                foreach (var post in group.MessageList.groupPostList){
                    var message = new Message(post);

                    inbox.addMessage(message);
                }
            }

            inbox.sortAndTruncateMessages();
            return inbox;
        }
Пример #2
0
 public void addMessage(Message message)
 {
     messages.Add(message);
 }