Represents the connection to the server.
Inheritance: IConnection, IDisposable
Exemplo n.º 1
0
        internal Parser(Connection conn)
        {
            argBufStream = new MemoryStream(argBufBase);
            msgBufStream = new MemoryStream(msgBufBase);

            this.conn = conn;
        }
Exemplo n.º 2
0
 internal AsyncSubscription(Connection conn, string subject, string queue)
     : base(conn, subject, queue)
 {
     mch = conn.getMessageChannel();
     if ((ownsChannel = (mch == null)))
     {
         mch = new Channel<Msg>();
     }
 }
Exemplo n.º 3
0
 /// <summary>
 /// CreateConnection to the NATs server using the provided options.
 /// </summary>
 /// <param name="opts">NATs client options</param>
 /// <returns>A new connection to the NATS server</returns>
 public IConnection CreateConnection(Options opts)
 {
     Connection nc = new Connection(opts);
     nc.connect();
     return nc;
 }
Exemplo n.º 4
0
 internal SyncSubscription(Connection conn, string subject, string queue)
     : base(conn, subject, queue)
 {
     mch = new Channel<Msg>();
 }
Exemplo n.º 5
0
 internal ErrEventArgs(Connection c, Subscription s, String err)
 {
     this.c = c;
     this.s = s;
     this.err = err;
 }
Exemplo n.º 6
0
 internal ConnEventArgs(Connection c)
 {
     this.c = c;
 }
Exemplo n.º 7
0
 internal SubChannelPool(Connection c, int numTasks)
 {
     maxTasks = numTasks;
     connection = c;
 }
Exemplo n.º 8
0
                internal SubChannelProcessor(Connection c)
                {
                    connection = c;

                    channelTask = new Task(() => {
                        connection.deliverMsgs(channel);
                    }, TaskCreationOptions.LongRunning);

                    channelTask.Start();
                }
Exemplo n.º 9
0
 internal SyncSubscription(Connection conn, string subject, string queue)
     : base(conn, subject, queue) { }
Exemplo n.º 10
0
 internal Subscription(Connection conn, string subject, string queue)
 {
     this.conn = conn;
     this.subject = subject;
     this.queue = queue;
 }
Exemplo n.º 11
0
 internal AsyncSubscription(Connection conn, string subject, string queue,
     EventHandler<MsgHandlerEventArgs> messageEventHandler) : base(conn, subject, queue)
 {
     MessageHandler = messageEventHandler;
     Start();
 }