Пример #1
0
 private void SendBye(Context context, CallbackPacket packet)
 {
     if (context == null)
     {
         return;
     }
     try
     {
         context.BadSession();
     }
     catch (Exception)
     {
         // We can do nothing here.
     }
 }
Пример #2
0
 private void Send(Context context, CallbackPacket packet)
 {
     if (context == null)
     {
         return;
     }
     try
     {
         if (packet == null)
         {
             context.Send();
         }
         else
         {
             context.SetCookie("CBID", packet.Id.ToString(CultureInfo.InvariantCulture));
             context.Send(packet.Data);
         }
     }
     catch (HttpRequestException)
     {
         // We can do nothing here.
     }
     catch (ObjectDisposedException)
     {
         // We can do nothing here.
     }
     catch (Exception ex)
     {
         try
         {
             context.Send(ex);
         }
         catch (Exception)
         {
             // We can do nothing here.
         }
     }
 }
Пример #3
0
 public ResponseInfo(Context context, CallbackPacket packet)
 {
     this.Context = context;
     this.Packet  = packet;
 }