Documentation ¶
Index ¶
- Constants
- func TypesMap() map[uint32]string
- type BadMsgNotification
- type BadMsgNotificationBox
- type BadMsgNotificationClass
- type BadServerSalt
- type Client
- func (c *Client) DestroySession(ctx context.Context, sessionid int64) (DestroySessionResClass, error)
- func (c *Client) GetFutureSalts(ctx context.Context, num int) (*FutureSalts, error)
- func (c *Client) Ping(ctx context.Context, pingid int64) (*Pong, error)
- func (c *Client) PingDelayDisconnect(ctx context.Context, request *PingDelayDisconnectRequest) (*Pong, error)
- func (c *Client) RPCDropAnswer(ctx context.Context, reqmsgid int64) (RpcDropAnswerClass, error)
- func (c *Client) ReqDHParams(ctx context.Context, request *ReqDHParamsRequest) (ServerDHParamsClass, error)
- func (c *Client) ReqPq(ctx context.Context, nonce bin.Int128) (*ResPQ, error)
- func (c *Client) ReqPqMulti(ctx context.Context, nonce bin.Int128) (*ResPQ, error)
- func (c *Client) SetClientDHParams(ctx context.Context, request *SetClientDHParamsRequest) (SetClientDHParamsAnswerClass, error)
- type ClientDHInnerData
- type DestroySessionNone
- type DestroySessionOk
- type DestroySessionRequest
- type DestroySessionResBox
- type DestroySessionResClass
- type DhGenFail
- type DhGenOk
- type DhGenRetry
- type FutureSalt
- type FutureSalts
- type GetFutureSaltsRequest
- type GzipPacked
- type HTTPWaitRequest
- type Invoker
- type Message
- type MsgCopy
- type MsgDetailedInfo
- type MsgDetailedInfoBox
- type MsgDetailedInfoClass
- type MsgNewDetailedInfo
- type MsgResendReq
- type MsgsAck
- type MsgsAllInfo
- type MsgsStateInfo
- type MsgsStateReq
- type NewSessionCreated
- type PQInnerData
- type PingDelayDisconnectRequest
- type PingRequest
- type Pong
- type RPCAnswerDropped
- type RPCAnswerDroppedRunning
- type RPCAnswerUnknown
- type RPCDropAnswerRequest
- type RPCError
- type RPCResult
- type ReqDHParamsRequest
- type ReqPqMultiRequest
- type ReqPqRequest
- type ResPQ
- type RpcDropAnswerBox
- type RpcDropAnswerClass
- type ServerDHInnerData
- type ServerDHParamsBox
- type ServerDHParamsClass
- type ServerDHParamsFail
- type ServerDHParamsOk
- type SetClientDHParamsAnswerBox
- type SetClientDHParamsAnswerClass
- type SetClientDHParamsRequest
Constants ¶
const BadMsgNotificationTypeID = 0xa7eff811
BadMsgNotificationTypeID is TL type id of BadMsgNotification.
const BadServerSaltTypeID = 0xedab447b
BadServerSaltTypeID is TL type id of BadServerSalt.
const ClientDHInnerDataTypeID = 0x6643b654
ClientDHInnerDataTypeID is TL type id of ClientDHInnerData.
const DestroySessionNoneTypeID = 0x62d350c9
DestroySessionNoneTypeID is TL type id of DestroySessionNone.
const DestroySessionOkTypeID = 0xe22045fc
DestroySessionOkTypeID is TL type id of DestroySessionOk.
const DestroySessionRequestTypeID = 0xe7512126
DestroySessionRequestTypeID is TL type id of DestroySessionRequest.
const DhGenFailTypeID = 0xa69dae02
DhGenFailTypeID is TL type id of DhGenFail.
const DhGenOkTypeID = 0x3bcbf734
DhGenOkTypeID is TL type id of DhGenOk.
const DhGenRetryTypeID = 0x46dc1fb9
DhGenRetryTypeID is TL type id of DhGenRetry.
const FutureSaltTypeID = 0x949d9dc
FutureSaltTypeID is TL type id of FutureSalt.
const FutureSaltsTypeID = 0xae500895
FutureSaltsTypeID is TL type id of FutureSalts.
const GetFutureSaltsRequestTypeID = 0xb921bd04
GetFutureSaltsRequestTypeID is TL type id of GetFutureSaltsRequest.
const GzipPackedTypeID = 0x3072cfa1
GzipPackedTypeID is TL type id of GzipPacked.
const HTTPWaitRequestTypeID = 0x9299359f
HTTPWaitRequestTypeID is TL type id of HTTPWaitRequest.
const MessageTypeID = 0x5bb8e511
MessageTypeID is TL type id of Message.
const MsgCopyTypeID = 0xe06046b2
MsgCopyTypeID is TL type id of MsgCopy.
const MsgDetailedInfoTypeID = 0x276d3ec6
MsgDetailedInfoTypeID is TL type id of MsgDetailedInfo.
const MsgNewDetailedInfoTypeID = 0x809db6df
MsgNewDetailedInfoTypeID is TL type id of MsgNewDetailedInfo.
const MsgResendReqTypeID = 0x7d861a08
MsgResendReqTypeID is TL type id of MsgResendReq.
const MsgsAckTypeID = 0x62d6b459
MsgsAckTypeID is TL type id of MsgsAck.
const MsgsAllInfoTypeID = 0x8cc0d131
MsgsAllInfoTypeID is TL type id of MsgsAllInfo.
const MsgsStateInfoTypeID = 0x4deb57d
MsgsStateInfoTypeID is TL type id of MsgsStateInfo.
const MsgsStateReqTypeID = 0xda69fb52
MsgsStateReqTypeID is TL type id of MsgsStateReq.
const NewSessionCreatedTypeID = 0x9ec20908
NewSessionCreatedTypeID is TL type id of NewSessionCreated.
const PQInnerDataTypeID = 0x83c95aec
PQInnerDataTypeID is TL type id of PQInnerData.
const PingDelayDisconnectRequestTypeID = 0xf3427b8c
PingDelayDisconnectRequestTypeID is TL type id of PingDelayDisconnectRequest.
const PingRequestTypeID = 0x7abe77ec
PingRequestTypeID is TL type id of PingRequest.
const PongTypeID = 0x347773c5
PongTypeID is TL type id of Pong.
const RPCAnswerDroppedRunningTypeID = 0xcd78e586
RPCAnswerDroppedRunningTypeID is TL type id of RPCAnswerDroppedRunning.
const RPCAnswerDroppedTypeID = 0xa43ad8b7
RPCAnswerDroppedTypeID is TL type id of RPCAnswerDropped.
const RPCAnswerUnknownTypeID = 0x5e2ad36e
RPCAnswerUnknownTypeID is TL type id of RPCAnswerUnknown.
const RPCDropAnswerRequestTypeID = 0x58e4a740
RPCDropAnswerRequestTypeID is TL type id of RPCDropAnswerRequest.
const RPCErrorTypeID = 0x2144ca19
RPCErrorTypeID is TL type id of RPCError.
const RPCResultTypeID = 0xf35c6d01
RPCResultTypeID is TL type id of RPCResult.
const ReqDHParamsRequestTypeID = 0xd712e4be
ReqDHParamsRequestTypeID is TL type id of ReqDHParamsRequest.
const ReqPqMultiRequestTypeID = 0xbe7e8ef1
ReqPqMultiRequestTypeID is TL type id of ReqPqMultiRequest.
const ReqPqRequestTypeID = 0x60469778
ReqPqRequestTypeID is TL type id of ReqPqRequest.
const ResPQTypeID = 0x5162463
ResPQTypeID is TL type id of ResPQ.
const ServerDHInnerDataTypeID = 0xb5890dba
ServerDHInnerDataTypeID is TL type id of ServerDHInnerData.
const ServerDHParamsFailTypeID = 0x79cb045d
ServerDHParamsFailTypeID is TL type id of ServerDHParamsFail.
const ServerDHParamsOkTypeID = 0xd0e8075c
ServerDHParamsOkTypeID is TL type id of ServerDHParamsOk.
const SetClientDHParamsRequestTypeID = 0xf5045f1f
SetClientDHParamsRequestTypeID is TL type id of SetClientDHParamsRequest.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BadMsgNotification ¶
type BadMsgNotification struct { // BadMsgID field of BadMsgNotification. BadMsgID int64 // BadMsgSeqno field of BadMsgNotification. BadMsgSeqno int // ErrorCode field of BadMsgNotification. ErrorCode int }
BadMsgNotification represents TL type `bad_msg_notification#a7eff811`.
func (*BadMsgNotification) Decode ¶
func (b *BadMsgNotification) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BadMsgNotification) Encode ¶
func (b *BadMsgNotification) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BadMsgNotification) String ¶ added in v0.12.0
func (b *BadMsgNotification) String() string
String implements fmt.Stringer.
type BadMsgNotificationBox ¶ added in v0.12.0
type BadMsgNotificationBox struct {
BadMsgNotification BadMsgNotificationClass
}
BadMsgNotification boxes the BadMsgNotificationClass providing a helper.
type BadMsgNotificationClass ¶ added in v0.12.0
type BadMsgNotificationClass interface { bin.Encoder bin.Decoder fmt.Stringer // contains filtered or unexported methods }
BadMsgNotificationClass represents BadMsgNotification generic type.
Example:
g, err := DecodeBadMsgNotification(buf) if err != nil { panic(err) } switch v := g.(type) { case *BadMsgNotification: // bad_msg_notification#a7eff811 case *BadServerSalt: // bad_server_salt#edab447b default: panic(v) }
func DecodeBadMsgNotification ¶ added in v0.12.0
func DecodeBadMsgNotification(buf *bin.Buffer) (BadMsgNotificationClass, error)
DecodeBadMsgNotification implements binary de-serialization for BadMsgNotificationClass.
type BadServerSalt ¶
type BadServerSalt struct { // BadMsgID field of BadServerSalt. BadMsgID int64 // BadMsgSeqno field of BadServerSalt. BadMsgSeqno int // ErrorCode field of BadServerSalt. ErrorCode int // NewServerSalt field of BadServerSalt. NewServerSalt int64 }
BadServerSalt represents TL type `bad_server_salt#edab447b`.
func (*BadServerSalt) Decode ¶
func (b *BadServerSalt) Decode(buf *bin.Buffer) error
Decode implements bin.Decoder.
func (*BadServerSalt) Encode ¶
func (b *BadServerSalt) Encode(buf *bin.Buffer) error
Encode implements bin.Encoder.
func (*BadServerSalt) String ¶ added in v0.12.0
func (b *BadServerSalt) String() string
String implements fmt.Stringer.
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client implement methods for calling functions from TL schema via Invoker.
func (*Client) DestroySession ¶ added in v0.12.0
func (c *Client) DestroySession(ctx context.Context, sessionid int64) (DestroySessionResClass, error)
DestroySession invokes method destroy_session#e7512126 returning error if any.
func (*Client) GetFutureSalts ¶ added in v0.12.0
GetFutureSalts invokes method get_future_salts#b921bd04 returning error if any.
func (*Client) PingDelayDisconnect ¶ added in v0.12.0
func (c *Client) PingDelayDisconnect(ctx context.Context, request *PingDelayDisconnectRequest) (*Pong, error)
PingDelayDisconnect invokes method ping_delay_disconnect#f3427b8c returning error if any.
func (*Client) RPCDropAnswer ¶ added in v0.12.0
RPCDropAnswer invokes method rpc_drop_answer#58e4a740 returning error if any.
func (*Client) ReqDHParams ¶ added in v0.12.0
func (c *Client) ReqDHParams(ctx context.Context, request *ReqDHParamsRequest) (ServerDHParamsClass, error)
ReqDHParams invokes method req_DH_params#d712e4be returning error if any.
func (*Client) ReqPq ¶ added in v0.12.0
ReqPq invokes method req_pq#60469778 returning error if any.
func (*Client) ReqPqMulti ¶ added in v0.12.0
ReqPqMulti invokes method req_pq_multi#be7e8ef1 returning error if any.
func (*Client) SetClientDHParams ¶ added in v0.12.0
func (c *Client) SetClientDHParams(ctx context.Context, request *SetClientDHParamsRequest) (SetClientDHParamsAnswerClass, error)
SetClientDHParams invokes method set_client_DH_params#f5045f1f returning error if any.
type ClientDHInnerData ¶
type ClientDHInnerData struct { // Nonce field of ClientDHInnerData. Nonce bin.Int128 // ServerNonce field of ClientDHInnerData. ServerNonce bin.Int128 // RetryID field of ClientDHInnerData. RetryID int64 // GB field of ClientDHInnerData. GB []byte }
ClientDHInnerData represents TL type `client_DH_inner_data#6643b654`.
func (*ClientDHInnerData) Decode ¶
func (c *ClientDHInnerData) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ClientDHInnerData) Encode ¶
func (c *ClientDHInnerData) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ClientDHInnerData) String ¶ added in v0.12.0
func (c *ClientDHInnerData) String() string
String implements fmt.Stringer.
type DestroySessionNone ¶ added in v0.12.0
type DestroySessionNone struct { // SessionID field of DestroySessionNone. SessionID int64 }
DestroySessionNone represents TL type `destroy_session_none#62d350c9`.
func (*DestroySessionNone) Decode ¶ added in v0.12.0
func (d *DestroySessionNone) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DestroySessionNone) Encode ¶ added in v0.12.0
func (d *DestroySessionNone) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DestroySessionNone) String ¶ added in v0.12.0
func (d *DestroySessionNone) String() string
String implements fmt.Stringer.
type DestroySessionOk ¶ added in v0.12.0
type DestroySessionOk struct { // SessionID field of DestroySessionOk. SessionID int64 }
DestroySessionOk represents TL type `destroy_session_ok#e22045fc`.
func (*DestroySessionOk) Decode ¶ added in v0.12.0
func (d *DestroySessionOk) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DestroySessionOk) Encode ¶ added in v0.12.0
func (d *DestroySessionOk) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DestroySessionOk) String ¶ added in v0.12.0
func (d *DestroySessionOk) String() string
String implements fmt.Stringer.
type DestroySessionRequest ¶ added in v0.12.0
type DestroySessionRequest struct { // SessionID field of DestroySessionRequest. SessionID int64 }
DestroySessionRequest represents TL type `destroy_session#e7512126`.
func (*DestroySessionRequest) Decode ¶ added in v0.12.0
func (d *DestroySessionRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DestroySessionRequest) Encode ¶ added in v0.12.0
func (d *DestroySessionRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DestroySessionRequest) String ¶ added in v0.12.0
func (d *DestroySessionRequest) String() string
String implements fmt.Stringer.
type DestroySessionResBox ¶ added in v0.12.0
type DestroySessionResBox struct {
DestroySessionRes DestroySessionResClass
}
DestroySessionRes boxes the DestroySessionResClass providing a helper.
type DestroySessionResClass ¶ added in v0.12.0
type DestroySessionResClass interface { bin.Encoder bin.Decoder fmt.Stringer // contains filtered or unexported methods }
DestroySessionResClass represents DestroySessionRes generic type.
Example:
g, err := DecodeDestroySessionRes(buf) if err != nil { panic(err) } switch v := g.(type) { case *DestroySessionOk: // destroy_session_ok#e22045fc case *DestroySessionNone: // destroy_session_none#62d350c9 default: panic(v) }
func DecodeDestroySessionRes ¶ added in v0.12.0
func DecodeDestroySessionRes(buf *bin.Buffer) (DestroySessionResClass, error)
DecodeDestroySessionRes implements binary de-serialization for DestroySessionResClass.
type DhGenFail ¶
type DhGenFail struct { // Nonce field of DhGenFail. Nonce bin.Int128 // ServerNonce field of DhGenFail. ServerNonce bin.Int128 // NewNonceHash3 field of DhGenFail. NewNonceHash3 bin.Int128 }
DhGenFail represents TL type `dh_gen_fail#a69dae02`.
type DhGenOk ¶
type DhGenOk struct { // Nonce field of DhGenOk. Nonce bin.Int128 // ServerNonce field of DhGenOk. ServerNonce bin.Int128 // NewNonceHash1 field of DhGenOk. NewNonceHash1 bin.Int128 }
DhGenOk represents TL type `dh_gen_ok#3bcbf734`.
type DhGenRetry ¶
type DhGenRetry struct { // Nonce field of DhGenRetry. Nonce bin.Int128 // ServerNonce field of DhGenRetry. ServerNonce bin.Int128 // NewNonceHash2 field of DhGenRetry. NewNonceHash2 bin.Int128 }
DhGenRetry represents TL type `dh_gen_retry#46dc1fb9`.
func (*DhGenRetry) Decode ¶
func (d *DhGenRetry) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*DhGenRetry) Encode ¶
func (d *DhGenRetry) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*DhGenRetry) String ¶ added in v0.12.0
func (d *DhGenRetry) String() string
String implements fmt.Stringer.
type FutureSalt ¶ added in v0.12.0
type FutureSalt struct { // ValidSince field of FutureSalt. ValidSince int // ValidUntil field of FutureSalt. ValidUntil int // Salt field of FutureSalt. Salt int64 }
FutureSalt represents TL type `future_salt#949d9dc`.
func (*FutureSalt) Decode ¶ added in v0.12.0
func (f *FutureSalt) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*FutureSalt) Encode ¶ added in v0.12.0
func (f *FutureSalt) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*FutureSalt) String ¶ added in v0.12.0
func (f *FutureSalt) String() string
String implements fmt.Stringer.
type FutureSalts ¶ added in v0.12.0
type FutureSalts struct { // ReqMsgID field of FutureSalts. ReqMsgID int64 // Now field of FutureSalts. Now int // Salts field of FutureSalts. Salts []FutureSalt }
FutureSalts represents TL type `future_salts#ae500895`.
func (*FutureSalts) Decode ¶ added in v0.12.0
func (f *FutureSalts) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*FutureSalts) Encode ¶ added in v0.12.0
func (f *FutureSalts) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*FutureSalts) String ¶ added in v0.12.0
func (f *FutureSalts) String() string
String implements fmt.Stringer.
type GetFutureSaltsRequest ¶ added in v0.12.0
type GetFutureSaltsRequest struct { // Num field of GetFutureSaltsRequest. Num int }
GetFutureSaltsRequest represents TL type `get_future_salts#b921bd04`.
func (*GetFutureSaltsRequest) Decode ¶ added in v0.12.0
func (g *GetFutureSaltsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*GetFutureSaltsRequest) Encode ¶ added in v0.12.0
func (g *GetFutureSaltsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*GetFutureSaltsRequest) String ¶ added in v0.12.0
func (g *GetFutureSaltsRequest) String() string
String implements fmt.Stringer.
type GzipPacked ¶ added in v0.12.0
type GzipPacked struct { // PackedData field of GzipPacked. PackedData []byte }
GzipPacked represents TL type `gzip_packed#3072cfa1`.
func (*GzipPacked) Decode ¶ added in v0.12.0
func (g *GzipPacked) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*GzipPacked) Encode ¶ added in v0.12.0
func (g *GzipPacked) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*GzipPacked) String ¶ added in v0.12.0
func (g *GzipPacked) String() string
String implements fmt.Stringer.
type HTTPWaitRequest ¶ added in v0.12.0
type HTTPWaitRequest struct { // MaxDelay field of HTTPWaitRequest. MaxDelay int // WaitAfter field of HTTPWaitRequest. WaitAfter int // MaxWait field of HTTPWaitRequest. MaxWait int }
HTTPWaitRequest represents TL type `http_wait#9299359f`.
func (*HTTPWaitRequest) Decode ¶ added in v0.12.0
func (h *HTTPWaitRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*HTTPWaitRequest) Encode ¶ added in v0.12.0
func (h *HTTPWaitRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*HTTPWaitRequest) String ¶ added in v0.12.0
func (h *HTTPWaitRequest) String() string
String implements fmt.Stringer.
type Invoker ¶
type Invoker interface {
InvokeRaw(ctx context.Context, input bin.Encoder, output bin.Decoder) error
}
Invoker can invoke raw MTProto rpc calls.
type Message ¶ added in v0.12.0
type Message struct { // MsgID field of Message. MsgID int64 // Seqno field of Message. Seqno int // Bytes field of Message. Bytes int // Body field of Message. Body GzipPacked }
Message represents TL type `message#5bb8e511`.
type MsgCopy ¶ added in v0.12.0
type MsgCopy struct { // OrigMessage field of MsgCopy. OrigMessage Message }
MsgCopy represents TL type `msg_copy#e06046b2`.
type MsgDetailedInfo ¶ added in v0.12.0
type MsgDetailedInfo struct { // MsgID field of MsgDetailedInfo. MsgID int64 // AnswerMsgID field of MsgDetailedInfo. AnswerMsgID int64 // Bytes field of MsgDetailedInfo. Bytes int // Status field of MsgDetailedInfo. Status int }
MsgDetailedInfo represents TL type `msg_detailed_info#276d3ec6`.
func (*MsgDetailedInfo) Decode ¶ added in v0.12.0
func (m *MsgDetailedInfo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MsgDetailedInfo) Encode ¶ added in v0.12.0
func (m *MsgDetailedInfo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MsgDetailedInfo) String ¶ added in v0.12.0
func (m *MsgDetailedInfo) String() string
String implements fmt.Stringer.
type MsgDetailedInfoBox ¶ added in v0.12.0
type MsgDetailedInfoBox struct {
MsgDetailedInfo MsgDetailedInfoClass
}
MsgDetailedInfo boxes the MsgDetailedInfoClass providing a helper.
type MsgDetailedInfoClass ¶ added in v0.12.0
type MsgDetailedInfoClass interface { bin.Encoder bin.Decoder fmt.Stringer // contains filtered or unexported methods }
MsgDetailedInfoClass represents MsgDetailedInfo generic type.
Example:
g, err := DecodeMsgDetailedInfo(buf) if err != nil { panic(err) } switch v := g.(type) { case *MsgDetailedInfo: // msg_detailed_info#276d3ec6 case *MsgNewDetailedInfo: // msg_new_detailed_info#809db6df default: panic(v) }
func DecodeMsgDetailedInfo ¶ added in v0.12.0
func DecodeMsgDetailedInfo(buf *bin.Buffer) (MsgDetailedInfoClass, error)
DecodeMsgDetailedInfo implements binary de-serialization for MsgDetailedInfoClass.
type MsgNewDetailedInfo ¶ added in v0.12.0
type MsgNewDetailedInfo struct { // AnswerMsgID field of MsgNewDetailedInfo. AnswerMsgID int64 // Bytes field of MsgNewDetailedInfo. Bytes int // Status field of MsgNewDetailedInfo. Status int }
MsgNewDetailedInfo represents TL type `msg_new_detailed_info#809db6df`.
func (*MsgNewDetailedInfo) Decode ¶ added in v0.12.0
func (m *MsgNewDetailedInfo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MsgNewDetailedInfo) Encode ¶ added in v0.12.0
func (m *MsgNewDetailedInfo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MsgNewDetailedInfo) String ¶ added in v0.12.0
func (m *MsgNewDetailedInfo) String() string
String implements fmt.Stringer.
type MsgResendReq ¶ added in v0.12.0
type MsgResendReq struct { // MsgIds field of MsgResendReq. MsgIds []int64 }
MsgResendReq represents TL type `msg_resend_req#7d861a08`.
func (*MsgResendReq) Decode ¶ added in v0.12.0
func (m *MsgResendReq) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MsgResendReq) Encode ¶ added in v0.12.0
func (m *MsgResendReq) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MsgResendReq) String ¶ added in v0.12.0
func (m *MsgResendReq) String() string
String implements fmt.Stringer.
type MsgsAck ¶
type MsgsAck struct { // MsgIds field of MsgsAck. MsgIds []int64 }
MsgsAck represents TL type `msgs_ack#62d6b459`.
type MsgsAllInfo ¶ added in v0.12.0
type MsgsAllInfo struct { // MsgIds field of MsgsAllInfo. MsgIds []int64 // Info field of MsgsAllInfo. Info []byte }
MsgsAllInfo represents TL type `msgs_all_info#8cc0d131`.
func (*MsgsAllInfo) Decode ¶ added in v0.12.0
func (m *MsgsAllInfo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MsgsAllInfo) Encode ¶ added in v0.12.0
func (m *MsgsAllInfo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MsgsAllInfo) String ¶ added in v0.12.0
func (m *MsgsAllInfo) String() string
String implements fmt.Stringer.
type MsgsStateInfo ¶ added in v0.12.0
type MsgsStateInfo struct { // ReqMsgID field of MsgsStateInfo. ReqMsgID int64 // Info field of MsgsStateInfo. Info []byte }
MsgsStateInfo represents TL type `msgs_state_info#4deb57d`.
func (*MsgsStateInfo) Decode ¶ added in v0.12.0
func (m *MsgsStateInfo) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MsgsStateInfo) Encode ¶ added in v0.12.0
func (m *MsgsStateInfo) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MsgsStateInfo) String ¶ added in v0.12.0
func (m *MsgsStateInfo) String() string
String implements fmt.Stringer.
type MsgsStateReq ¶ added in v0.12.0
type MsgsStateReq struct { // MsgIds field of MsgsStateReq. MsgIds []int64 }
MsgsStateReq represents TL type `msgs_state_req#da69fb52`.
func (*MsgsStateReq) Decode ¶ added in v0.12.0
func (m *MsgsStateReq) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*MsgsStateReq) Encode ¶ added in v0.12.0
func (m *MsgsStateReq) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*MsgsStateReq) String ¶ added in v0.12.0
func (m *MsgsStateReq) String() string
String implements fmt.Stringer.
type NewSessionCreated ¶
type NewSessionCreated struct { // FirstMsgID field of NewSessionCreated. FirstMsgID int64 // UniqueID field of NewSessionCreated. UniqueID int64 // ServerSalt field of NewSessionCreated. ServerSalt int64 }
NewSessionCreated represents TL type `new_session_created#9ec20908`.
func (*NewSessionCreated) Decode ¶
func (n *NewSessionCreated) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*NewSessionCreated) Encode ¶
func (n *NewSessionCreated) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*NewSessionCreated) String ¶ added in v0.12.0
func (n *NewSessionCreated) String() string
String implements fmt.Stringer.
type PQInnerData ¶ added in v0.12.0
type PQInnerData struct { // Pq field of PQInnerData. Pq []byte // P field of PQInnerData. P []byte // Q field of PQInnerData. Q []byte // Nonce field of PQInnerData. Nonce bin.Int128 // ServerNonce field of PQInnerData. ServerNonce bin.Int128 // NewNonce field of PQInnerData. NewNonce bin.Int256 }
PQInnerData represents TL type `p_q_inner_data#83c95aec`.
func (*PQInnerData) Decode ¶ added in v0.12.0
func (p *PQInnerData) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PQInnerData) Encode ¶ added in v0.12.0
func (p *PQInnerData) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PQInnerData) String ¶ added in v0.12.0
func (p *PQInnerData) String() string
String implements fmt.Stringer.
type PingDelayDisconnectRequest ¶ added in v0.12.0
type PingDelayDisconnectRequest struct { // PingID field of PingDelayDisconnectRequest. PingID int64 // DisconnectDelay field of PingDelayDisconnectRequest. DisconnectDelay int }
PingDelayDisconnectRequest represents TL type `ping_delay_disconnect#f3427b8c`.
func (*PingDelayDisconnectRequest) Decode ¶ added in v0.12.0
func (p *PingDelayDisconnectRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PingDelayDisconnectRequest) Encode ¶ added in v0.12.0
func (p *PingDelayDisconnectRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PingDelayDisconnectRequest) String ¶ added in v0.12.0
func (p *PingDelayDisconnectRequest) String() string
String implements fmt.Stringer.
type PingRequest ¶ added in v0.12.0
type PingRequest struct { // PingID field of PingRequest. PingID int64 }
PingRequest represents TL type `ping#7abe77ec`.
func (*PingRequest) Decode ¶ added in v0.12.0
func (p *PingRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*PingRequest) Encode ¶ added in v0.12.0
func (p *PingRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*PingRequest) String ¶ added in v0.12.0
func (p *PingRequest) String() string
String implements fmt.Stringer.
type RPCAnswerDropped ¶ added in v0.12.0
type RPCAnswerDropped struct { // MsgID field of RPCAnswerDropped. MsgID int64 // SeqNo field of RPCAnswerDropped. SeqNo int // Bytes field of RPCAnswerDropped. Bytes int }
RPCAnswerDropped represents TL type `rpc_answer_dropped#a43ad8b7`.
func (*RPCAnswerDropped) Decode ¶ added in v0.12.0
func (r *RPCAnswerDropped) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*RPCAnswerDropped) Encode ¶ added in v0.12.0
func (r *RPCAnswerDropped) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*RPCAnswerDropped) String ¶ added in v0.12.0
func (r *RPCAnswerDropped) String() string
String implements fmt.Stringer.
type RPCAnswerDroppedRunning ¶ added in v0.12.0
type RPCAnswerDroppedRunning struct { }
RPCAnswerDroppedRunning represents TL type `rpc_answer_dropped_running#cd78e586`.
func (*RPCAnswerDroppedRunning) Decode ¶ added in v0.12.0
func (r *RPCAnswerDroppedRunning) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*RPCAnswerDroppedRunning) Encode ¶ added in v0.12.0
func (r *RPCAnswerDroppedRunning) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*RPCAnswerDroppedRunning) String ¶ added in v0.12.0
func (r *RPCAnswerDroppedRunning) String() string
String implements fmt.Stringer.
type RPCAnswerUnknown ¶ added in v0.12.0
type RPCAnswerUnknown struct { }
RPCAnswerUnknown represents TL type `rpc_answer_unknown#5e2ad36e`.
func (*RPCAnswerUnknown) Decode ¶ added in v0.12.0
func (r *RPCAnswerUnknown) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*RPCAnswerUnknown) Encode ¶ added in v0.12.0
func (r *RPCAnswerUnknown) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*RPCAnswerUnknown) String ¶ added in v0.12.0
func (r *RPCAnswerUnknown) String() string
String implements fmt.Stringer.
type RPCDropAnswerRequest ¶ added in v0.12.0
type RPCDropAnswerRequest struct { // ReqMsgID field of RPCDropAnswerRequest. ReqMsgID int64 }
RPCDropAnswerRequest represents TL type `rpc_drop_answer#58e4a740`.
func (*RPCDropAnswerRequest) Decode ¶ added in v0.12.0
func (r *RPCDropAnswerRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*RPCDropAnswerRequest) Encode ¶ added in v0.12.0
func (r *RPCDropAnswerRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*RPCDropAnswerRequest) String ¶ added in v0.12.0
func (r *RPCDropAnswerRequest) String() string
String implements fmt.Stringer.
type RPCError ¶
type RPCError struct { // ErrorCode field of RPCError. ErrorCode int // ErrorMessage field of RPCError. ErrorMessage string }
RPCError represents TL type `rpc_error#2144ca19`.
type RPCResult ¶ added in v0.12.0
type RPCResult struct { // ReqMsgID field of RPCResult. ReqMsgID int64 // Result field of RPCResult. Result GzipPacked }
RPCResult represents TL type `rpc_result#f35c6d01`.
type ReqDHParamsRequest ¶ added in v0.12.0
type ReqDHParamsRequest struct { // Nonce field of ReqDHParamsRequest. Nonce bin.Int128 // ServerNonce field of ReqDHParamsRequest. ServerNonce bin.Int128 // P field of ReqDHParamsRequest. P []byte // Q field of ReqDHParamsRequest. Q []byte // PublicKeyFingerprint field of ReqDHParamsRequest. PublicKeyFingerprint int64 // EncryptedData field of ReqDHParamsRequest. EncryptedData []byte }
ReqDHParamsRequest represents TL type `req_DH_params#d712e4be`.
func (*ReqDHParamsRequest) Decode ¶ added in v0.12.0
func (r *ReqDHParamsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ReqDHParamsRequest) Encode ¶ added in v0.12.0
func (r *ReqDHParamsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ReqDHParamsRequest) String ¶ added in v0.12.0
func (r *ReqDHParamsRequest) String() string
String implements fmt.Stringer.
type ReqPqMultiRequest ¶ added in v0.12.0
ReqPqMultiRequest represents TL type `req_pq_multi#be7e8ef1`.
func (*ReqPqMultiRequest) Decode ¶ added in v0.12.0
func (r *ReqPqMultiRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ReqPqMultiRequest) Encode ¶ added in v0.12.0
func (r *ReqPqMultiRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ReqPqMultiRequest) String ¶ added in v0.12.0
func (r *ReqPqMultiRequest) String() string
String implements fmt.Stringer.
type ReqPqRequest ¶ added in v0.12.0
ReqPqRequest represents TL type `req_pq#60469778`.
func (*ReqPqRequest) Decode ¶ added in v0.12.0
func (r *ReqPqRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ReqPqRequest) Encode ¶ added in v0.12.0
func (r *ReqPqRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ReqPqRequest) String ¶ added in v0.12.0
func (r *ReqPqRequest) String() string
String implements fmt.Stringer.
type ResPQ ¶
type ResPQ struct { // Nonce field of ResPQ. Nonce bin.Int128 // ServerNonce field of ResPQ. ServerNonce bin.Int128 // Pq field of ResPQ. Pq []byte // ServerPublicKeyFingerprints field of ResPQ. ServerPublicKeyFingerprints []int64 }
ResPQ represents TL type `resPQ#5162463`.
type RpcDropAnswerBox ¶ added in v0.12.0
type RpcDropAnswerBox struct {
RpcDropAnswer RpcDropAnswerClass
}
RpcDropAnswer boxes the RpcDropAnswerClass providing a helper.
type RpcDropAnswerClass ¶ added in v0.12.0
type RpcDropAnswerClass interface { bin.Encoder bin.Decoder fmt.Stringer // contains filtered or unexported methods }
RpcDropAnswerClass represents RpcDropAnswer generic type.
Example:
g, err := DecodeRpcDropAnswer(buf) if err != nil { panic(err) } switch v := g.(type) { case *RPCAnswerUnknown: // rpc_answer_unknown#5e2ad36e case *RPCAnswerDroppedRunning: // rpc_answer_dropped_running#cd78e586 case *RPCAnswerDropped: // rpc_answer_dropped#a43ad8b7 default: panic(v) }
func DecodeRpcDropAnswer ¶ added in v0.12.0
func DecodeRpcDropAnswer(buf *bin.Buffer) (RpcDropAnswerClass, error)
DecodeRpcDropAnswer implements binary de-serialization for RpcDropAnswerClass.
type ServerDHInnerData ¶
type ServerDHInnerData struct { // Nonce field of ServerDHInnerData. Nonce bin.Int128 // ServerNonce field of ServerDHInnerData. ServerNonce bin.Int128 // G field of ServerDHInnerData. G int // DhPrime field of ServerDHInnerData. DhPrime []byte // GA field of ServerDHInnerData. GA []byte // ServerTime field of ServerDHInnerData. ServerTime int }
ServerDHInnerData represents TL type `server_DH_inner_data#b5890dba`.
func (*ServerDHInnerData) Decode ¶
func (s *ServerDHInnerData) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ServerDHInnerData) Encode ¶
func (s *ServerDHInnerData) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ServerDHInnerData) String ¶ added in v0.12.0
func (s *ServerDHInnerData) String() string
String implements fmt.Stringer.
type ServerDHParamsBox ¶
type ServerDHParamsBox struct {
Server_DH_Params ServerDHParamsClass
}
ServerDHParams boxes the ServerDHParamsClass providing a helper.
type ServerDHParamsClass ¶
type ServerDHParamsClass interface { bin.Encoder bin.Decoder fmt.Stringer // contains filtered or unexported methods }
ServerDHParamsClass represents Server_DH_Params generic type.
Example:
g, err := DecodeServerDHParams(buf) if err != nil { panic(err) } switch v := g.(type) { case *ServerDHParamsFail: // server_DH_params_fail#79cb045d case *ServerDHParamsOk: // server_DH_params_ok#d0e8075c default: panic(v) }
func DecodeServerDHParams ¶
func DecodeServerDHParams(buf *bin.Buffer) (ServerDHParamsClass, error)
DecodeServerDHParams implements binary de-serialization for ServerDHParamsClass.
type ServerDHParamsFail ¶
type ServerDHParamsFail struct { // Nonce field of ServerDHParamsFail. Nonce bin.Int128 // ServerNonce field of ServerDHParamsFail. ServerNonce bin.Int128 // NewNonceHash field of ServerDHParamsFail. NewNonceHash bin.Int128 }
ServerDHParamsFail represents TL type `server_DH_params_fail#79cb045d`.
func (*ServerDHParamsFail) Decode ¶
func (s *ServerDHParamsFail) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ServerDHParamsFail) Encode ¶
func (s *ServerDHParamsFail) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ServerDHParamsFail) String ¶ added in v0.12.0
func (s *ServerDHParamsFail) String() string
String implements fmt.Stringer.
type ServerDHParamsOk ¶
type ServerDHParamsOk struct { // Nonce field of ServerDHParamsOk. Nonce bin.Int128 // ServerNonce field of ServerDHParamsOk. ServerNonce bin.Int128 // EncryptedAnswer field of ServerDHParamsOk. EncryptedAnswer []byte }
ServerDHParamsOk represents TL type `server_DH_params_ok#d0e8075c`.
func (*ServerDHParamsOk) Decode ¶
func (s *ServerDHParamsOk) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*ServerDHParamsOk) Encode ¶
func (s *ServerDHParamsOk) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*ServerDHParamsOk) String ¶ added in v0.12.0
func (s *ServerDHParamsOk) String() string
String implements fmt.Stringer.
type SetClientDHParamsAnswerBox ¶
type SetClientDHParamsAnswerBox struct {
Set_client_DH_params_answer SetClientDHParamsAnswerClass
}
SetClientDHParamsAnswer boxes the SetClientDHParamsAnswerClass providing a helper.
type SetClientDHParamsAnswerClass ¶
type SetClientDHParamsAnswerClass interface { bin.Encoder bin.Decoder fmt.Stringer // contains filtered or unexported methods }
SetClientDHParamsAnswerClass represents Set_client_DH_params_answer generic type.
Example:
g, err := DecodeSetClientDHParamsAnswer(buf) if err != nil { panic(err) } switch v := g.(type) { case *DhGenOk: // dh_gen_ok#3bcbf734 case *DhGenRetry: // dh_gen_retry#46dc1fb9 case *DhGenFail: // dh_gen_fail#a69dae02 default: panic(v) }
func DecodeSetClientDHParamsAnswer ¶
func DecodeSetClientDHParamsAnswer(buf *bin.Buffer) (SetClientDHParamsAnswerClass, error)
DecodeSetClientDHParamsAnswer implements binary de-serialization for SetClientDHParamsAnswerClass.
type SetClientDHParamsRequest ¶ added in v0.12.0
type SetClientDHParamsRequest struct { // Nonce field of SetClientDHParamsRequest. Nonce bin.Int128 // ServerNonce field of SetClientDHParamsRequest. ServerNonce bin.Int128 // EncryptedData field of SetClientDHParamsRequest. EncryptedData []byte }
SetClientDHParamsRequest represents TL type `set_client_DH_params#f5045f1f`.
func (*SetClientDHParamsRequest) Decode ¶ added in v0.12.0
func (s *SetClientDHParamsRequest) Decode(b *bin.Buffer) error
Decode implements bin.Decoder.
func (*SetClientDHParamsRequest) Encode ¶ added in v0.12.0
func (s *SetClientDHParamsRequest) Encode(b *bin.Buffer) error
Encode implements bin.Encoder.
func (*SetClientDHParamsRequest) String ¶ added in v0.12.0
func (s *SetClientDHParamsRequest) String() string
String implements fmt.Stringer.
Source Files ¶
- tl_bad_msg_notification_gen.go
- tl_client_d_h_inner_data_gen.go
- tl_client_gen.go
- tl_destroy_session_gen.go
- tl_destroy_session_res_gen.go
- tl_future_salt_gen.go
- tl_future_salts_gen.go
- tl_get_future_salts_gen.go
- tl_gzip_packed_gen.go
- tl_http_wait_gen.go
- tl_message_gen.go
- tl_msg_copy_gen.go
- tl_msg_detailed_info_gen.go
- tl_msg_resend_req_gen.go
- tl_msgs_ack_gen.go
- tl_msgs_all_info_gen.go
- tl_msgs_state_info_gen.go
- tl_msgs_state_req_gen.go
- tl_new_session_created_gen.go
- tl_p_q_inner_data_gen.go
- tl_ping_delay_disconnect_gen.go
- tl_ping_gen.go
- tl_pong_gen.go
- tl_registry_gen.go
- tl_req_d_h_params_gen.go
- tl_req_pq_gen.go
- tl_req_pq_multi_gen.go
- tl_res_p_q_gen.go
- tl_rpc_drop_answer_const_gen.go
- tl_rpc_drop_answer_gen.go
- tl_rpc_error_gen.go
- tl_rpc_result_gen.go
- tl_server_d_h_inner_data_gen.go
- tl_server_d_h_params_gen.go
- tl_set_client_d_h_params_answer_gen.go
- tl_set_client_d_h_params_gen.go