Documentation ¶ Index ¶ type Dialer type Telegram func New(dialer Dialer, ipPreference string, useTestDCs bool) (*Telegram, error) func (t Telegram) Dial(ctx context.Context, dc int) (net.Conn, error) func (t Telegram) GetFallbackDC() int func (t Telegram) IsKnownDC(dc int) bool Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ This section is empty. Types ¶ type Dialer ¶ type Dialer interface { DialContext(ctx context.Context, network, address string) (net.Conn, error) } type Telegram ¶ type Telegram struct { // contains filtered or unexported fields } func New ¶ func New(dialer Dialer, ipPreference string, useTestDCs bool) (*Telegram, error) func (Telegram) Dial ¶ func (t Telegram) Dial(ctx context.Context, dc int) (net.Conn, error) func (Telegram) GetFallbackDC ¶ added in v2.1.2 func (t Telegram) GetFallbackDC() int func (Telegram) IsKnownDC ¶ added in v2.1.2 func (t Telegram) IsKnownDC(dc int) bool Source Files ¶ View all Source files address_pool.go init.go telegram.go Click to show internal directories. Click to hide internal directories.