예제 #1
0
        private FriendlyMessage CreateFriendlyMessageFrom(string sender)
        {
            var message = new FriendlyMessage();

            message.From = Char.IsLower(sender.First())
                       ? CultureInfo.CurrentCulture.TextInfo.ToTitleCase(sender.ToLower())
                       : sender;
            return(message);
        }
예제 #2
0
 private void Send(FriendlyMessage message)
 {
     _destination.Send("From: " + message.From + Environment.NewLine +
                       "To: " + message.To + Environment.NewLine +
                       "Content: " + message.Content);
 }