Example #1
0
 public static string toString(Message message)
 {
     return(new StringBuilder()
            .Append(message.getSender())
            .Append("|")
            .Append(message.getText())
            .Append("|")
            .Append(message.getDate().ToString())
            .ToString());
 }
Example #2
0
        public void addMessage(Message message)
        {
            foreach (Message itr in messages)
            {
                if (itr.getText() == message.getText())
                {
                    return;
                }
            }

            messages.Add(message);
        }