| Total Complexity | 10 |
| Total Lines | 116 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 15 | class InlineQuery |
||
| 16 | { |
||
| 17 | |||
| 18 | /** |
||
| 19 | * Unique identifier for this query |
||
| 20 | * |
||
| 21 | * @var string |
||
| 22 | */ |
||
| 23 | private $id; |
||
| 24 | |||
| 25 | /** |
||
| 26 | * Sender |
||
| 27 | * |
||
| 28 | * @var User |
||
| 29 | */ |
||
| 30 | private $from; |
||
| 31 | |||
| 32 | /** |
||
| 33 | * Optional. Sender location, only for bots that request user location |
||
| 34 | * |
||
| 35 | * @var Location|null |
||
| 36 | */ |
||
| 37 | private $location; |
||
| 38 | |||
| 39 | /** |
||
| 40 | * Text of the query (up to 256 characters) |
||
| 41 | * |
||
| 42 | * @var string |
||
| 43 | */ |
||
| 44 | private $query; |
||
| 45 | |||
| 46 | /** |
||
| 47 | * Offset of the results to be returned, can be controlled by the bot |
||
| 48 | * |
||
| 49 | * @var string |
||
| 50 | */ |
||
| 51 | private $offset; |
||
| 52 | |||
| 53 | /** |
||
| 54 | * @return string |
||
| 55 | */ |
||
| 56 | public function getId(): string |
||
| 57 | { |
||
| 58 | return $this->id; |
||
| 59 | } |
||
| 60 | |||
| 61 | /** |
||
| 62 | * @param string $id |
||
| 63 | */ |
||
| 64 | public function setId(string $id): void |
||
| 65 | { |
||
| 66 | $this->id = $id; |
||
| 67 | } |
||
| 68 | |||
| 69 | /** |
||
| 70 | * @return User |
||
| 71 | */ |
||
| 72 | public function getFrom(): User |
||
| 73 | { |
||
| 74 | return $this->from; |
||
| 75 | } |
||
| 76 | |||
| 77 | /** |
||
| 78 | * @param User $from |
||
| 79 | */ |
||
| 80 | public function setFrom(User $from): void |
||
| 81 | { |
||
| 82 | $this->from = $from; |
||
| 83 | } |
||
| 84 | |||
| 85 | /** |
||
| 86 | * @return Location|null |
||
| 87 | */ |
||
| 88 | public function getLocation(): ?Location |
||
| 89 | { |
||
| 90 | return $this->location; |
||
| 91 | } |
||
| 92 | |||
| 93 | /** |
||
| 94 | * @param Location|null $location |
||
| 95 | */ |
||
| 96 | public function setLocation(?Location $location): void |
||
| 97 | { |
||
| 98 | $this->location = $location; |
||
| 99 | } |
||
| 100 | |||
| 101 | /** |
||
| 102 | * @return string |
||
| 103 | */ |
||
| 104 | public function getQuery(): string |
||
| 105 | { |
||
| 106 | return $this->query; |
||
| 107 | } |
||
| 108 | |||
| 109 | /** |
||
| 110 | * @param string $query |
||
| 111 | */ |
||
| 112 | public function setQuery(string $query): void |
||
| 115 | } |
||
| 116 | |||
| 117 | /** |
||
| 118 | * @return string |
||
| 119 | */ |
||
| 120 | public function getOffset(): string |
||
| 123 | } |
||
| 124 | |||
| 125 | /** |
||
| 126 | * @param string $offset |
||
| 127 | */ |
||
| 128 | public function setOffset(string $offset): void |
||
| 131 | } |
||
| 132 | |||
| 133 | } |