Esempio n. 1
0
 public string MessageToString(FlooMessage message)
 {
     return($"From: {message.FromAlias} [{message.From}]\r\n" +
            $"To: {message.ToAlias} [{message.To}]\r\n" +
            $"Content:-----------------------\r\n" +
            $"{message.Content}\r\n" +
            $"--------------------------------\r\n");
 }
Esempio n. 2
0
        public Result Send(FlooMessage message)
        {
            System.Console.WriteLine($"Sending Message ({message.Type}) =======");

            System.Console.WriteLine($"_");

            System.Console.WriteLine($"{MessageToString(message)}");

            System.Console.WriteLine($"_");

            System.Console.WriteLine($"==================================");

            return(new Result(false));
        }
Esempio n. 3
0
        static void PlugMessagingFloomeen(out MessagingFloomeen floomeen, MessagePOCO message, FlooMessage email)
        {
            floomeen = Factory <MessagingFloomeen> .Create();

            floomeen.InjectAdapter <EmailGatewayAdapter>();

            floomeen.AddContextData(MessagingFloomeen.ContextKey.Message, email);

            floomeen.AddContextData(MessagingFloomeen.ContextKey.MaxRetries, new FlooInt(3));

            floomeen.Plug(message);
        }