Esempio n. 1
0
        public EzQuoteMain()
        {
            // Establish the uplink connection (using local Unix domain socket)
            FrontEndConnection local = new UnixSocketConnection("/tmp/dotss.socket");
            local.Connect();

            // Instantiate the client context
            ctx_ = ClientContext.CreateClientEndpointContext(local);

            // Authenticate the local user
            ctx_.AuthClient.SelectAuthentication("unix_auth");
            ctx_.AuthClient.Authenticate();

            ctx_.DebugClient.PrintOnServerConsole("ready to rumble");
        }
Esempio n. 2
0
 /// <summary>
 /// Creates a ClientContext for the specified connection
 /// </summary>
 public static ClientContext CreateClientEndpointContext(FrontEndConnection connection)
 {
     PacketTransmitter packetTransmitter = new PacketTransmitter(connection);
     ClientContext ctx = new ClientContext(connection, packetTransmitter);
     packetTransmitter.StartTransmitting();
     return ctx;
 }
Esempio n. 3
0
 public void Dispose()
 {
     try
     {
         ctx_.Connection.Close();
     }
     finally
     {
         ctx_ = null;
     }
 }