Exemplo n.º 1
0
 public StreamImpl GetStream(System.Type returnType, ulong id)
 {
     CheckDisposed();
     lock (updateLock) {
         if (!streams.ContainsKey(id))
         {
             streams [id] = new StreamImpl(connection, id, returnType, updateLock);
         }
         return(streams [id]);
     }
 }
Exemplo n.º 2
0
        public StreamImpl AddStream(System.Type returnType, ProcedureCall call)
        {
            CheckDisposed();
            var id = connection.KRPC().AddStream(call, false).Id;

            lock (updateLock) {
                if (!streams.ContainsKey(id))
                {
                    streams [id] = new StreamImpl(connection, id, returnType, updateLock);
                }
                return(streams [id]);
            }
        }
Exemplo n.º 3
0
 internal Stream(Connection connection, ProcedureCall call)
 {
     stream = connection.StreamManager.AddStream(typeof(TReturnType), call);
 }
Exemplo n.º 4
0
 internal Stream(Connection connection, ulong id)
 {
     stream = connection.StreamManager.GetStream(typeof(TReturnType), id);
 }