Beispiel #1
0
 public byte[] Process(byte[] buffer)
 {
     buffer = WcfByteHandler.DecryptData(buffer);
     buffer = WcfByteHandler.DecompressData(buffer);
     buffer = DoProcess(buffer);
     buffer = WcfByteHandler.CompressData(buffer);
     buffer = WcfByteHandler.EncryptData(buffer);
     return(buffer);
 }
Beispiel #2
0
 private static byte[] Process(byte[] buffer, Func <byte[], byte[]> action)
 {
     buffer = WcfByteHandler.CompressData(buffer);
     buffer = WcfByteHandler.EncryptData(buffer);
     buffer = action(buffer);
     if (buffer != null)
     {
         buffer = WcfByteHandler.DecryptData(buffer);
         buffer = WcfByteHandler.DecompressData(buffer);
     }
     return(buffer);
 }