mirror of
https://github.com/sochix/TLSharp.git
synced 2026-04-07 07:25:24 +00:00
Generator Must Respect MS .NET API guidelines
This commit is contained in:
parent
3ba3ea53fd
commit
d769dd3c2f
646 changed files with 7213 additions and 7166 deletions
|
|
@ -18,29 +18,29 @@ namespace TeleSharp.TL
|
|||
}
|
||||
}
|
||||
|
||||
public int flags { get; set; }
|
||||
public bool has_stickers { get; set; }
|
||||
public long id { get; set; }
|
||||
public long access_hash { get; set; }
|
||||
public int date { get; set; }
|
||||
public TLVector<TLAbsPhotoSize> sizes { get; set; }
|
||||
public int Flags { get; set; }
|
||||
public bool HasStickers { get; set; }
|
||||
public long Id { get; set; }
|
||||
public long AccessHash { get; set; }
|
||||
public int Date { get; set; }
|
||||
public TLVector<TLAbsPhotoSize> Sizes { get; set; }
|
||||
|
||||
|
||||
public void ComputeFlags()
|
||||
{
|
||||
flags = 0;
|
||||
flags = has_stickers ? (flags | 1) : (flags & ~1);
|
||||
Flags = 0;
|
||||
Flags = HasStickers ? (Flags | 1) : (Flags & ~1);
|
||||
|
||||
}
|
||||
|
||||
public override void DeserializeBody(BinaryReader br)
|
||||
{
|
||||
flags = br.ReadInt32();
|
||||
has_stickers = (flags & 1) != 0;
|
||||
id = br.ReadInt64();
|
||||
access_hash = br.ReadInt64();
|
||||
date = br.ReadInt32();
|
||||
sizes = (TLVector<TLAbsPhotoSize>)ObjectUtils.DeserializeVector<TLAbsPhotoSize>(br);
|
||||
Flags = br.ReadInt32();
|
||||
HasStickers = (Flags & 1) != 0;
|
||||
Id = br.ReadInt64();
|
||||
AccessHash = br.ReadInt64();
|
||||
Date = br.ReadInt32();
|
||||
Sizes = (TLVector<TLAbsPhotoSize>)ObjectUtils.DeserializeVector<TLAbsPhotoSize>(br);
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -48,12 +48,12 @@ namespace TeleSharp.TL
|
|||
{
|
||||
bw.Write(Constructor);
|
||||
ComputeFlags();
|
||||
bw.Write(flags);
|
||||
bw.Write(Flags);
|
||||
|
||||
bw.Write(id);
|
||||
bw.Write(access_hash);
|
||||
bw.Write(date);
|
||||
ObjectUtils.SerializeObject(sizes, bw);
|
||||
bw.Write(Id);
|
||||
bw.Write(AccessHash);
|
||||
bw.Write(Date);
|
||||
ObjectUtils.SerializeObject(Sizes, bw);
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue