Esempio n. 1
0
 public override byte[] ToBytes()
 {
     return(TLUtils.Combine(
                TLUtils.SignatureToBytes(Signature),
                Thumb.ToBytes(),
                ThumbW.ToBytes(),
                ThumbH.ToBytes(),
                FileName.ToBytes(),
                MimeType.ToBytes(),
                Size.ToBytes(),
                Key.ToBytes(),
                IV.ToBytes()));
 }
Esempio n. 2
0
 public override void ToStream(Stream output)
 {
     output.Write(TLUtils.SignatureToBytes(Signature));
     output.Write(Thumb.ToBytes());
     output.Write(ThumbW.ToBytes());
     output.Write(ThumbH.ToBytes());
     output.Write(FileName.ToBytes());
     output.Write(MimeType.ToBytes());
     output.Write(Size.ToBytes());
     output.Write(Key.ToBytes());
     output.Write(IV.ToBytes());
     File.NullableToStream(output);
 }
Esempio n. 3
0
 public override byte[] ToBytes()
 {
     return(TLUtils.Combine(
                TLUtils.SignatureToBytes(Signature),
                Thumb.ToBytes(),
                ThumbW.ToBytes(),
                ThumbH.ToBytes(),
                Duration.ToBytes(),
                W.ToBytes(),
                H.ToBytes(),
                Size.ToBytes(),
                Key.ToBytes(),
                IV.ToBytes()));
 }