mirror of
https://github.com/sochix/TLSharp.git
synced 2026-04-07 23:45:09 +00:00
Layer-57
This commit is contained in:
parent
0752c60082
commit
23e647e81c
81 changed files with 2631 additions and 213 deletions
|
|
@ -7,18 +7,20 @@ using System.Threading.Tasks;
|
|||
using TeleSharp.TL;
|
||||
namespace TeleSharp.TL.Messages
|
||||
{
|
||||
[TLObject(-1494659324)]
|
||||
[TLObject(-2130010132)]
|
||||
public class TLRequestGetBotCallbackAnswer : TLMethod
|
||||
{
|
||||
public override int Constructor
|
||||
{
|
||||
get
|
||||
{
|
||||
return -1494659324;
|
||||
return -2130010132;
|
||||
}
|
||||
}
|
||||
|
||||
public TLAbsInputPeer peer {get;set;}
|
||||
public int flags {get;set;}
|
||||
public bool game {get;set;}
|
||||
public TLAbsInputPeer peer {get;set;}
|
||||
public int msg_id {get;set;}
|
||||
public byte[] data {get;set;}
|
||||
public Messages.TLBotCallbackAnswer Response{ get; set;}
|
||||
|
|
@ -26,22 +28,35 @@ namespace TeleSharp.TL.Messages
|
|||
|
||||
public void ComputeFlags()
|
||||
{
|
||||
|
||||
flags = 0;
|
||||
flags = game ? (flags | 2) : (flags & ~2);
|
||||
flags = data != null ? (flags | 1) : (flags & ~1);
|
||||
|
||||
}
|
||||
|
||||
public override void DeserializeBody(BinaryReader br)
|
||||
{
|
||||
peer = (TLAbsInputPeer)ObjectUtils.DeserializeObject(br);
|
||||
flags = br.ReadInt32();
|
||||
game = (flags & 2) != 0;
|
||||
peer = (TLAbsInputPeer)ObjectUtils.DeserializeObject(br);
|
||||
msg_id = br.ReadInt32();
|
||||
if ((flags & 1) != 0)
|
||||
data = BytesUtil.Deserialize(br);
|
||||
else
|
||||
data = null;
|
||||
|
||||
|
||||
}
|
||||
|
||||
public override void SerializeBody(BinaryWriter bw)
|
||||
{
|
||||
bw.Write(Constructor);
|
||||
ObjectUtils.SerializeObject(peer,bw);
|
||||
ComputeFlags();
|
||||
bw.Write(flags);
|
||||
|
||||
ObjectUtils.SerializeObject(peer,bw);
|
||||
bw.Write(msg_id);
|
||||
if ((flags & 1) != 0)
|
||||
BytesUtil.Serialize(data,bw);
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue