using NotificationClient;
using NotificationShared;

namespace EonaCat.Helpers.EonaCat.Notifications
{
    class ConnectionSettings : IConnectionSettings
    {
        public string Address { get => "127.0.0.1"; set => throw new NotImplementedException(); }
        public int Port { get => 8888; set => throw new NotImplementedException(); }
        public Protocol Protocol { get => Protocol.UDP; set => throw new NotImplementedException(); }
        public int MaxConnections { get => 10000; set => throw new NotImplementedException(); }
    }
    public class test
    {

        static async Task Main(string[] args)
        {
            NotificationServiceClient client = new NotificationServiceClient(new ConnectionSettings());
            client.OpenConnectionAsync(received);
            Console.WriteLine("Press any key to continue...");
            Console.ReadKey(true);
        }

        private static void received(NotificationPayload obj)
        {
            Console.WriteLine(obj.Message);
        }
    }
}