1
0
mirror of https://github.com/danog/MadelineProto.git synced 2024-11-26 21:14:43 +01:00

Added missing methods

This commit is contained in:
Daniil Gentili 2017-06-03 20:19:05 +02:00
parent c94f98509e
commit 6459cf72fd
5 changed files with 129 additions and 0 deletions

View File

@ -360,6 +360,15 @@ Works exactly like the [socket_send](http://php.net/manual/en/function.socket-se
Works exactly like the [socket_close](http://php.net/manual/en/function.socket-close.php) function.
```public function getPeerName(bool $port = true);```
Works like [socket_getpeername](http://php.net/manual/en/function.socket-getpeername.php): the difference is that it returns an array with the `host` and the `port`.
```public function getSockName(bool $port = true);```
Works like [socket_getsockname](http://php.net/manual/en/function.socket-getsockname.php): the difference is that it returns an array with the `host` and the `port`.
### Uploading and downloading files

View File

@ -0,0 +1,37 @@
---
title: documentAttributeAudio
description: documentAttributeAudio attributes, type and example
---
## Constructor: documentAttributeAudio\_46
[Back to constructors index](index.md)
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|duration|[int](../types/int.md) | Yes|
|title|[string](../types/string.md) | Yes|
|performer|[string](../types/string.md) | Yes|
### Type: [DocumentAttribute](../types/DocumentAttribute.md)
### Example:
```
$documentAttributeAudio_46 = ['_' => 'documentAttributeAudio', 'duration' => int, 'title' => string, 'performer' => string, ];
```
Or, if you're into Lua:
```
documentAttributeAudio_46={_='documentAttributeAudio', duration=int, title=string, performer=string, }
```

View File

@ -0,0 +1,36 @@
---
title: documentAttributeSticker
description: documentAttributeSticker attributes, type and example
---
## Constructor: documentAttributeSticker\_55
[Back to constructors index](index.md)
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|alt|[string](../types/string.md) | Yes|
|stickerset|[InputStickerSet](../types/InputStickerSet.md) | Yes|
### Type: [DocumentAttribute](../types/DocumentAttribute.md)
### Example:
```
$documentAttributeSticker_55 = ['_' => 'documentAttributeSticker', 'alt' => string, 'stickerset' => InputStickerSet, ];
```
Or, if you're into Lua:
```
documentAttributeSticker_55={_='documentAttributeSticker', alt=string, stickerset=InputStickerSet, }
```

View File

@ -0,0 +1,38 @@
---
title: documentAttributeVideo
description: documentAttributeVideo attributes, type and example
---
## Constructor: documentAttributeVideo\_66
[Back to constructors index](index.md)
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|round\_message|[Bool](../types/Bool.md) | Optional|
|duration|[int](../types/int.md) | Yes|
|w|[int](../types/int.md) | Yes|
|h|[int](../types/int.md) | Yes|
### Type: [DocumentAttribute](../types/DocumentAttribute.md)
### Example:
```
$documentAttributeVideo_66 = ['_' => 'documentAttributeVideo', 'round_message' => Bool, 'duration' => int, 'w' => int, 'h' => int, ];
```
Or, if you're into Lua:
```
documentAttributeVideo_66={_='documentAttributeVideo', round_message=Bool, duration=int, w=int, h=int, }
```

View File

@ -364,6 +364,15 @@ Works exactly like the [socket_send](http://php.net/manual/en/function.socket-se
Works exactly like the [socket_close](http://php.net/manual/en/function.socket-close.php) function.
```public function getPeerName(bool $port = true);```
Works like [socket_getpeername](http://php.net/manual/en/function.socket-getpeername.php): the difference is that it returns an array with the `host` and the `port`.
```public function getSockName(bool $port = true);```
Works like [socket_getsockname](http://php.net/manual/en/function.socket-getsockname.php): the difference is that it returns an array with the `host` and the `port`.
### Uploading and downloading files