コード例 #1
0
 private PacketLogFile(Func<Stream> openStream)
 {
     _openStream = openStream;
     using (var stream = _openStream())
     {
         var reader = new PacketLogReader(stream);
         Header = reader.Header;
     }
 }
コード例 #2
0
ファイル: PacketLogFile.cs プロジェクト: tuita520/Tera
 private PacketLogFile(Func <Stream> openStream)
 {
     _openStream = openStream;
     using (var stream = _openStream())
     {
         var reader = new PacketLogReader(stream);
         Header = reader.Header;
     }
 }
コード例 #3
0
 private static IEnumerable<Message> ReadMessages(Func<Stream> openStream)
 {
     using (var stream = openStream())
     {
         var reader = new PacketLogReader(stream);
         Message message;
         while ((message = reader.ReadMessage()) != null)
         {
             yield return message;
         }
     }
 }
コード例 #4
0
 private static IEnumerable <Message> ReadMessages(Func <Stream> openStream)
 {
     using (var stream = openStream())
     {
         var     reader = new PacketLogReader(stream);
         Message message;
         while ((message = reader.ReadMessage()) != null)
         {
             yield return(message);
         }
     }
 }