1
0
mirror of https://github.com/InsanusMokrassar/TelegramBotAPI.git synced 2025-11-16 12:00:18 +00:00

Compare commits

..

588 Commits

Author SHA1 Message Date
da5e46e59f remove several PreviewFeature 2020-11-21 15:19:31 +06:00
a3f315a73a update micro_utils 2020-11-21 15:15:07 +06:00
43583a885a update versions 2020-11-21 14:40:34 +06:00
ec02257ecd start 0.30.8 2020-11-21 14:32:32 +06:00
29ee4a9396 update publishing urls 2020-11-18 17:51:53 +06:00
2717cb4fc6 exprimentally update publishing scripts 2020-11-18 17:18:51 +06:00
1ce2526401 Merge pull request #217 from InsanusMokrassar/0.30.7
0.30.7
2020-11-17 16:32:19 +06:00
74c480b07e one new telegramBot function 2020-11-17 16:18:58 +06:00
657e9aa770 add KtorRequestsExecutorBuilder 2020-11-17 16:06:25 +06:00
0d19952ba7 PowLimiter and CommonLimiter rewriting (#210) 2020-11-17 15:48:58 +06:00
f8cccc3e17 update gradle 2020-11-17 14:41:53 +06:00
bc1b7c3f25 fix ending of host url in TelegramAPIUrlsKeeper 2020-11-17 13:18:11 +06:00
ec74111a9d update micro_utils version 2020-11-17 12:51:55 +06:00
2dadeb7eb7 start 0.30.7 2020-11-17 12:50:54 +06:00
24bd65501b Update README.md 2020-11-16 21:59:25 +06:00
574ca803fa Update README.md 2020-11-16 21:56:31 +06:00
947e3bf34e add fast start 2020-11-16 21:55:22 +06:00
488158d8fb Merge pull request #214 from InsanusMokrassar/0.30.6
0.30.6
2020-11-16 16:29:46 +06:00
41bf3c7f0b filling of changelog and renaming of new function makeLink -> makeUsernameLink 2020-11-16 16:25:10 +06:00
c2032d21cd TextSource properties has been renamed 2020-11-16 13:32:20 +06:00
6650dd9cfe reworking of links extension 2020-11-16 13:22:08 +06:00
af1d6d6f1a start 0.30.6 2020-11-15 23:05:19 +06:00
a5861d659d Merge pull request #212 from InsanusMokrassar/0.30.5
0.30.5
2020-11-14 19:44:26 +06:00
b36f80a6d3 update micro_utils 2020-11-14 19:41:26 +06:00
7c4f034a6c fixes in imports 2020-11-14 14:41:16 +06:00
3b08bc6dd2 serialization of ChatMember and changing of id type in User 2020-11-14 14:38:54 +06:00
ed87c0ad95 start 0.30.5 2020-11-14 11:19:53 +06:00
c8c0fc2ce8 Merge pull request #211 from InsanusMokrassar/0.30.4
0.30.4
2020-11-12 23:05:49 +06:00
1f40ce1a81 add a lot of shortcuts for events 2020-11-12 22:35:27 +06:00
b0219389fc add several functions and changelog notes 2020-11-12 22:23:10 +06:00
f6ec82b449 deprecate old asChatEventsFlow 2020-11-12 22:04:46 +06:00
71dac70635 deprecations in old functions 2020-11-12 22:02:06 +06:00
98f68a9e1e filling of changelog 2020-11-12 21:54:14 +06:00
e7199e7451 fix use user in group messages 2020-11-12 21:46:33 +06:00
33b50c6c68 events filters 2020-11-12 21:17:11 +06:00
e4ce6f8fc7 fixes in events 2020-11-12 17:44:33 +06:00
8764f18ca8 TextContent now implements TextedInput 2020-11-12 16:57:32 +06:00
b2fa7fee9d rename MultilevelTextSource#textSources 2020-11-12 16:37:17 +06:00
0121e3a104 update micro_utils 2020-11-12 16:33:48 +06:00
f6e5664632 start 0.30.4 2020-11-12 16:31:02 +06:00
c5b7c4e1f5 Merge pull request #209 from InsanusMokrassar/0.30.3
0.30.3
2020-11-11 11:25:25 +06:00
53800d49bf small rework in ExceptionsOnlyLimiter 2020-11-11 11:23:24 +06:00
d83e3eb10a add handling of 429 status 2020-11-11 11:15:19 +06:00
66b4d06064 limiter rework 2020-11-11 10:23:20 +06:00
4fab01b2a2 update micro_utils 2020-11-11 10:15:06 +06:00
b81086c4bb start 0.30.3 2020-11-11 10:14:10 +06:00
d776071cac Update build.gradle 2020-11-11 01:32:25 +06:00
5f33d05deb Update extensions utils dependencies 2020-11-11 01:31:28 +06:00
912cc7217c Update extensions api dependencies 2020-11-11 01:30:31 +06:00
96e00f6e31 Merge pull request #207 from InsanusMokrassar/0.30.2
0.30.2
2020-11-10 21:52:37 +06:00
f8ea5f9515 fix in changelog 2020-11-10 21:45:07 +06:00
9f11c4f1c4 update ktor 2020-11-10 20:56:11 +06:00
9c91980d5d webhook fixes 2020-11-10 20:44:39 +06:00
7376eb5b10 start 0.30.2 2020-11-10 20:01:22 +06:00
6654f27f9d Merge pull request #202 from InsanusMokrassar/0.30.1
0.30.1
2020-11-09 15:16:26 +06:00
d29acce417 add suppressing of unused in EntitiesBuilder 2020-11-09 15:14:48 +06:00
f0f18209f3 a little bit improve EntitiesBuilder 2020-11-09 15:12:57 +06:00
324018a0f6 update publication scripts 2020-11-09 14:45:29 +06:00
b621325e92 update version of microutils and changelog 2020-11-09 08:37:30 +06:00
43e92555c2 Merge pull request #203 from Djaler/entities-dsl
Add builder-style dsl for text sources
2020-11-09 08:26:44 +06:00
Kirill Romanov
5f1ca51e60 Add builder-style dsl for text sources 2020-11-08 23:12:32 +03:00
83edda2dfe add link to bot template 2020-11-08 18:58:52 +06:00
1974c20229 start 0.30.1 2020-11-08 12:07:14 +06:00
499d9b1791 Update README.md 2020-11-08 00:03:41 +06:00
6caa7dd428 Merge pull request #163 from InsanusMokrassar/0.30.0
0.30.0
2020-11-07 23:00:35 +06:00
e8ded44562 rename StorageFile in jvm of common 2020-11-07 22:28:20 +06:00
1e6b0381ee StorageFile factories 2020-11-07 14:44:05 +06:00
1cf7ae7438 add micro_utils and deprecate old coroutine methods 2020-11-07 13:42:10 +06:00
311512b5db fix chat interfaces serializers 2020-11-07 01:34:22 +06:00
d73fa4076f add several extension properties to texted/captioned/explained interfaces 2020-11-06 19:13:59 +06:00
3620350cc0 add simple text dsl for textsources 2020-11-06 18:52:59 +06:00
54cfea9adf fill changelog 2020-11-06 14:42:30 +06:00
6665b6ef03 reorganize text sources and text parts 2020-11-06 14:37:13 +06:00
ee6f0f3d5d add separation of text sources 2020-11-06 12:59:55 +06:00
6ec0fcadd2 rewrite telegramBot functions 2020-11-06 12:29:51 +06:00
c89aa7b9ba telegramBot improvements 2020-11-06 12:07:46 +06:00
cf47cee36a Merge pull request #198 from madhead/issues/190
Fix #190: Support for Google Places values in venue-related methods and types
2020-11-06 11:23:29 +06:00
madhead
824fa9ba09 Fix #190: Support for Google Places values in venue-related methods and types 2020-11-06 00:06:33 +03:00
654d84b1b4 Merge pull request #197 from madhead/issues/175
Fix #175: Support for message_id field in unpinChatMessage method
2020-11-06 02:17:11 +06:00
madhead
c7259e7699 Fix #175: Support for message_id field in unpinChatMessage method 2020-11-05 23:15:23 +03:00
00a75801a8 fixes 2020-11-06 01:14:48 +06:00
e45f9cf46a return serialname for messageId in RawMessage 2020-11-06 00:37:56 +06:00
3b1803e851 remove deprecations 2020-11-06 00:12:14 +06:00
bf1e353615 fix build 2020-11-06 00:05:05 +06:00
99bb8d6e0d update extnsions.api 2020-11-05 23:48:23 +06:00
98d7b9c651 update coroutines :) 2020-11-05 21:42:31 +06:00
765caefc32 implementation of allow sending without reply (#191) 2020-11-05 21:33:11 +06:00
6bdefb6f8f new request CopyMessage (#187) 2020-11-05 20:27:45 +06:00
d5e283e7ba Update all classes which must have "entities"/"caption_entities" fields (#189) 2020-11-05 20:18:16 +06:00
a5982ac881 partially restructurize InlineQueryResult and several its implementators 2020-11-05 18:00:40 +06:00
c0e81b1d6d partially complete rewriting of things according to #189 2020-11-05 16:53:26 +06:00
eb879963f8 isAnonymous support in api 2020-11-05 12:48:44 +06:00
f835167f66 isAnonymous support 2020-11-05 12:47:14 +06:00
ff34b23777 implementation of sender_chat and author_signature 2020-11-05 12:39:59 +06:00
ec806dfd83 Merge pull request #195 from madhead/issues/184
Fix #184: Anonymous Admins: support for is_anonymous flag
2020-11-05 11:38:24 +06:00
madhead
0a73dfb799 Fix #184: Anonymous Admins: support for is_anonymous flag 2020-11-05 01:57:26 +03:00
53b8cc4625 update pollQuestionTextLength 2020-11-05 01:15:03 +06:00
201def826e locations updates 2020-11-05 01:12:14 +06:00
609a959b99 DiceAnimationType#valueLimits 2020-11-04 23:52:22 +06:00
6a05a7ecab add footbal dice animation type 2020-11-04 23:47:01 +06:00
159ea6f1cc UnpinAllChatMessages 2020-11-04 23:44:13 +06:00
0886781d61 add docs for PinChatMessage 2020-11-04 23:41:19 +06:00
60d5581ec6 supporting of private chats in pinChatMessage 2020-11-04 23:38:40 +06:00
2a33216006 disableContentTypeDetection 2020-11-04 23:33:48 +06:00
179bb66183 return SetWebhook without certificate 2020-11-04 23:21:25 +06:00
7a2ecd2dbf getChat updates completing 2020-11-04 23:10:39 +06:00
fd1a15cb5d ExtendedPrivateChat#bio 2020-11-04 22:46:08 +06:00
86a472e814 SetWebhook updates 2020-11-04 22:43:26 +06:00
6d6c544aaf logout and close 2020-11-04 22:17:17 +06:00
dd4d5cd15d start 0.30.0 2020-11-04 22:06:44 +06:00
23dfa4f69d Merge pull request #162 from InsanusMokrassar/0.29.4
0.29.4
2020-11-02 21:51:23 +06:00
a10d766295 slotmachine utils 2020-11-02 20:32:46 +06:00
ea6ab8f024 start 0.29.4 2020-11-02 20:10:38 +06:00
f377d61bf0 Merge pull request #158 from InsanusMokrassar/0.29.3
0.29.3
2020-11-02 14:21:54 +06:00
18c9d4e468 fill changelog 2020-11-02 14:14:08 +06:00
20b931138c update FlowsUpdatesFilter 2020-11-02 14:11:26 +06:00
d7bca15693 deprecations 2020-11-02 13:57:44 +06:00
957649603b fix for media fields in input media 2020-11-02 13:51:20 +06:00
bbc56fe94c hotfix in changelog 2020-11-02 13:26:06 +06:00
d048958423 WrongFileIdentifierException 2020-11-02 13:25:40 +06:00
f0e9267664 fixes in files and filling of changelog 2020-11-02 13:16:46 +06:00
5dd7207e09 update serialization version 2020-11-02 12:56:29 +06:00
d96d47e32c make different interfaces for audio and documents media content 2020-11-02 12:51:09 +06:00
1ee73dd406 sending media groups api updates 2020-11-02 12:39:12 +06:00
e9a05c4930 include audio playlists, documents and slot machine dice 2020-11-02 12:02:12 +06:00
9e771fa04a fixes 2020-11-02 11:13:16 +06:00
06ba21fc1f add changelog for audio and document media items 2020-10-30 20:40:44 +06:00
7d72d72f2c Revert "Revert "Revert "Revert "add slot machine, but currently it is not working""""
This reverts commit b457d11067.
2020-10-30 20:38:04 +06:00
80d4bdfe17 make audio and documents able to be media group items 2020-10-30 20:38:02 +06:00
b457d11067 Revert "Revert "Revert "add slot machine, but currently it is not working"""
This reverts commit 46fe16fd73.
2020-10-30 19:45:55 +06:00
46fe16fd73 Revert "Revert "add slot machine, but currently it is not working""
This reverts commit f317e144e6.
2020-10-30 19:37:26 +06:00
8e1cafb1b6 start 0.29.3 2020-10-30 19:36:48 +06:00
68d971f874 Merge pull request #155 from InsanusMokrassar/0.29.2
0.29.2
2020-10-27 15:55:17 +06:00
37a23c7e79 fixes in aggregation of flows 2020-10-27 15:51:48 +06:00
b053c29ea3 update aggregateFlows 2020-10-27 15:26:32 +06:00
23a1fed7dd Revert "update greetings config"
This reverts commit 87d2537bda.
2020-10-27 15:16:04 +06:00
87d2537bda update greetings config 2020-10-27 15:14:45 +06:00
6d782f28c3 updates after coroutines version change 2020-10-27 15:11:57 +06:00
d8dbbdf549 update coroutines 2020-10-27 15:01:30 +06:00
f317e144e6 Revert "add slot machine, but currently it is not working"
This reverts commit 4f9cb531c0.
2020-10-27 14:53:22 +06:00
05c27804ce update travis config 2020-10-22 19:19:55 +06:00
eb97a8e151 Merge pull request #154 from Megamiun/gm/update-dokka
Gm/update dokka
2020-10-22 19:18:51 +06:00
Gabryel Monteiro
06639e5f3c Update gradle.properties 2020-10-22 09:41:06 -03:00
82b7bf676f Update .travis.yml 2020-10-20 02:05:34 +06:00
4f9cb531c0 add slot machine, but currently it is not working 2020-10-19 20:26:36 +06:00
09bbb1945c start 0.29.2 2020-10-19 20:12:18 +06:00
7bedc4caf0 Merge remote-tracking branch 'original/master' into gm/update-dokka 2020-10-19 19:51:03 +06:00
6a73aa1525 add travis dokka step 2020-10-19 19:50:41 +06:00
e1ee541005 extend max heap size for gradle 2020-10-19 19:45:46 +06:00
Gabryel Monteiro
2d2fe01227 Changing Dokka version 2020-10-19 01:51:09 -03:00
Gabryel Monteiro
af53682b1f Removing kts notation 2020-10-19 00:45:29 -03:00
Gabryel Monteiro
c8a5552c9e Adding projects 2020-10-19 00:40:24 -03:00
Gabryel Monteiro
ffa78ebfe1 Update to 1.4.0 2020-10-18 22:38:16 -03:00
e85e7d02f7 Merge pull request #149 from InsanusMokrassar/0.29.1
0.29.1
2020-10-13 16:08:19 +06:00
37ad279ab4 Merge pull request #148 from leobia/master
Reformat CHANGELOG.md
2020-10-12 15:27:09 +06:00
3b41dc1fbf Merge remote-tracking branch 'original/0.29.1' 2020-10-12 15:26:11 +06:00
5747383ed1 Update README.md 2020-10-12 01:08:56 +06:00
18a6efabb8 post fixes for serialization update 2020-10-09 11:49:24 +06:00
dcb837b155 update serialization version 2020-10-09 11:41:08 +06:00
03755e9eef start 0.29.1 2020-10-09 11:35:33 +06:00
lbia
b9db2d544d Reformat CHANGELOG.md 2020-10-08 22:11:39 +02:00
800d14561e add conversations between AudioFile and VoiceFile 2020-10-04 20:00:43 +06:00
2378237fc5 Merge pull request #146 from InsanusMokrassar/0.29.0
0.29.0
2020-10-04 19:46:22 +06:00
35e28c00cb fix help for versions before 0.28.0 2020-10-04 19:31:45 +06:00
1913f1a900 update libraries schema 2020-10-04 19:26:16 +06:00
cbfd34098d READMEs fixes 2020-10-04 18:54:57 +06:00
e5618f4705 more fixes to god of fixes (docs fixes) 2020-10-04 18:50:05 +06:00
c9f2166e7d fixes in md files 2020-10-04 18:46:28 +06:00
eb960290c6 remove redundant changes 2020-10-04 18:39:03 +06:00
100f8b564a remove redundant changes 2020-10-04 18:37:55 +06:00
8e1ad9ffbc artifacts names has been changed 2020-10-04 18:34:03 +06:00
8875e2a986 update changelog parser 2020-10-04 17:43:25 +06:00
7478b151eb fixes in readmes 2020-10-04 17:41:30 +06:00
959136479e add information about migration in examples project 2020-10-04 17:35:24 +06:00
a52a62837e add migration notes 2020-10-04 17:17:52 +06:00
17dd694044 change package group and readmes 2020-10-04 17:10:03 +06:00
34fcfe2e20 migrate core project in new package 2020-10-04 17:06:30 +06:00
64862ecd2d experimentaly change package for extensions projects 2020-10-04 16:59:27 +06:00
c9edbbf7af migration onto major changes 0.29.0 2020-10-04 16:52:00 +06:00
a2f9a5a432 hotfix after SendVoice signature change 2020-10-04 16:49:43 +06:00
8337da34ca fix of #144 plus several other changes 2020-10-04 16:47:30 +06:00
f45956b554 hotfix for changelogs 2020-10-04 13:19:19 +06:00
bec1255d67 replaces of RequestsExecutor by TelegramBot typealias in TelegramBotAPI-extensions-api 2020-10-04 13:18:24 +06:00
39ca29279f fix forward_from_chat for SupergroupChat 2020-10-02 18:07:16 +06:00
70b592baad ForwardFromSupergroupInfo 2020-10-02 14:59:10 +06:00
403aa684a8 start 0.28.5 2020-10-02 14:58:27 +06:00
48c6f103b5 Update README.md 2020-10-02 14:27:07 +06:00
e326d289cb Create pull_request_template.md 2020-10-02 13:26:32 +06:00
7fd9c4c897 Create CONTRIBUTING.md 2020-10-02 13:10:01 +06:00
347a6212d4 Merge pull request #141 from InsanusMokrassar/0.28.4
0.28.4
2020-09-28 13:29:22 +06:00
e10e257c80 update ktor 2020-09-28 13:18:03 +06:00
5e7bc96b44 add deprecations 2020-09-28 13:11:41 +06:00
79d0eda61d add changelog 2020-09-28 13:09:58 +06:00
9916b3f469 Merge pull request #140 from madhead/issues/139
Fix #139: Add "from" field to chat events
2020-09-28 12:55:13 +06:00
2bac5f0eed start 0.28.4 2020-09-28 12:54:01 +06:00
madhead
01eb072caa Fix #139: Add "from" field to chat events 2020-09-27 13:26:10 +03:00
496af479b0 Revert "add karma for tests"
This reverts commit 386e91e28b.
2020-09-22 22:42:01 +06:00
386e91e28b add karma for tests 2020-09-22 22:33:45 +06:00
91dbcecefc add autoPublishing 2020-09-22 18:53:48 +06:00
2d743e4c19 Merge pull request #136 from InsanusMokrassar/0.28.3
0.28.3
2020-09-22 18:32:06 +06:00
8804a24013 small refactoring 2020-09-22 18:12:48 +06:00
8b5244d8df hotfix 2020-09-22 18:06:50 +06:00
034901a479 add publication of github release via changelog 2020-09-22 18:04:10 +06:00
7043647584 changelog parser script has been added 2020-09-22 15:15:20 +06:00
acd9505a5d inline queries extensions 2020-09-22 14:47:34 +06:00
46c33d5ec4 update dependencies 2020-09-22 11:33:47 +06:00
89dc7a4b2a InlineQueryResult#id type change 2020-09-20 20:16:14 +06:00
e4f305b3ec start 0.28.3 2020-09-20 20:11:27 +06:00
d56c132201 Reorder 0.28.* changelogs 2020-09-16 19:28:05 +06:00
d336e177dd Merge pull request #135 from InsanusMokrassar/0.28.2
0.28.2
2020-09-16 11:45:22 +06:00
15e29286fb commonMessages and sent via bot shortcuts updates 2020-09-14 00:12:28 +06:00
314ceed78e signature change in filterCommandsWithArgs 2020-09-13 23:58:09 +06:00
3fa3aa50d9 commands shortcuts 2020-09-13 23:42:59 +06:00
571296b9a0 start 0.28.2 2020-09-13 23:32:47 +06:00
3f13e5d062 Merge pull request #132 from InsanusMokrassar/0.28.1
0.28.1
2020-09-12 22:38:24 +06:00
1874023c05 fixes in build + changes in signature of executeUnsafe 2020-09-12 16:22:39 +06:00
dc0fda2066 update handleSafely 2020-09-12 16:18:00 +06:00
c0d4a4f01b update gradle wrapper version 2020-09-12 15:49:09 +06:00
603762bc22 update kotlin and UUID versions 2020-09-12 15:44:44 +06:00
4db82d6ce2 start 0.28.1 2020-09-12 15:40:12 +06:00
9bf8f56254 update SimpleInputFilesTest 2020-08-29 19:52:46 +06:00
9c926a2265 update SimpleInputFilesTest 2020-08-29 19:51:10 +06:00
747854f4f4 Merge pull request #123 from InsanusMokrassar/0.28.0
0.28.0
2020-08-29 18:46:16 +06:00
dcfb14553d JS/JVM errors opportunity note 2020-08-29 18:37:02 +06:00
6eaa9d699b crutch for inputmediaphoto 2020-08-29 12:08:37 +06:00
6788c4d1dd make the test failing again 2020-08-24 00:34:30 +06:00
6420737a82 remove arguments 2020-08-24 00:27:37 +06:00
4c36750431 add failing test which normally must be working ok 2020-08-23 23:42:50 +06:00
fd022742aa files downloading extensions in utils 2020-08-23 23:37:29 +06:00
0472e35752 Merge pull request #124 from sleshJdev/feature/download-pathed-file-extension
Extended PathedFile to get it as file/stream
2020-08-23 21:44:53 +06:00
768d00eedd total rework (by accident) 2020-08-23 21:43:58 +06:00
e9347075ed Merge remote-tracking branch 'upstream/0.28.0' into feature/download-pathed-file-extension 2020-08-23 18:57:03 +06:00
slesh
3da74b0c66 Converted to expression body 2020-08-23 01:05:12 +03:00
slesh
8b79c5c76b Use DEFAULT_BUFFER_SIZE 2020-08-23 01:04:01 +03:00
slesh
a1b471d2ca Added asBytes method. Used InputStream.copyTo 2020-08-23 01:02:50 +03:00
slesh
e2c7125f6c Extended PathedFile to get it as file/stream 2020-08-23 00:47:17 +03:00
ec8df3c31c start work with publication 2020-08-20 22:26:35 +06:00
94a35349aa temporal update 2020-08-20 17:35:26 +06:00
046402454f Revert "try to fix problem with arguments in InputMedia"
This reverts commit c3978f2dab.
2020-08-20 16:07:01 +06:00
c3978f2dab try to fix problem with arguments in InputMedia 2020-08-20 15:58:11 +06:00
1019fd4d19 turn on incremental building and add TelegramBot typealias 2020-08-20 15:00:45 +06:00
76a9fd1a55 updates in readmes 2020-08-20 13:55:34 +06:00
aec4c7323a fill changelog 2020-08-20 12:02:28 +06:00
7bdfd5cf69 update README 2020-08-20 11:58:37 +06:00
ce95a60fbc migration of artifacts names 2020-08-20 11:55:39 +06:00
3c17a67b01 rewrite on BOTH for JS 2020-08-20 10:51:05 +06:00
35bf5b9e9d fix of formatter in ChatSerializers 2020-08-20 02:00:42 +06:00
0087d02b5f potential fix of build 2020-08-20 01:17:32 +06:00
212d8946c8 update travis build 2020-08-19 13:52:18 +06:00
319e43901a several more changes in build.script's 2020-08-19 13:49:30 +06:00
da01955507 pass old way for building of js part 2020-08-19 12:14:28 +06:00
095382040c update travis build config 2020-08-19 00:31:14 +06:00
5545708d38 fix after ktor update 2020-08-19 00:28:16 +06:00
5d06d86549 update ktor version 2020-08-19 00:19:09 +06:00
c081e5c457 add IR compiling 2020-08-19 00:07:55 +06:00
555c2ffa04 try to fix 2020-08-18 20:49:27 +06:00
bcee64c103 try to fix 2020-08-18 20:44:31 +06:00
44a35bd26e upgrade travis config 2020-08-18 13:50:26 +06:00
1f5c719294 deprecations removing and several warnings fixes 2020-08-18 13:45:15 +06:00
6013c3ba86 versions updates 2020-08-18 12:50:11 +06:00
d4551490f7 start 0.28.0 2020-08-18 10:56:05 +06:00
cc0498a89a Update README.md 2020-08-14 23:44:21 +06:00
0b78c0382f Merge branch '0.27.11' 2020-08-14 19:29:16 +06:00
c91426a910 filename created 2020-08-14 19:26:51 +06:00
5d1c59ff75 Merge pull request #97 from InsanusMokrassar/0.27.11
0.27.11
2020-08-14 18:43:51 +06:00
d2228e274c sentMessages extension for FlowsUpdatesFilter 2020-08-13 15:28:10 +06:00
790959ea49 add a lot of extension for FlowUpdatesFilter and Flow 2020-08-13 14:55:21 +06:00
ce9f7f35dc fix scope of one of startGettingOfUpdatesByLongPolling 2020-08-13 13:45:25 +06:00
4f984d1dbc update documentation for FlowsAggregation 2020-08-13 12:53:04 +06:00
c83da6be70 Merge pull request #98 from InsanusMokrassar/renovate/configure
Configure Renovate
2020-08-13 02:24:42 +06:00
Renovate Bot
710438489c Add renovate.json 2020-08-12 20:21:10 +00:00
6f650f6d6c Flow<BaseSentMessageUpdate> extensions 2020-08-13 01:19:12 +06:00
2d15e13ae6 started 0.27.11 2020-08-13 01:08:44 +06:00
d60ee7b8a5 Merge pull request #96 from InsanusMokrassar/0.27.10
0.27.10
2020-08-11 12:58:45 +06:00
8f882e9825 fix links in toc of extensions readme 2020-08-10 20:02:11 +06:00
48e946c2d0 add a simple fix in readme 2020-08-10 20:00:45 +06:00
1758d80020 new telegramBot 2020-08-10 13:38:19 +06:00
63b2bd61b5 add aggregation of flows 2020-08-10 11:53:54 +06:00
ff2c70fc76 FlowsUpdatesFiler extensions 2020-08-10 11:41:46 +06:00
e3bfc4472a includeWebhookHandlingInRouteWithFlows 2020-08-10 10:46:18 +06:00
1cff6f616f start 0.27.10 2020-08-10 10:45:46 +06:00
1dfe4bf276 Merge pull request #95 from InsanusMokrassar/0.27.9
0.27.9
2020-08-06 21:38:39 +06:00
e4b09032cd deprecate PositionedInlineQueryResult 2020-08-03 12:15:59 +06:00
e8e54a0aea add labeler config for versions 2020-08-03 11:46:38 +06:00
8f85b4cba3 versions update 2020-08-03 11:41:14 +06:00
46d65a271d start 0.27.9 2020-07-29 15:38:32 +06:00
e088329ce1 Update README.md 2020-07-20 15:15:06 +06:00
8d9ebb754b Merge pull request #94 from InsanusMokrassar/0.27.8
0.27.8
2020-07-02 16:39:04 +06:00
c0a43077ad optimize imports 2020-07-02 16:15:06 +06:00
1811a63a13 update last added sendVenue 2020-07-02 16:00:38 +06:00
cba0e30710 sendVenue with Location 2020-07-02 15:55:14 +06:00
ff0b7faa48 Foursquare and fixes of deprecations in methods 2020-07-02 00:52:52 +06:00
975898660c TelegramBotAPI Venue and foursquare additions 2020-07-01 23:57:20 +06:00
cfb7f35d20 add several makeLinkToMessage 2020-06-27 10:11:03 +06:00
147889a66a update readme 2020-06-27 09:59:57 +06:00
ed9ed715a0 update defaults for new FlowsUpdatesFilter 2020-06-27 09:51:18 +06:00
a9a3f55c8d refactoring of FlowsUpdatesFilter 2020-06-27 09:44:50 +06:00
58943f2504 small refactor of BaseMessagesUpdatesConversations 2020-06-27 09:31:29 +06:00
5f7633a57e start 0.27.8 2020-06-27 09:30:25 +06:00
65cfc3220d add hierarchy diagram 2020-06-26 19:11:59 +06:00
36d30ef91b Merge pull request #92 from InsanusMokrassar/0.27.7
0.27.7
2020-06-26 17:50:05 +06:00
41e5c579a2 add excluding of CHANGELOG file for labeler 2020-06-26 17:45:16 +06:00
bbf63c51ec Revert "add com.soywiz.korlibs.krypto:krypto dependency"
This reverts commit acfb7066d2.
2020-06-25 15:45:38 +06:00
fb91199f83 Revert "start implement passport"
This reverts commit d76c09ffb2.
2020-06-25 15:45:35 +06:00
d76c09ffb2 start implement passport 2020-06-25 15:45:15 +06:00
acfb7066d2 add com.soywiz.korlibs.krypto:krypto dependency 2020-06-25 12:07:48 +06:00
7507c107b4 add one more flatMatrix 2020-06-24 20:54:22 +06:00
2acb177ad6 first keyboards improvements 2020-06-24 20:51:48 +06:00
b5a14077fd start 0.27.7 2020-06-24 20:25:51 +06:00
5f60bf003f Add useful links 2020-06-07 17:27:20 +06:00
f9b2c4c403 update README 2020-06-05 17:01:37 +06:00
c909774403 Merge pull request #91 from InsanusMokrassar/0.27.6
0.27.6
2020-06-05 15:44:30 +06:00
670cfcca13 update kotlin coroutines 2020-06-05 15:17:14 +06:00
130e00b62b extensions for CommonMessage 2020-06-05 14:57:58 +06:00
ca4beee95f add PossiblySentViaBotCommonMessage and fix error in build 2020-06-05 14:25:19 +06:00
ca784e67df add BuiltInMimeTypes, ThumbedWithMimeTypeInlineQueryResult and buildMimeType factory 2020-06-05 14:01:19 +06:00
835b8b34f9 add via_bot 2020-06-05 13:40:12 +06:00
e6430a729c work on version 0.27.6 has been started 2020-06-05 13:37:11 +06:00
6c4c9f2fc6 by default dokka task will not set up exact folder for docs 2020-06-03 15:42:00 +06:00
310a7e6e82 update docs build gradle to be able to put dokka where it is required 2020-06-03 15:39:54 +06:00
7375894645 Merge pull request #90 from InsanusMokrassar/0.27.5
0.27.5
2020-06-02 22:26:07 +06:00
69973c597b update BotCommandNameRegex 2020-06-02 22:10:33 +06:00
22e8b06fda BotBuilder fixes 2020-06-02 21:18:49 +06:00
7ede53fdbb BotCommandNameRegex and strict check of incoming command 2020-06-02 20:16:55 +06:00
ca9051920d new setMyCommands extension added 2020-06-02 19:54:13 +06:00
b477e8d585 extend getChat extensions 2020-06-02 13:54:30 +06:00
8ae2f57d55 update description of PreviewFeature annotation 2020-06-02 13:47:28 +06:00
1fb2ecf15f executes was replaced 2020-06-02 13:39:09 +06:00
6073d914d5 hotfixes in new media groups shortcuts 2020-06-02 13:22:36 +06:00
16f55d70af resend and other media group utils replaced into TelegramBotAPI_extensions-utils 2020-06-02 13:21:38 +06:00
b484a31a4a replacement of CaptionAndTextSourcesToText 2020-06-02 13:05:15 +06:00
0a162c4129 StringFormattiing replacement 2020-06-02 01:26:46 +06:00
648f1b488b add makeLinkToAddStickerSet 2020-06-02 01:15:08 +06:00
5fbde4bc06 new "row" 2020-06-02 01:02:38 +06:00
2a276d9272 safely function 2020-06-01 12:56:48 +06:00
9ae252717d versions update 2020-06-01 12:00:06 +06:00
456143a266 complete refresh of CaptinAndTextSourcesToText 2020-06-01 11:55:48 +06:00
0bcc98e126 update caption errors 2020-06-01 11:53:33 +06:00
ab9ceba41c updates in caption and text lengths 2020-06-01 11:44:58 +06:00
7cd5666e88 use maxTextLength inside of CaptionAndTextSourcesToText 2020-05-31 22:53:04 +06:00
35dcd6ada7 fix in SendMessage 2020-05-31 22:51:42 +06:00
ec37df82a9 start 0.27.5 2020-05-31 22:43:35 +06:00
220cb47615 update look like of kdocs badge 2020-05-23 15:46:49 +06:00
d79b8a337a add kdocs badge 2020-05-23 15:43:47 +06:00
cef6a6f741 update telegram badge 2020-05-23 15:27:45 +06:00
9471df1f2d Merge pull request #89 from InsanusMokrassar/0.27.4
0.27.4
2020-05-23 15:22:13 +06:00
f121e5f9c3 renames for JVM signature duplication avoiding 2020-05-23 12:53:42 +06:00
7f4fe318c5 update filters 2020-05-22 16:40:30 +06:00
dbf5c2dbb2 update publish scripts 2020-05-22 14:03:48 +06:00
105415873d updates extensions 2020-05-22 13:21:22 +06:00
ff32fd1dfc 0.27.4 started 2020-05-22 12:56:50 +06:00
006251ed07 fixes 2020-05-17 15:10:02 +06:00
9307582654 Add TelegramBotAPI-all status to readme 2020-05-17 01:30:05 +06:00
fe11a2119e Return opts in telegram bot api 2020-05-16 22:24:50 +06:00
c31403c1a2 Merge pull request #88 from InsanusMokrassar/0.27.3
0.27.3
2020-05-16 22:07:56 +06:00
0260e7bedc fixes of warnings 2020-05-16 22:02:57 +06:00
fa43a55f26 one more update of labeler 2020-05-16 21:54:54 +06:00
e9e1f4b9cf Merge branch 'master' into 0.27.3 2020-05-16 21:24:14 +06:00
e7b5b9184d update rules for labelers 2020-05-16 21:22:37 +06:00
81aa3f2307 update labeler task 2020-05-16 21:19:38 +06:00
a9fe584504 add TOC for TelegramBotAPI-extensions-utils 2020-05-16 21:14:10 +06:00
4c8861ba79 change visibility of internalSetWebhookInfoAndStartListenWebhooks 2020-05-16 20:57:57 +06:00
0ec18cbf06 dice changes 2020-05-16 20:46:49 +06:00
7008f312dc fixes 2020-05-16 20:43:09 +06:00
85317a510e update docs 2020-05-16 11:09:31 +06:00
d629aa206e fixes 2020-05-15 22:14:19 +06:00
6394e1a52b setWebhookInfo 2020-05-15 22:02:53 +06:00
23dca3d307 small grammar fix in WebhookInfo 2020-05-15 19:19:30 +06:00
3032aa8474 renaming of telegramBot functions 2020-05-15 19:14:09 +06:00
db19b69ca0 fails handler in executeUnsafe 2020-05-15 19:04:10 +06:00
f3827f81a7 change mechanism of executeUnsafe 2020-05-15 18:59:42 +06:00
0532dbb1ae fixes 2020-05-15 18:39:12 +06:00
efc2681da8 add additional signatures for setWebhookInfoAndStartListenWebhooks 2020-05-15 18:35:16 +06:00
735ed9fd86 change flowsUpdatesFilter signature 2020-05-15 18:31:49 +06:00
e856dc4754 add flowsUdatesFilter 2020-05-15 18:17:55 +06:00
0706ff1f95 Update labeler.yml 2020-05-15 18:06:29 +06:00
336b830b0b Merge branch 'master' into 0.27.3 2020-05-15 18:05:57 +06:00
1a638fe0a5 update labeler
one more update of labeler
2020-05-15 18:05:00 +06:00
45467e5bd7 Create labeler.yml 2020-05-15 18:05:00 +06:00
8419b0ab6a Create label.yml 2020-05-15 18:05:00 +06:00
49573607fb Create greetings.yml 2020-05-15 18:05:00 +06:00
35fe48db35 Create labeler.yml 2020-05-15 17:05:53 +06:00
590db3e672 Create label.yml 2020-05-15 17:02:33 +06:00
ea40474c47 add opportunity to set up media groups devounce time 2020-05-15 16:53:21 +06:00
7354389f2d Create greetings.yml 2020-05-15 15:49:10 +06:00
1f20ae16aa Update README.md 2020-05-15 00:54:00 +06:00
095c91bf39 update readmes with updates handling 2020-05-15 00:48:34 +06:00
dc173d752c optimize imports 2020-05-15 00:29:17 +06:00
a1788e35b2 clean up in webhooks 2020-05-15 00:28:16 +06:00
ea224fd765 add javax.activation dependency 2020-05-14 21:18:33 +06:00
7f51544bb9 Fix links in TelegramBotAPI-all readme 2020-05-14 16:25:39 +06:00
dfb22b0e89 update readme of all includer 2020-05-14 14:26:42 +06:00
e675e841da update urls 2020-05-14 14:23:26 +06:00
dea43aad8e update subprojects implementation types 2020-05-14 14:11:33 +06:00
52e25e934d add TelegramBotAPI-all 2020-05-14 14:07:23 +06:00
acc067585d add build instructions in README 2020-05-14 13:44:18 +06:00
47aa1a0795 fixes in CHANGELOG and docs 2020-05-14 13:26:56 +06:00
b40cc0c1ea fixes 2020-05-14 13:11:46 +06:00
b5632626ad small extention docs for RequestsExecutor 2020-05-14 12:21:38 +06:00
67fafdac00 add docs for RequestsExecutor 2020-05-14 12:14:38 +06:00
738e628a89 small change of deprecations message 2020-05-13 23:25:22 +06:00
420b846466 replace long polling and webhook tools 2020-05-13 23:22:35 +06:00
05e8c9c90d replace webhooks work into api subproject 2020-05-13 21:21:07 +06:00
e776c5182f additional setWebhook 2020-05-13 20:56:03 +06:00
be5b3745b9 extension was added 2020-05-13 20:01:58 +06:00
0de1d9cfda UpdateDeserializationStrategy currently is public 2020-05-13 19:53:27 +06:00
01da98d2fe start 0.27.3 2020-05-13 19:48:07 +06:00
e985100c21 Update README.md 2020-05-13 19:41:46 +06:00
671faabef9 add telegramBot function 2020-05-12 18:52:37 +06:00
bb9c9e22a2 remove dokka docs from github 2020-05-12 00:14:16 +06:00
42228f0eaa Merge pull request #86 from InsanusMokrassar/0.27.2
0.27.2
2020-05-11 23:42:17 +06:00
dafd0a8ece add docs 2020-05-11 23:37:38 +06:00
bee9d82372 update folder of dokka 2020-05-11 23:24:26 +06:00
ec6cf0f029 docs 2020-05-11 20:44:03 +06:00
9cee22165d start normal filling of docs 2020-05-11 20:32:14 +06:00
a58aad1198 update docs generation 2020-05-11 13:56:45 +06:00
aa78d99179 add docs project 2020-05-11 01:09:07 +06:00
603efe9259 small update of utils readme 2020-05-10 16:40:53 +06:00
21e3e10222 renames 2020-05-10 16:33:44 +06:00
34eb6eb4bf add ChatEventsConversations and refill README of telegramboapi-extensions-utils 2020-05-10 16:25:42 +06:00
565a724b9c remove todo from thumbed input media 2020-05-10 15:30:23 +06:00
e87c4a0126 MediaGroupMemberInputMedia deserialization 2020-05-10 15:26:07 +06:00
9b16d5d82b add MimeType 2020-05-10 14:37:55 +06:00
9747c8bff1 warnings fixes 2020-05-09 21:04:56 +06:00
3ee84700f4 update versions 2020-05-09 20:57:55 +06:00
04a463f42c start 0.27.2 2020-05-09 20:52:52 +06:00
668a201789 Merge pull request #85 from InsanusMokrassar/0.27.1
0.27.1
2020-04-25 10:12:53 +06:00
b336b17eef FullTextSourcesList 2020-04-25 09:57:59 +06:00
76b25d719a explanation small utils and explanationLimit 2020-04-25 09:48:23 +06:00
a4d077dd17 add Explained interface and use it in polls 2020-04-25 09:41:04 +06:00
469712150b started 0.27.1 2020-04-25 09:26:10 +06:00
fad27ede78 Merge pull request #84 from InsanusMokrassar/0.27.0
0.27.0
2020-04-24 21:25:11 +06:00
1de90412b3 addition in changelog 2020-04-24 21:24:24 +06:00
215c8793e1 optimize imports 2020-04-24 20:25:53 +06:00
54835f97d1 update TelegramBotAPI utils readme 2020-04-24 20:23:25 +06:00
923e929670 update TelegramBotAPI readme 2020-04-24 20:16:12 +06:00
37488e92e6 utils ScheduledCloseInfo shortcuts 2020-04-24 20:01:20 +06:00
830ca8122d add openPeriodPollSecondsLimit and checks 2020-04-24 19:46:47 +06:00
fbb2758bdb update changelog 2020-04-24 19:26:57 +06:00
a5c3e06f1c remove List<TextPart> extensions for texts due to JVM signature conflict and actualize TelegramBotAPI-extensions-api 2020-04-24 19:24:49 +06:00
c6fb50c4a6 SendPoll#closeInfo functionality 2020-04-24 19:08:54 +06:00
976c0b86dc send quiz poll functionality 2020-04-24 18:46:26 +06:00
fee5d8f925 texts and captions utils 2020-04-24 18:44:04 +06:00
808746e12d Dice#emoji support 2020-04-24 18:25:47 +06:00
3fb80dd475 add support of income explanation functionality in polls and polls auto close functionality 2020-04-24 17:51:09 +06:00
db8ea0da94 update versions 2020-04-24 16:18:07 +06:00
fbdfb714a3 started 0.27.0 2020-04-24 16:13:02 +06:00
1facfbc2b7 Merge pull request #83 from InsanusMokrassar/0.26.4
0.26.4
2020-04-22 15:08:35 +06:00
914a0662a9 CallbackGameInlineKeyboardButton now have only one income parameter 2020-04-22 14:11:46 +06:00
eda3003b7d change the way how we are deserializing updates in webhooks 2020-04-22 13:20:15 +06:00
459942de36 webhook update handling enhancement 2020-04-22 13:16:46 +06:00
17f64f9b48 CallbackGame update 2020-04-22 13:08:05 +06:00
3f896c2240 fix not implemented error thrown 2020-04-22 13:05:57 +06:00
94f8c971c5 started 0.26.4 2020-04-22 13:01:17 +06:00
c43109c063 Update README.md 2020-04-17 15:52:47 +06:00
f6058e29b4 Update README.md 2020-04-17 15:52:28 +06:00
3a37311331 Update README.md 2020-04-17 15:52:03 +06:00
9fe1472e64 update readme for help on JS platform 2020-04-17 15:43:43 +06:00
f1480c40a7 Merge pull request #81 from InsanusMokrassar/0.26.3
0.26.3
2020-04-13 12:55:48 +06:00
88eebdc448 small optimization of updates polling exception handling 2020-04-13 12:53:02 +06:00
8c76283db5 suspend inline function handleSafely was added 2020-04-13 12:40:14 +06:00
7668c48081 BaseEditMessageUpdate#data now is CommonMessage 2020-04-13 12:09:59 +06:00
35d2135f73 update serialization of InlineKeyboardButton 2020-04-13 11:31:36 +06:00
1cb0e096be fixes in InlineKeyboardButtonSerializer 2020-04-13 11:20:39 +06:00
31f7c7f31b UnknownUpdateType even if serialization exception 2020-04-13 11:17:15 +06:00
82d3b3bc48 add UnknownInlineKeyboardButton 2020-04-13 11:11:09 +06:00
b3734a5c2a fix of changelog 2020-04-13 01:46:58 +06:00
55b8736d50 Merge pull request #80 from Djaler/inline-keyboard-button-callback-game
Add support for inline keyboard buttons with callback_game field
2020-04-13 01:40:52 +06:00
3334fd3ca6 started 0.26.3 2020-04-13 01:39:31 +06:00
Kirill Romanov
e2416b405a add support for inline keyboard buttons with callback_game field 2020-04-12 22:30:37 +03:00
14f012fbfa Update README.md 2020-04-09 01:24:55 +06:00
1ff55057f2 Merge pull request #78 from InsanusMokrassar/0.26.2
0.26.2
2020-04-08 16:48:00 +06:00
71b5e33dbc update common README 2020-04-08 15:28:03 +06:00
08d9d183f4 add filterCommandsWithArgs 2020-04-08 15:23:12 +06:00
7183634fd6 experimentally make source string available inside of text sources 2020-04-08 15:17:13 +06:00
cf9f270651 rename new getting updates extension to avoid JVM signature collisions 2020-04-08 14:56:56 +06:00
bd87938e9c fixes in UpdatesChatFilters 2020-04-08 14:51:26 +06:00
ba76eaeb90 update readmes 2020-04-08 14:34:55 +06:00
d8492ae168 fixes, new readme 2020-04-08 14:02:55 +06:00
0db85232d3 fixes in changelog 2020-04-08 13:20:48 +06:00
bcf2325be8 make new startGettingOfUpdates more useful 2020-04-08 13:19:19 +06:00
51174a13de added some of extensions in TelegramBotAPI-extensions-utils 2020-04-08 11:50:47 +06:00
dfc1fa4d7e refill of changelog 2020-04-08 11:11:31 +06:00
10a1d1cb38 add TelegramBotAPI-extensions-utils 2020-04-08 11:05:48 +06:00
6c39dc4d06 new startGettingOfUpdates extension 2020-04-08 10:44:44 +06:00
4877b8958e start 0.26.2 2020-04-08 10:37:05 +06:00
db9c460e66 Merge pull request #75 from InsanusMokrassar/0.26.1
0.26.1
2020-04-06 12:15:27 +06:00
2bd5d53b2a fill changelog 2020-04-06 12:11:14 +06:00
577436843d fixes 2020-04-06 12:09:59 +06:00
048aa93044 InvalidPhotoDimensionsException 2020-04-05 14:06:40 +06:00
4e49de0dd7 fix in hashtag 2020-04-04 12:12:12 +06:00
9dc5a7624d complete CHANGELOG 2020-04-03 14:26:32 +06:00
21a15db031 StorageFile improvement 2020-04-03 14:22:34 +06:00
a6aa4b8758 BotCommand checks 2020-04-01 10:08:44 +06:00
e85d5df03e started 0.26.1 2020-04-01 10:05:30 +06:00
6833640c48 Create write-good.yml 2020-03-31 19:13:48 +06:00
c22c1bb144 Merge pull request #74 from InsanusMokrassar/0.26.0
0.26.0
2020-03-31 11:45:47 +06:00
8293d6683c optimize imports 2020-03-31 11:41:58 +06:00
7e6e892c45 libraries updates 2020-03-31 11:31:24 +06:00
43ac09a79b fixes in startGettingUpdates 2020-03-31 11:28:48 +06:00
ee1f115d77 refill TelegramBotAPI-extensions-api 2020-03-31 11:11:37 +06:00
7d85b6fb88 update readme of telegram bot api 2020-03-31 11:00:22 +06:00
013944c5c9 real fix:) 2020-03-30 22:52:57 +06:00
55ed3e165b resolve compiling errors 2020-03-30 22:47:20 +06:00
9c0106d229 StickerSetAction -> StandardStickerSetAction 2020-03-30 22:31:54 +06:00
9cd2a6220c add setStickerSetThumb 2020-03-30 22:29:34 +06:00
033ec8f2da update version 2020-03-30 22:18:59 +06:00
274afe8efc addAnimatedStickerToSet 2020-03-30 22:12:31 +06:00
e60630b331 add StickerSet#thumb 2020-03-30 22:07:13 +06:00
f6692a22d1 create new animated sticker set 2020-03-30 22:03:59 +06:00
53257ff131 hotfix for setMyCommands request 2020-03-30 21:53:36 +06:00
ec70813e49 commands handling added 2020-03-30 21:52:00 +06:00
54589ed17b BotCommand 2020-03-30 21:40:36 +06:00
1d3736c44e add realisation of DiceContent#createResend 2020-03-30 21:37:30 +06:00
8ef7acab2d sendDice in extensions api 2020-03-30 21:33:17 +06:00
c3fca5c6c4 include dice in TelegramBotAPI 2020-03-30 21:30:22 +06:00
84d2c88032 started 0.25.2 2020-03-30 21:16:04 +06:00
b7ec2f2b86 Merge pull request #71 from InsanusMokrassar/0.25.1
0.25.1
2020-03-26 14:36:00 +06:00
97d6d3ad13 update kotlin 2020-03-26 14:27:17 +06:00
3dd428c7d9 fix of error inside of update utils for media groups 2020-03-26 14:26:44 +06:00
688de1053b started 0.25.1 2020-03-26 14:13:00 +06:00
a4fae36b22 hotfix for ExtendedUser 2020-03-22 22:57:01 +06:00
909a7fd26a add ExtendedUser 2020-03-22 22:37:26 +06:00
041232e260 FlowUpdatesFilter update 2020-03-22 17:21:01 +06:00
d4c409107a Merge pull request #69 from InsanusMokrassar/0.25.0
0.25.0
2020-03-22 16:50:50 +06:00
a0db95d929 suppressions nad compiler args 2020-03-22 16:41:48 +06:00
fb34b0bec1 optimize imports 2020-03-22 16:04:11 +06:00
d18863b7b3 TelegramDateTests now using strict json 2020-03-22 15:56:05 +06:00
c5c8a743e6 fixes in ChatIdentifierSerializer 2020-03-22 15:53:37 +06:00
89881a7349 removing of deprecations 2020-03-22 15:15:01 +06:00
865edf385f fix several todo 2020-03-22 14:07:00 +06:00
c85faa73c0 fixes 2020-03-22 13:53:42 +06:00
6b3f836096 new libraries versions adaptation 2020-03-22 13:37:01 +06:00
574ffbc44d update versions 2020-03-22 13:04:40 +06:00
a0120afb08 now bot username is not nullable 2020-03-22 12:56:52 +06:00
0b4b4950c2 started 0.25.0 2020-03-22 12:54:15 +06:00
b3391330a0 add setting up of socketTimeoutMillis inside of abstract request call factory for GetUpdates 2020-03-19 12:41:16 +06:00
518dee46b3 now startGettingOfUpdates have exceptions handler as argument 2020-03-19 12:03:40 +06:00
c9de4bc79e hotfix for installing of HttpTimeout inside of client only in case when it was not installed previously 2020-03-19 11:10:18 +06:00
badb138bc1 Merge pull request #67 from InsanusMokrassar/0.24.1
0.24.1
2020-03-18 23:02:01 +06:00
4b980d3f44 remove redundant import from webhooks 2020-03-18 22:58:23 +06:00
b11da02c8b refactor UpdatesUtils 2020-03-18 22:56:57 +06:00
71c0b688e8 fixes and improvements 2020-03-17 21:24:04 +06:00
d61aa8b50e getting updates refactoring 2020-03-17 20:24:31 +06:00
be64287c42 copypaste functions from TelegramBotAPI to TelegramBotAPI-extensions-api with adaptation of updates 2020-03-17 19:50:25 +06:00
e7027047cb abstracts for difference between sent and edited messages updates 2020-03-17 19:46:42 +06:00
944d15f326 new startGettingUpdates method 2020-03-17 17:20:42 +06:00
ba2c4cbb30 UpdatesFilter now is interface 2020-03-17 17:16:14 +06:00
244a1e5175 replacement of UpdatesPolling help functions 2020-03-17 16:59:28 +06:00
9c9a938d94 started 0.24.1 2020-03-17 16:47:59 +06:00
a2a403045b a little fix on README 2020-03-17 13:30:01 +06:00
6858af14f8 update info sections 2020-03-17 13:25:10 +06:00
779009c2a6 Merge pull request #66 from InsanusMokrassar/0.24.0
0.24.0
2020-02-25 21:01:46 +06:00
b22d8a5a25 ForwardFromChannelInfo#channelChat now is ChannelChat 2020-02-25 13:45:32 +06:00
54e3c43999 Most part of sending media messages functions was removed and replaced with their InputFile args analogs 2020-02-23 21:29:31 +06:00
f8a312acb3 removing of deprecations 2020-02-23 20:23:33 +06:00
a51e68be04 Update LICENSE 2020-02-19 22:29:53 +06:00
39dab0b970 Replace build badge and link it with travis 2020-02-19 20:12:54 +06:00
b42a6ca0cf Create .travis.yml 2020-02-19 20:08:15 +06:00
a34e67722b update telegrambotapi-extensions-api readme 2020-02-18 19:10:08 +06:00
c0e660c8d3 replace awesome badge 2020-02-17 15:35:33 +06:00
7cca12930c fixes and fill up 2020-02-17 15:33:28 +06:00
5da60b4ac2 update README 2020-02-17 15:25:08 +06:00
51dac40e45 now for extensions api system environment will be checked too 2020-02-17 11:49:48 +06:00
51fc33960a now group is common 2020-02-17 11:47:43 +06:00
b89b798eb6 remove redundant readme 2020-02-15 16:58:26 +06:00
a9326bb374 Merge pull request #65 from InsanusMokrassar/0.23.3
0.23.3
2020-02-15 16:57:29 +06:00
edad64c6e3 actualize changelog 2020-02-15 16:56:15 +06:00
8c06322586 now LiveLocation is deprecated in TelegramBotAPI and placed into TelegramBotAPI-extensions-api 2020-02-15 16:19:12 +06:00
9684e55c12 update group badge
update group badge

update group badge
2020-02-15 16:11:42 +06:00
d7d92cd83f fixes in readme 2020-02-15 15:49:29 +06:00
7229d96ce7 remove redundant .gitignore 2020-02-15 15:38:24 +06:00
c32ab031dd fill changelog 2020-02-15 15:37:15 +06:00
a8d7104145 extract RequestsExecutor extensions 2020-02-15 15:33:04 +06:00
ff550fafde add subproject TelegramBotAPI-extensions-api 2020-02-15 01:23:52 +06:00
1dbb0e669d started 0.23.3 2020-02-15 00:55:37 +06:00
723818f04f improve badge 2020-02-15 00:54:44 +06:00
0c107bc512 replace TelegramBotAPI to the separated subproject 2020-02-15 00:50:35 +06:00
945df1bc5f Add chat badge in README 2020-02-14 19:18:15 +06:00
239d740587 Make text in chat badge less 2020-02-14 19:15:36 +06:00
5fdcf252b2 Create chat.svg 2020-02-14 19:14:30 +06:00
a17ae07e50 InputMedia#media fix (version 0.23.2) 2020-02-14 12:06:54 +06:00
8bbfa2ee24 Create FUNDING.yml 2020-02-10 23:13:07 +06:00
4b908f9975 Now it is possible to send broadcast channels size for FlowsUpdatesFilter 2020-02-09 15:15:36 +06:00
542fcef6da optimize imports 2020-02-08 00:00:52 +06:00
0959c0b0d7 Merge pull request #64 from InsanusMokrassar/0.23.1
0.23.1
2020-02-07 23:12:13 +06:00
4f2a8e49bc Add maven version badge 2020-02-04 13:46:07 +06:00
0ce9080efc Add awesome badge due to merged PR in kotlin awesome
https://github.com/KotlinBy/awesome-kotlin/pull/526
2020-02-04 13:42:06 +06:00
991 changed files with 22968 additions and 11922 deletions

5
.github/FUNDING.yml vendored Normal file
View File

@@ -0,0 +1,5 @@
# These are supported funding model platforms
patreon: InsanusMokrassar
custom: ['https://paypal.me/InsanusMokrassar?locale.x=ru_RU']

10
.github/labeler.yml vendored Normal file
View File

@@ -0,0 +1,10 @@
api: "TelegramBotAPI-extensions-api/**"
utils: "TelegramBotAPI-extensions-utils/**"
core: "TelegramBotAPI/**" # currently not work
code: "**/*.kt"
gradle: "**/*.gradle"
versions: "**/gradle.properties"
markdown:
- "**/*.md"
- "!CHANGELOG.md"

2
.github/pull_request_template.md vendored Normal file
View File

@@ -0,0 +1,2 @@
* Please, be sure that you have read [Contributing](https://github.com/InsanusMokrassar/TelegramBotAPI/blob/master/CONTRIBUTING.md) file. Of course, this line must be removed during PR preparation :)
* Describe your changes, shortly. As example (or format) you can look at the body of any [Project releases](https://github.com/InsanusMokrassar/TelegramBotAPI/releases)

13
.github/workflows/greetings.yml vendored Normal file
View File

@@ -0,0 +1,13 @@
name: Greetings
on: [pull_request, issues]
jobs:
greeting:
runs-on: ubuntu-latest
steps:
- uses: actions/first-interaction@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
issue-message: 'Welcome with your first issue'
pr-message: 'Welcome with your first PullRequest'

18
.github/workflows/label.yml vendored Normal file
View File

@@ -0,0 +1,18 @@
# This workflow will triage pull requests and apply a label based on the
# paths that are modified in the pull request.
#
# To use this workflow, you will need to set up a .github/labeler.yml
# file with configuration. For more information, see:
# https://github.com/actions/labeler/blob/master/README.md
name: "Pull Request Labeler"
on:
- pull_request
jobs:
triage:
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@v2
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"

1
.github/write-good.yml vendored Normal file
View File

@@ -0,0 +1 @@
spellchecker: true

3
.gitignore vendored
View File

@@ -8,3 +8,6 @@ settings.xml
.gradle/
build/
out/
local.properties
secret.gradle

15
.travis.yml Normal file
View File

@@ -0,0 +1,15 @@
language: java
install: true
os: linux
dist: trusty
jdk: oraclejdk8
jobs:
include:
- stage: build
script: ./gradlew build -s -x jvmTest -x jsIrTest -x jsIrBrowserTest -x jsIrNodeTest -x jsLegacyTest -x jsLegacyBrowserTest -x jsLegacyNodeTest
- state: test
script: ./gradlew allTests
- state: dokka
script: ./gradlew dokkaHtml

File diff suppressed because it is too large Load Diff

10
CONTRIBUTING.md Normal file
View File

@@ -0,0 +1,10 @@
# Contributing
In case you wish to contribute this project, there are several small things you must remember:
* Give maintainers opportunity to manage your Pull request. It is required for two reasons
* For more efficient Pull Requests handling (it is much easier for me to fix something small directly in your pull request than ask to fix some small things after each review)
* Usually, you will set as a target `master` branch, but I prefer to include code into separated version branch firstly. So, if you will give me opporunity to change Pull Request, I will be available to change base branch
* Currently in Pull Requests there are several bots. The most important is Travis bot and it must always successfuly build code from your Pull Request
This project was built on the idea of strongly-typed declaration of TelegramBotAPI. So, do not worry if maintaners will change your pull requests: you are already cool because you have contributed this project:)

View File

@@ -178,7 +178,7 @@
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "{}"
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
@@ -186,7 +186,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright 2018 Insanus
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.

313
README.md
View File

@@ -1,206 +1,149 @@
# TelegramBotAPI
[![Download](https://api.bintray.com/packages/insanusmokrassar/StandardRepository/TelegramBotAPI/images/download.svg) ](https://bintray.com/insanusmokrassar/StandardRepository/TelegramBotAPI/_latestVersion)
[![Build Status](https://jenkins.insanusmokrassar.com/buildStatus/icon?job=TelegramBotAPI_master__publishing)](https://jenkins.insanusmokrassar.com/job/TelegramBotAPI_master__publishing/)
<details>
<summary><b>I do not wanna read a lot, just give me my bot</b></summary>
You can simply use [this template](https://github.com/InsanusMokrassar/TelegramBotAPI-bot_template) (and button
`Use template`) to get your copy of bot and start to code.
**P.S. Do not forget to look into our [minidocs](https://bookstack.inmo.dev/books/telegrambotapi/) and
[kdocs](https://tgbotapi.inmo.dev/docs/index.html)**
</details>
| Common info | [![Awesome Kotlin Badge](https://kotlin.link/awesome-kotlin.svg)](https://github.com/KotlinBy/awesome-kotlin) [![Build Status](https://travis-ci.com/InsanusMokrassar/TelegramBotAPI.svg?branch=master)](https://travis-ci.com/InsanusMokrassar/TelegramBotAPI) [Small survey](https://forms.gle/2Hex2ynbHWHhi1KY7)|
| -------------------------------------:|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Useful links | [![Chat in Telegram](badges/chat.svg)](https://t.me/InMoTelegramBotAPI) [![Create bot](badges/template.svg)](https://github.com/InsanusMokrassar/TelegramBotAPI-bot_template/generate) [![KDocs](badges/kdocs.svg)](https://tgbotapi.inmo.dev/docs/index.html) [Examples](https://github.com/InsanusMokrassar/TelegramBotAPI-examples/), [Mini tutorial](https://bookstack.inmo.dev/books/telegrambotapi/chapter/introduction-tutorial) |
| TelegramBotAPI Core status | [![Download](https://api.bintray.com/packages/insanusmokrassar/TelegramBotAPI/tgbotapi.core/images/download.svg)](https://bintray.com/insanusmokrassar/TelegramBotAPI/tgbotapi.core/_latestVersion) [![Maven Central](https://maven-badges.herokuapp.com/maven-central/dev.inmo/tgbotapi.core/badge.svg)](https://maven-badges.herokuapp.com/maven-central/dev.inmo/tgbotapi.core) |
| TelegramBotAPI Extensions status | [![Download](https://api.bintray.com/packages/insanusmokrassar/TelegramBotAPI/tgbotapi.extensions.api/images/download.svg)](https://bintray.com/insanusmokrassar/TelegramBotAPI/tgbotapi.extensions.api/_latestVersion) [![Maven Central](https://maven-badges.herokuapp.com/maven-central/dev.inmo/tgbotapi.extensions.api/badge.svg)](https://maven-badges.herokuapp.com/maven-central/dev.inmo/tgbotapi.extensions.api) |
| TelegramBotAPI Util Extensions status | [![Download](https://api.bintray.com/packages/insanusmokrassar/TelegramBotAPI/tgbotapi.extensions.utils/images/download.svg)](https://bintray.com/insanusmokrassar/TelegramBotAPI/tgbotapi.extensions.utils/_latestVersion) [![Maven Central](https://maven-badges.herokuapp.com/maven-central/dev.inmo/tgbotapi.extensions.utils/badge.svg)](https://maven-badges.herokuapp.com/maven-central/dev.inmo/tgbotapi.extensions.utils) |
| TelegramBotAPI All status | [![Download](https://api.bintray.com/packages/insanusmokrassar/TelegramBotAPI/tgbotapi/images/download.svg)](https://bintray.com/insanusmokrassar/TelegramBotAPI/tgbotapi/_latestVersion) [![Maven Central](https://maven-badges.herokuapp.com/maven-central/dev.inmo/tgbotapi/badge.svg)](https://maven-badges.herokuapp.com/maven-central/dev.inmo/tgbotapi) |
**At the time of publication of version `0.28.0` there are errors in serialization plugins like
[kotlinx.serialization#1004](https://github.com/Kotlin/kotlinx.serialization/issues/1004). It is possible, that both JVM
and JS version may work improperly in some cases with `kotlinx.serialization` version `1.0.0-RC`**
## What is it?
Library for Object-Oriented and type-safe work with Telegram Bot API. Most part of some specific solves or unuseful
It is a complex of libraries for working with `TelegramBotAPI` in type-safe and strict way as much as it possible. In
the list of this complex currently next projects:
* [TelegramBotAPI Core](tgbotapi.core/README.md) - core of library. In fact it is independent library and can be used alone
without any additional library
* [TelegramBotAPI API Extensions](tgbotapi.extensions.api/README.md) - contains extensions (mostly for
`RequestsExecutor`), which allows to use the core library in more pleasant way
* [TelegramBotAPI Util Extensions](tgbotapi.extensions.utils/README.md) - contains extensions for more comfortable
work with commands, updates and other different things
* [TelegramBotAPI](tgbotapi/README.md) - concentration of all previously mentioned libraries
Most part of some specific solves or unuseful
moments are describing by official [Telegram Bot API](https://core.telegram.org/bots/api).
## Compatibility
## JavaScript notes
This version compatible with [23th of January 2020 update of TelegramBotAPI (version 4.6)](https://core.telegram.org/bots/api#january-23-2020).
There is Telegram Passport API exception of implemented functionality, which was presented in
[August 2018 update of TelegramBotAPI](https://core.telegram.org/bots/api-changelog#august-27-2018) update. It will be implemented
as soon as possible. All APIs that are not included are presented
[wiki](https://github.com/InsanusMokrassar/TelegramBotAPI/wiki/Not-included-API).
### Versions before `0.28.0`
## How to implement library?
In case if you are want to use this library inside of browser, you will need additional settings (thanks for help to [Alexander Nozik](https://research.jetbrains.org/researchers/altavir)):
Common ways to implement this library are presented here. In some cases it will require additional steps
like inserting of additional libraries (like `kotlin stdlib`). In the examples will be used variable
`telegrambotapi.version`, which must be set up by developer. Available versions are presented on
[bintray](https://bintray.com/insanusmokrassar/StandardRepository/TelegramBotAPI), next version is last published:
[![Download](https://api.bintray.com/packages/insanusmokrassar/StandardRepository/TelegramBotAPI/images/download.svg) ](https://bintray.com/insanusmokrassar/StandardRepository/TelegramBotAPI/_latestVersion)
Currently, last versions of library can be available from the Maven repository with errors (for the reason difficult in publishing
of signed artifacts in Bintray). You can:
* Use earlier version (available version you can find
[here](https://mvnrepository.com/artifact/com.github.insanusmokrassar/TelegramBotAPI))
* Add `jCenter` repository in build config
### Maven
Dependency config presented here:
```xml
<dependency>
<groupId>com.github.insanusmokrassar</groupId>
<artifactId>TelegramBotAPI</artifactId>
<version>${telegrambotapi.version}</version>
</dependency>
```
### Gradle
To use last versions you will need to add one line in repositories block of your `build.gradle`:
`jcenter()` or `mavenCentral()`
And add next line to your dependencies block:
```groovy
implementation "com.github.insanusmokrassar:TelegramBotAPI:$telegrambotapi_version"
```
or for old gradle:
```groovy
compile "com.github.insanusmokrassar:TelegramBotAPI:$telegrambotapi_version"
```
## How to work with library?
For now, this library have no some API god-object. Instead of this, this library has several
important objects:
* [RequestsExecutor](https://github.com/InsanusMokrassar/TelegramBotAPI/blob/master/src/commonMain/kotlin/com/github/insanusmokrassar/TelegramBotAPI/bot/RequestsExecutor.kt)
* [Requests](https://github.com/InsanusMokrassar/TelegramBotAPI/blob/master/src/commonMain/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests)
* [Types](https://github.com/InsanusMokrassar/TelegramBotAPI/blob/master/src/commonMain/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types)
### Types
Types declare different objects representation. For example, `Chat` for now represented as
interface and has several realisations:
* `PrivateChat`
* `GroupChat`
* `SupergroupChat`
* `ChannelChat`
Instead of common garbage with all information as in original [Chat](https://core.telegram.org/bots/api#chat),
here it was separated for more obvious difference between chats types and their possible content.
The same principle work with a lot of others things in this Telegram bot API.
### Requests
Requests usually are very simple objects, but some of them are using their own
build factories. For example, the next code show, how to get information about bot:
```kotlin
val requestsExecutor: RequestsExecutor = ...
requestsExecutor.execute(GetMe())
```
Or you can use new syntax:
```kotlin
val bot: RequestsExecutor = ...
bot.getMe()
```
The result type of [GetMe (and getMe extension)](https://github.com/InsanusMokrassar/TelegramBotAPI/blob/master/src/commonMain/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/GetMe.kt)
request is
[ExtendedBot](https://github.com/InsanusMokrassar/TelegramBotAPI/blob/master/src/commonMain/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/User.kt).
### RequestsExecutor
It is base object which can be used to execute requests in API. For now by default included Ktor
realisation of `RequestsExecutor`, but it is possible, that in future it will be extracted in separated
project. How to create `RequestsExecutor`:
```kotlin
val requestsExecutor = KtorRequestsExecutor(
TelegramAPIUrlsKeeper(TOKEN)
)
```
Here:
* `KtorRequestsExecutor` - default realisation with [ktor](https://ktor.io)
* `TelegramAPIUrlsKeeper` - special keeper, which you can save and use for getting files full urls (`resolveFileURL`
extension inside of `PathedFile.kt`)
* `TOKEN` is just a token of bot which was retrieved according to
[instruction](https://core.telegram.org/bots#3-how-do-i-create-a-bot).
By default, for JVM there is implemented `CIO` client engine, but there is not server engine. Both can be changed like
here:
<details>
<summary>Gradle build script help (for versions before 0.28.0)</summary>
```groovy
dependencies {
// ...
implementation "io.ktor:ktor-server-cio:$ktor_version" // for implementing of server engine
implementation "io.ktor:ktor-client-okhttp:$ktor_version" // for implementing of additional client engine
// ...
/* ... */
implementation "com.github.insanusmokrassar:TelegramBotAPI:$tgbot_api_version"
implementation "com.github.insanusmokrassar:TelegramBotAPI-extensions-api:$tgbot_api_version" // optional
implementation "com.github.insanusmokrassar:TelegramBotAPI-extensions-utils:$tgbot_api_version" // optional
/* Block of dependencies for correct building in browser */
implementation(npm("fs"))
implementation(npm("bufferutil"))
implementation(npm("utf-8-validate"))
implementation(npm("abort-controller"))
implementation(npm("text-encoding"))
}
/* ... */
kotlin {
target {
browser {
/* Block for fix of exception in absence of some functionality, https://github.com/ktorio/ktor/issues/1339 */
dceTask {
dceOptions {
keep("ktor-ktor-io.\$\$importsForInline\$\$.ktor-ktor-io.io.ktor.utils.io")
}
}
}
}
}
```
You can avoid using of `server` dependency in case if you will not use `Webhook`s. In this case,
dependencies list will be simplify:
</details>
## Ok, where should I start?
![Libraries hierarchy](resources/TelegramBotAPI-libraries-hierarchy.svg)
In most cases, the most simple way will be to implement [TelegramBotAPI](tgbotapi/README.md) - it contains
all necessary tools for comfort usage of this library. If you want to exclude some libraries, you can implement just
[TelegramBotAPI API Extensions](tgbotapi.extensions.api/README.md),
[TelegramBotAPI Util Extensions](tgbotapi.extensions.utils/README.md) or even
[TelegramBotAPI Core](tgbotapi.core/README.md).
If you want to dive deeper in the core of library or develop something for it - welcome to learn more from
[TelegramBotAPI Core](tgbotapi.core/README.md) and our [Telegram Chat](https://teleg.one/InMoTelegramBotAPIChat).
Anyway, all libraries are very typical inside of them. Examples:
* In `TelegramBotAPI` common request look like `requestsExecutor.execute(SomeRequest())`
* `tgbotapi.extensions.api` typical syntax look like `requestsExecutor.someRequest()` (in most cases it would be
better to use `bot` name instead of `requestsExecutor`)
* `tgbotapi.extensions.utils` will look like `filter.filterBaseMessageUpdates(chatId).filterExactCommands(Regex("^.*$"))...`
## Build instruction
If you want to build this project or to contribute, there are several recommendations:
### Build
In case if you want to just build project, run next command:
```bash
./gradlew clean build
```
On windows:
```
gradlew.bat clean build
```
### Publishing for work with your version locally
In case, if you want to work in your other projects using your modification (or some state) of this library,
you can use next code:
```bash
./gradlew clean build publishToMavenLocal
```
On windows:
```
gradlew.bat clean build publishToMavenLocal
```
But you must remember, that in this case your local maven repo must be the first one from
your project retrieving libraries:
```groovy
dependencies {
// ...
implementation "io.ktor:ktor-client-okhttp:$ktor_version" // for implementing of additional client engine
// ...
repositories {
mavenLocal() // that must be the first one
jcenter()
mavenCentral()
}
```
Here was used `okhttp` realisation of client, but there are several others engines for Ktor. More information
available on ktor.io site for [client](https://ktor.io/clients/http-client/engines.html) and [server](https://ktor.io/quickstart/artifacts.html)
engines.
## Getting updates
In this library currently realised two ways to get updates from telegram:
* Polling - in this case bot will request updates from time to time (you can set up delay between requests)
* Webhook via reverse proxy or something like this
### Updates filters
Currently webhook method contains `UpdatesFilter` as necessary argument for getting updates.
`UpdatesFilter` will sort updates and throw their into different callbacks. Currently supporting
separate getting updates for media groups - they are accumulating with debounce in one second
(for being sure that all objects of media group was received).
Updates polling also support `UpdatesFilter` but it is not required to use it and you can get updates directly
in `UpdateReceiver`, which you will provide to `startGettingOfUpdates` method
### Webhook set up
If you wish to use webhook method, you will need:
* White IP - your IP address or host, which available for calling. [TelegramBotAPI](https://core.telegram.org/bots/api#setwebhook)
recommend to use some unique address for each bot which you are using
* SSL certificate. Usually you can obtain the certificate using your domain provider, [Let'sEncrypt](https://letsencrypt.org/) or [create it](https://core.telegram.org/bots/self-signed)
* Nginx or something like this
Template for Nginx server config you can find in [this gist](https://gist.github.com/InsanusMokrassar/fcc6e09cebd07e46e8f0fdec234750c4#file-nginxssl-conf).
For webhook you can provide `File` with public part of certificate, `URL` where bot will be available and inner `PORT` which
will be used to start receiving of updates. Actually, you can skip passing of `File` when you have something like
nginx for proxy forwarding.
In case of using `nginx` with reverse-proxy config, setting up of Webhook will look like:
```kotlin
requestsExecutor.setWebhook(
WEBHOOK_URL,
INTERNAL_PORT,
filter,
ENGINE_FACTORY
)
```
Here:
* `WEBHOOK_URL` - the url which will be used by Telegram system to send updates
* `INTERNAL_PORT` - the port which will be used in bot for listening of updates
* `filter` - instance of [UpdatesFilter](https://github.com/InsanusMokrassar/TelegramBotAPI/blob/master/src/commonMain/kotlin/com/github/insanusmokrassar/TelegramBotAPI/updateshandlers/UpdatesFilter.kt),
which will be used to filter incoming updates
* `ENGINE_FACTORY` - used factory name, for example, `CIO` in case of usage `io.ktor:ktor-server-cio` as server engine
Besides, for your own version you can change variable `library_version` in the file [gradle.properties](./gradle.properties).

125
TelegramBotAPI.minder Normal file
View File

@@ -0,0 +1,125 @@
<?xml version="1.0"?>
<minder version="1.11.1">
<theme name="default" label="Default" index="-1"/>
<styles>
<style level="0" isset="true" branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="200" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true" connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
<style level="1" isset="true" branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="200" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true" connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
<style level="2" isset="true" branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="200" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true" connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
<style level="3" isset="true" branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="200" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true" connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
<style level="4" isset="true" branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="200" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true" connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
<style level="5" isset="true" branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="200" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true" connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
<style level="6" isset="true" branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="200" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true" connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
<style level="7" isset="true" branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="200" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true" connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
<style level="8" isset="true" branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="200" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true" connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
<style level="9" isset="true" branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="200" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true" connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
<style level="10" isset="true" branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="200" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true" connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
</styles>
<drawarea x="-320.56697591145837" y="-10.028254191080691" scale="0.75"/>
<images/>
<nodes>
<node id="0" posx="748.88964843749955" posy="119.42341613769531" width="472" height="168" side="top" fold="false" treesize="603" layout="Downwards" group="false">
<style branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="439" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true"/>
<nodename posx="764.88964843749955" posy="135.42341613769531" maxwidth="488.96484375">
<text data="tgbotapi.core&#10;&#10;Root project with API. It is not recommended to use its requests directly and better to use at least tgbotapi.extensions.api"/>
</nodename>
<nodenote></nodenote>
<nodes>
<node id="1" posx="781.88964843749955" posy="387.42341613769531" width="406" height="145" side="bottom" fold="false" treesize="603" color="#68b723" colorroot="true" layout="Downwards" group="false">
<style branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="none" nodewidth="394" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true"/>
<nodename posx="797.88964843749955" posy="403.42341613769531" maxwidth="419.451171875">
<text data="TelegramBotAPI extensions&#10;&#10;Family of projects which are fully based on TelegramBotAPI and extend its functionality"/>
</nodename>
<nodenote></nodenote>
<nodes>
<node id="2" posx="683.38964843749955" posy="632.42341613769531" width="296" height="191" side="bottom" fold="false" treesize="296" color="#68b723" colorroot="true" layout="Downwards" group="false">
<style branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="203" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true"/>
<nodename posx="699.38964843749955" posy="648.42341613769531" maxwidth="295.90315755208337">
<text data="tgbotapi.extensions.api&#10;&#10;Extensions project for make requests more look like in the Telegram Bot API and give opportunity to use it's easier"/>
</nodename>
<nodenote></nodenote>
</node>
<node id="3" posx="979.38964843749955" posy="632.42341613769531" width="307" height="168" side="bottom" fold="false" treesize="307" color="#68b723" colorroot="true" layout="Downwards" group="false">
<style branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="286" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true"/>
<nodename posx="995.38964843749955" posy="648.42341613769531" maxwidth="299.252197265625">
<text data="tgbotapi.extensions.utils&#10;&#10;Extensions project with utils things which will make easier different operations"/>
</nodename>
<nodenote></nodenote>
</node>
</nodes>
</node>
</nodes>
</node>
<node id="4" posx="815.52319335937455" posy="948.04447937011719" width="329" height="213" side="top" fold="false" treesize="329" layout="Downwards" group="false">
<style branchmargin="100" linktype="curved" linkwidth="5" linkarrow="true" linkdash="solid" nodeborder="bracket" nodewidth="388" nodeborderwidth="3" nodefill="false" nodemargin="11" nodepadding="5" nodefont="Roboto Mono 14" nodemarkup="true"/>
<nodename posx="831.52319335937455" posy="964.04447937011719" maxwidth="394.3671875">
<text data="tgbotapi&#10;&#10;Here included all available TelegramBotAPI libraries:&#13;&#10;&#13;&#10;* tgbotapi.core&#13;&#10;* tgbotapi.extensions.api&#13;&#10;* tgbotapi.extensions.utils">
<color>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="67" end="68" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="84" end="85" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
<range start="111" end="112" extra="rgb(255,0,0)"/>
</color>
</text>
</nodename>
<nodenote></nodenote>
</node>
</nodes>
<groups/>
<connections>
<connection from_id="2" to_id="4" drag_x="905.70642089843705" drag_y="891.23394775390625" color="#777777">
<style connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
<title></title>
<note></note>
</connection>
<connection from_id="3" to_id="4" drag_x="1056.456420898437" drag_y="885.48394775390625" color="#777777">
<style connectiondash="dotted" connectionlwidth="2" connectionarrow="fromto" connectionpadding="3" connectionfont="Sans 10" connectiontwidth="100"/>
<title></title>
<note></note>
</connection>
</connections>
<stickers/>
</minder>

20
badges/chat.svg Normal file
View File

@@ -0,0 +1,20 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="104" height="20">
<linearGradient id="b" x2="0" y2="100%">
<stop offset="0" stop-color="#bbb" stop-opacity=".1"/>
<stop offset="1" stop-opacity=".1"/>
</linearGradient>
<clipPath id="a">
<rect width="104" height="20" rx="3" fill="#fff"/>
</clipPath>
<g clip-path="url(#a)">
<path fill="#555" d="M0 0h65v20H0z"/>
<path fill="#007ec6" d="M35 0h69v20H35z"/>
<path fill="url(#b)" d="M0 0h104v20H0z"/>
</g>
<g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="110">
<text x="175" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)">Talk</text>
<text x="175" y="140" transform="scale(.1)">Talk</text>
<text x="690" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)">Telegram</text>
<text x="690" y="140" transform="scale(.1)">Telegram</text>
</g>
</svg>

After

Width:  |  Height:  |  Size: 1018 B

20
badges/kdocs.svg Normal file
View File

@@ -0,0 +1,20 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="104" height="20">
<linearGradient id="b" x2="0" y2="100%">
<stop offset="0" stop-color="#bbb" stop-opacity=".1"/>
<stop offset="1" stop-opacity=".1"/>
</linearGradient>
<clipPath id="a">
<rect width="104" height="20" rx="3" fill="#fff"/>
</clipPath>
<g clip-path="url(#a)">
<path fill="#555" d="M0 0h65v20H0z"/>
<path fill="#007ec6" d="M45 0h69v20H45z"/>
<path fill="url(#b)" d="M0 0h104v20H0z"/>
</g>
<g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="110">
<text x="225" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)">Open</text>
<text x="225" y="140" transform="scale(.1)">Open</text>
<text x="740" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)">KDocs</text>
<text x="740" y="140" transform="scale(.1)">KDocs</text>
</g>
</svg>

After

Width:  |  Height:  |  Size: 1012 B

20
badges/template.svg Normal file
View File

@@ -0,0 +1,20 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="104" height="20">
<linearGradient id="b" x2="0" y2="100%">
<stop offset="0" stop-color="#bbb" stop-opacity=".1"/>
<stop offset="1" stop-opacity=".1"/>
</linearGradient>
<clipPath id="a">
<rect width="104" height="20" rx="3" fill="#fff"/>
</clipPath>
<g clip-path="url(#a)">
<path fill="#555" d="M0 0h65v20H0z"/>
<path fill="#007ec6" d="M35 0h69v20H35z"/>
<path fill="url(#b)" d="M0 0h104v20H0z"/>
</g>
<g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="110">
<text x="175" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)">Bot</text>
<text x="175" y="140" transform="scale(.1)">Bot</text>
<text x="690" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)">Template</text>
<text x="690" y="140" transform="scale(.1)">Template</text>
</g>
</svg>

After

Width:  |  Height:  |  Size: 1016 B

View File

@@ -3,79 +3,45 @@ buildscript {
mavenLocal()
jcenter()
mavenCentral()
maven { url "https://plugins.gradle.org/m2/" }
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath "org.jetbrains.kotlin:kotlin-serialization:$kotlin_version"
classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:$gradle_bintray_plugin_version"
classpath "com.github.breadmoirai:github-release:$github_release_plugin_version"
}
}
plugins {
id "org.jetbrains.kotlin.multiplatform" version "$kotlin_version"
id "org.jetbrains.kotlin.plugin.serialization" version "$kotlin_version"
id "org.jetbrains.kotlin.multiplatform" version "$kotlin_version" apply false
id "org.jetbrains.kotlin.plugin.serialization" version "$kotlin_version" apply false
}
project.version = "0.23.1"
project.group = "com.github.insanusmokrassar"
private String getCurrentVersionChangelog() {
OutputStream changelogDataOS = new ByteArrayOutputStream()
exec {
standardOutput = changelogDataOS
commandLine './changelog_info_retriever', "$library_version", 'CHANGELOG.md'
}
apply from: "publish.gradle"
repositories {
mavenLocal()
jcenter()
mavenCentral()
maven { url "https://kotlin.bintray.com/kotlinx" }
return changelogDataOS.toString().trim()
}
kotlin {
jvm()
js()
if (new File(projectDir, "secret.gradle").exists()) {
apply from: './secret.gradle'
apply plugin: "com.github.breadmoirai.github-release"
sourceSets {
commonMain {
dependencies {
implementation kotlin('stdlib')
api "org.jetbrains.kotlinx:kotlinx-coroutines-core-common:$kotlin_coroutines_version"
api "org.jetbrains.kotlinx:kotlinx-serialization-runtime-common:$kotlin_serialisation_runtime_version"
githubRelease {
token "${project.property('GITHUB_RELEASE_TOKEN')}"
api "com.soywiz.korlibs.klock:klock:$klock_version"
api "com.benasher44:uuid:$uuid_version"
owner "InsanusMokrassar"
repo "TelegramBotAPI"
api "io.ktor:ktor-client-core:$ktor_version"
}
}
commonTest {
dependencies {
implementation kotlin('test-common')
implementation kotlin('test-annotations-common')
}
}
tagName "$library_version"
releaseName "$library_version"
targetCommitish "$library_version"
jvmMain {
dependencies {
api "org.jetbrains.kotlinx:kotlinx-serialization-runtime:$kotlin_serialisation_runtime_version"
api "io.ktor:ktor-client:$ktor_version"
api "io.ktor:ktor-server:$ktor_version"
api "io.ktor:ktor-server-host-common:$ktor_version"
api "io.ktor:ktor-client-cio:$ktor_version"
}
}
jvmTest {
dependencies {
implementation kotlin('test-junit')
}
}
jsMain {
dependencies {
api "org.jetbrains.kotlinx:kotlinx-serialization-runtime-js:$kotlin_serialisation_runtime_version"
api "org.jetbrains.kotlinx:kotlinx-coroutines-core-js:$kotlin_coroutines_version"
api "io.ktor:ktor-client-js:$ktor_version"
}
}
body getCurrentVersionChangelog()
}
}

24
changelog_info_retriever Executable file
View File

@@ -0,0 +1,24 @@
#!/bin/bash
function parse() {
version=$1
while IFS= read -r line && [ -z "`echo $line | grep -e "^#\+ $version"`" ]
do
: # do nothing
done
while IFS= read -r line && [ -z "`echo $line | grep -e "^#\+"`" ]
do
echo "$line"
done
}
version=$1
file=$2
if [ -n "$file" ]; then
parse $version < "$file"
else
parse $version
fi

92
docs/build.gradle Normal file
View File

@@ -0,0 +1,92 @@
buildscript {
repositories {
mavenLocal()
jcenter()
mavenCentral()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath "org.jetbrains.kotlin:kotlin-serialization:$kotlin_version"
classpath "org.jetbrains.dokka:dokka-gradle-plugin:$dokka_version"
}
}
plugins {
id "org.jetbrains.kotlin.multiplatform"
id "org.jetbrains.kotlin.plugin.serialization"
id "org.jetbrains.dokka" version "$dokka_version"
}
repositories {
mavenLocal()
jcenter()
mavenCentral()
}
kotlin {
jvm()
js(BOTH) {
browser()
nodejs()
}
sourceSets {
commonMain {
dependencies {
implementation kotlin('stdlib')
project.parent.subprojects.forEach {
if (it != project) {
api it
}
}
}
}
}
}
private List<SourceDirectorySet> findSourcesWithName(String... approximateNames) {
return parent.subprojects
.findAll { it != project }
.collectMany { it.kotlin.sourceSets }
.findAll { sourceSet -> approximateNames.any {
nameToFilter -> sourceSet.name.contains(nameToFilter)
}
}.collect { it.kotlin }
}
tasks.dokkaHtml {
switch (true) {
case project.hasProperty("DOKKA_PATH"):
outputDirectory = project.property("DOKKA_PATH").toString()
break
case System.getenv("DOKKA_PATH") != null:
outputDirectory = System.getenv("DOKKA_PATH")
break
}
dokkaSourceSets {
configureEach {
skipDeprecated.set(true)
sourceLink {
localDirectory.set(file("./"))
remoteUrl.set(new URL("https://github.com/InsanusMokrassar/TelegramBotAPI/blob/master/"))
remoteLineSuffix.set("#L")
}
}
named("commonMain") {
sourceRoots.setFrom(findSourcesWithName("commonMain"))
}
named("jsMain") {
sourceRoots.setFrom(findSourcesWithName("jsMain", "commonMain"))
}
named("jvmMain") {
sourceRoots.setFrom(findSourcesWithName("jvmMain", "commonMain"))
}
}
}

3
docs/gradle.properties Normal file
View File

@@ -0,0 +1,3 @@
dokka_version=1.4.0
org.gradle.jvmargs=-Xmx1024m

View File

@@ -1,9 +1,22 @@
org.gradle.jvmargs=-Xmx2048m
kotlin.code.style=official
kotlin_version=1.3.61
kotlin_coroutines_version=1.3.3
kotlin_serialisation_runtime_version=0.14.0
klock_version=1.8.7
uuid_version=0.0.7
ktor_version=1.3.1
org.gradle.parallel=true
kotlin.js.generate.externals=true
kotlin.incremental=true
kotlin.incremental.js=true
gradle_bintray_plugin_version=1.8.4
kotlin_version=1.4.20
kotlin_coroutines_version=1.4.1
kotlin_serialisation_runtime_version=1.0.1
klock_version=2.0.0
uuid_version=0.2.2
ktor_version=1.4.2
micro_utils_version=0.4.3
javax_activation_version=1.1.1
library_group=dev.inmo
library_version=0.30.8
github_release_plugin_version=2.2.12

View File

@@ -1,6 +1,5 @@
#Fri Nov 29 12:11:00 HKT 2019
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.0.1-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip

View File

@@ -1,57 +0,0 @@
apply plugin: 'maven-publish'
task javadocsJar(type: Jar) {
classifier = 'javadoc'
}
afterEvaluate {
project.publishing.publications.all {
// rename artifacts
groupId "${project.group}"
if (it.name.contains('kotlinMultiplatform')) {
artifactId = "${project.name}"
} else {
artifactId = "${project.name}-$name"
}
}
}
publishing {
publications.all {
artifact javadocsJar
pom.withXml {
asNode().children().last() + {
resolveStrategy = Closure.DELEGATE_FIRST
description "Library for Object-Oriented and type-safe work with Telegram Bot API"
name "Telegram Bot API"
url "https://insanusmokrassar.github.io/TelegramBotAPI"
scm {
developerConnection "scm:git:[fetch=]https://github.com/insanusmokrassar/TelegramBotAPI.git[push=]https://github.com/insanusmokrassar/TelegramBotAPI.git"
url "https://github.com/insanusmokrassar/TelegramBotAPI.git"
}
developers {
developer {
id "InsanusMokrassar"
name "Ovsiannikov Aleksei"
email "ovsyannikov.alexey95@gmail.com"
}
}
licenses {
license {
name "Apache Software License 2.0"
url "https://github.com/InsanusMokrassar/TelegramBotAPI/blob/master/LICENSE"
}
}
}
}
}
}

View File

@@ -1 +0,0 @@
{"bintrayConfig":{"repo":"StandardRepository","packageName":"${project.name}","packageVcs":"https://github.com/InsanusMokrassar/TelegramBotAPI"},"licenses":[{"id":"Apache-2.0","title":"Apache Software License 2.0","url":"https://github.com/InsanusMokrassar/TelegramBotAPI/blob/master/LICENSE"}],"mavenConfig":{"name":"Telegram Bot API","description":"Library for Object-Oriented and type-safe work with Telegram Bot API","url":"https://insanusmokrassar.github.io/TelegramBotAPI","vcsUrl":"https://github.com/insanusmokrassar/TelegramBotAPI.git","developers":[{"id":"InsanusMokrassar","name":"Ovsiannikov Aleksei","eMail":"ovsyannikov.alexey95@gmail.com"}]}}

View File

@@ -1,55 +0,0 @@
apply plugin: 'com.jfrog.bintray'
apply from: "maven.publish.gradle"
bintray {
user = project.hasProperty('BINTRAY_USER') ? project.property('BINTRAY_USER') : System.getenv('BINTRAY_USER')
key = project.hasProperty('BINTRAY_KEY') ? project.property('BINTRAY_KEY') : System.getenv('BINTRAY_KEY')
filesSpec {
from "${buildDir}/publications/"
eachFile {
String directorySubname = it.getFile().parentFile.name
if (it.getName() == "module.json") {
if (directorySubname == "kotlinMultiplatform") {
it.setPath("${project.name}/${project.version}/${project.name}-${project.version}.module")
} else {
it.setPath("${project.name}-${directorySubname}/${project.version}/${project.name}-${directorySubname}-${project.version}.module")
}
} else {
if (directorySubname == "kotlinMultiplatform" && it.getName() == "pom-default.xml") {
it.setPath("${project.name}/${project.version}/${project.name}-${project.version}.pom")
} else {
it.exclude()
}
}
}
into "${project.group}".replace(".", "/")
}
pkg {
repo = "StandardRepository"
name = "${project.name}"
vcsUrl = "https://github.com/InsanusMokrassar/TelegramBotAPI"
licenses = ["Apache-2.0"]
version {
name = "${project.version}"
released = new Date()
vcsTag = "${project.version}"
gpg {
sign = true
passphrase = project.hasProperty('signing.gnupg.passphrase') ? project.property('signing.gnupg.passphrase') : System.getenv('signing.gnupg.passphrase')
}
}
}
}
bintrayUpload.doFirst {
publications = publishing.publications.collect {
if (it.name.contains('kotlinMultiplatform')) {
null
} else {
it.name
}
} - null
}
bintrayUpload.dependsOn publishToMavenLocal

5
renovate.json Normal file
View File

@@ -0,0 +1,5 @@
{
"extends": [
"config:base"
]
}

View File

@@ -0,0 +1,811 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="623pt" height="1061pt" viewBox="0 0 623 1061" version="1.1">
<defs>
<g>
<symbol overflow="visible" id="glyph0-0">
<path style="stroke:none;" d=""/>
</symbol>
<symbol overflow="visible" id="glyph0-1">
<path style="stroke:none;" d="M 5.578125 -12.5 L 5.578125 -10 L 9.34375 -10 L 9.34375 -8.703125 L 5.578125 -8.703125 L 5.578125 -3.375 C 5.578125 -2.988281 5.625 -2.671875 5.71875 -2.421875 C 5.820312 -2.179688 5.957031 -1.984375 6.125 -1.828125 C 6.289062 -1.679688 6.484375 -1.578125 6.703125 -1.515625 C 6.929688 -1.460938 7.171875 -1.4375 7.421875 -1.4375 C 7.597656 -1.4375 7.785156 -1.445312 7.984375 -1.46875 C 8.179688 -1.488281 8.367188 -1.515625 8.546875 -1.546875 C 8.734375 -1.578125 8.90625 -1.609375 9.0625 -1.640625 C 9.226562 -1.679688 9.363281 -1.710938 9.46875 -1.734375 L 9.703125 -0.53125 C 9.566406 -0.445312 9.394531 -0.375 9.1875 -0.3125 C 8.988281 -0.25 8.769531 -0.191406 8.53125 -0.140625 C 8.300781 -0.0976562 8.050781 -0.0625 7.78125 -0.03125 C 7.519531 -0.0078125 7.257812 0 7 0 C 6.5625 0 6.148438 -0.0625 5.765625 -0.1875 C 5.390625 -0.3125 5.0625 -0.507812 4.78125 -0.78125 C 4.5 -1.050781 4.28125 -1.398438 4.125 -1.828125 C 3.96875 -2.253906 3.890625 -2.769531 3.890625 -3.375 L 3.890625 -8.703125 L 1.296875 -8.703125 L 1.296875 -10 L 3.890625 -10 L 3.890625 -12.5 Z M 5.578125 -12.5 "/>
</symbol>
<symbol overflow="visible" id="glyph0-2">
<path style="stroke:none;" d="M 1.28125 -5.078125 C 1.28125 -5.804688 1.367188 -6.46875 1.546875 -7.0625 C 1.722656 -7.664062 1.976562 -8.179688 2.3125 -8.609375 C 2.65625 -9.046875 3.070312 -9.382812 3.5625 -9.625 C 4.050781 -9.875 4.601562 -10 5.21875 -10 C 5.820312 -10 6.351562 -9.890625 6.8125 -9.671875 C 7.269531 -9.460938 7.660156 -9.15625 7.984375 -8.75 L 8.0625 -10 L 9.59375 -10 L 9.59375 -0.15625 C 9.59375 0.5 9.488281 1.082031 9.28125 1.59375 C 9.082031 2.113281 8.800781 2.550781 8.4375 2.90625 C 8.070312 3.269531 7.632812 3.539062 7.125 3.71875 C 6.613281 3.90625 6.046875 4 5.421875 4 C 5.171875 4 4.878906 3.96875 4.546875 3.90625 C 4.222656 3.851562 3.890625 3.757812 3.546875 3.625 C 3.210938 3.488281 2.890625 3.3125 2.578125 3.09375 C 2.265625 2.875 1.992188 2.597656 1.765625 2.265625 L 2.640625 1.125 C 2.847656 1.40625 3.0625 1.640625 3.28125 1.828125 C 3.5 2.023438 3.71875 2.179688 3.9375 2.296875 C 4.164062 2.421875 4.390625 2.507812 4.609375 2.5625 C 4.835938 2.613281 5.066406 2.640625 5.296875 2.640625 C 5.703125 2.640625 6.0625 2.578125 6.375 2.453125 C 6.695312 2.328125 6.972656 2.140625 7.203125 1.890625 C 7.429688 1.648438 7.601562 1.351562 7.71875 1 C 7.84375 0.644531 7.90625 0.234375 7.90625 -0.234375 L 7.90625 -1.15625 C 7.582031 -0.78125 7.195312 -0.492188 6.75 -0.296875 C 6.300781 -0.0976562 5.785156 0 5.203125 0 C 4.597656 0 4.050781 -0.125 3.5625 -0.375 C 3.070312 -0.625 2.660156 -0.96875 2.328125 -1.40625 C 1.992188 -1.851562 1.734375 -2.375 1.546875 -2.96875 C 1.367188 -3.5625 1.28125 -4.203125 1.28125 -4.890625 Z M 2.96875 -4.890625 C 2.96875 -4.421875 3.015625 -3.976562 3.109375 -3.5625 C 3.210938 -3.144531 3.367188 -2.773438 3.578125 -2.453125 C 3.796875 -2.140625 4.070312 -1.890625 4.40625 -1.703125 C 4.75 -1.523438 5.148438 -1.4375 5.609375 -1.4375 C 5.898438 -1.4375 6.160156 -1.46875 6.390625 -1.53125 C 6.628906 -1.601562 6.84375 -1.695312 7.03125 -1.8125 C 7.21875 -1.9375 7.382812 -2.082031 7.53125 -2.25 C 7.675781 -2.425781 7.800781 -2.617188 7.90625 -2.828125 L 7.90625 -7.21875 C 7.800781 -7.414062 7.675781 -7.597656 7.53125 -7.765625 C 7.382812 -7.929688 7.21875 -8.070312 7.03125 -8.1875 C 6.84375 -8.300781 6.628906 -8.394531 6.390625 -8.46875 C 6.160156 -8.539062 5.910156 -8.578125 5.640625 -8.578125 C 5.160156 -8.578125 4.75 -8.484375 4.40625 -8.296875 C 4.070312 -8.109375 3.796875 -7.851562 3.578125 -7.53125 C 3.367188 -7.207031 3.210938 -6.832031 3.109375 -6.40625 C 3.015625 -5.988281 2.96875 -5.546875 2.96875 -5.078125 Z M 2.96875 -4.890625 "/>
</symbol>
<symbol overflow="visible" id="glyph0-3">
<path style="stroke:none;" d="M 9.953125 -4.890625 C 9.953125 -4.203125 9.863281 -3.5625 9.6875 -2.96875 C 9.519531 -2.375 9.269531 -1.851562 8.9375 -1.40625 C 8.613281 -0.96875 8.207031 -0.625 7.71875 -0.375 C 7.238281 -0.125 6.6875 0 6.0625 0 C 5.425781 0 4.875 -0.113281 4.40625 -0.34375 C 3.945312 -0.570312 3.554688 -0.894531 3.234375 -1.3125 L 3.140625 0 L 1.59375 0 L 1.59375 -14 L 3.28125 -14 L 3.28125 -8.765625 C 3.601562 -9.160156 3.992188 -9.460938 4.453125 -9.671875 C 4.910156 -9.890625 5.441406 -10 6.046875 -10 C 6.679688 -10 7.238281 -9.875 7.71875 -9.625 C 8.207031 -9.382812 8.613281 -9.046875 8.9375 -8.609375 C 9.269531 -8.179688 9.519531 -7.664062 9.6875 -7.0625 C 9.863281 -6.46875 9.953125 -5.804688 9.953125 -5.078125 Z M 8.265625 -5.078125 C 8.265625 -5.546875 8.21875 -5.988281 8.125 -6.40625 C 8.03125 -6.832031 7.878906 -7.207031 7.671875 -7.53125 C 7.460938 -7.851562 7.191406 -8.109375 6.859375 -8.296875 C 6.523438 -8.484375 6.113281 -8.578125 5.625 -8.578125 C 5.332031 -8.578125 5.0625 -8.535156 4.8125 -8.453125 C 4.570312 -8.378906 4.359375 -8.273438 4.171875 -8.140625 C 3.984375 -8.015625 3.8125 -7.863281 3.65625 -7.6875 C 3.507812 -7.507812 3.382812 -7.316406 3.28125 -7.109375 L 3.28125 -2.921875 C 3.394531 -2.703125 3.523438 -2.503906 3.671875 -2.328125 C 3.816406 -2.148438 3.984375 -1.992188 4.171875 -1.859375 C 4.367188 -1.722656 4.585938 -1.617188 4.828125 -1.546875 C 5.078125 -1.472656 5.347656 -1.4375 5.640625 -1.4375 C 6.109375 -1.4375 6.503906 -1.523438 6.828125 -1.703125 C 7.160156 -1.890625 7.429688 -2.140625 7.640625 -2.453125 C 7.847656 -2.773438 8.003906 -3.144531 8.109375 -3.5625 C 8.210938 -3.976562 8.265625 -4.421875 8.265625 -4.890625 Z M 8.265625 -5.078125 "/>
</symbol>
<symbol overflow="visible" id="glyph0-4">
<path style="stroke:none;" d="M 1.109375 -5.09375 C 1.109375 -5.789062 1.210938 -6.4375 1.421875 -7.03125 C 1.628906 -7.625 1.925781 -8.140625 2.3125 -8.578125 C 2.695312 -9.023438 3.164062 -9.375 3.71875 -9.625 C 4.269531 -9.875 4.894531 -10 5.59375 -10 C 6.289062 -10 6.914062 -9.875 7.46875 -9.625 C 8.03125 -9.375 8.503906 -9.023438 8.890625 -8.578125 C 9.273438 -8.140625 9.566406 -7.625 9.765625 -7.03125 C 9.972656 -6.4375 10.078125 -5.789062 10.078125 -5.09375 L 10.078125 -4.890625 C 10.078125 -4.191406 9.972656 -3.546875 9.765625 -2.953125 C 9.566406 -2.367188 9.273438 -1.851562 8.890625 -1.40625 C 8.503906 -0.96875 8.03125 -0.625 7.46875 -0.375 C 6.914062 -0.125 6.296875 0 5.609375 0 C 4.910156 0 4.28125 -0.125 3.71875 -0.375 C 3.164062 -0.625 2.695312 -0.96875 2.3125 -1.40625 C 1.925781 -1.851562 1.628906 -2.367188 1.421875 -2.953125 C 1.210938 -3.546875 1.109375 -4.191406 1.109375 -4.890625 Z M 2.796875 -4.890625 C 2.796875 -4.421875 2.851562 -3.972656 2.96875 -3.546875 C 3.082031 -3.117188 3.253906 -2.742188 3.484375 -2.421875 C 3.722656 -2.097656 4.019531 -1.84375 4.375 -1.65625 C 4.726562 -1.46875 5.140625 -1.375 5.609375 -1.375 C 6.066406 -1.375 6.46875 -1.46875 6.8125 -1.65625 C 7.164062 -1.84375 7.457031 -2.097656 7.6875 -2.421875 C 7.925781 -2.742188 8.101562 -3.117188 8.21875 -3.546875 C 8.332031 -3.972656 8.390625 -4.421875 8.390625 -4.890625 L 8.390625 -5.09375 C 8.390625 -5.5625 8.332031 -6.007812 8.21875 -6.4375 C 8.101562 -6.863281 7.925781 -7.238281 7.6875 -7.5625 C 7.457031 -7.882812 7.164062 -8.140625 6.8125 -8.328125 C 6.46875 -8.523438 6.0625 -8.625 5.59375 -8.625 C 5.125 -8.625 4.710938 -8.523438 4.359375 -8.328125 C 4.015625 -8.140625 3.722656 -7.882812 3.484375 -7.5625 C 3.253906 -7.238281 3.082031 -6.863281 2.96875 -6.4375 C 2.851562 -6.007812 2.796875 -5.5625 2.796875 -5.09375 Z M 2.796875 -4.890625 "/>
</symbol>
<symbol overflow="visible" id="glyph0-5">
<path style="stroke:none;" d="M 8.0625 -0.1875 C 8 -0.3125 7.945312 -0.46875 7.90625 -0.65625 C 7.863281 -0.851562 7.835938 -1.054688 7.828125 -1.265625 C 7.648438 -1.085938 7.457031 -0.921875 7.25 -0.765625 C 7.039062 -0.617188 6.8125 -0.488281 6.5625 -0.375 C 6.3125 -0.257812 6.039062 -0.164062 5.75 -0.09375 C 5.46875 -0.03125 5.164062 0 4.84375 0 C 4.320312 0 3.847656 -0.0703125 3.421875 -0.21875 C 3.003906 -0.363281 2.644531 -0.5625 2.34375 -0.8125 C 2.050781 -1.070312 1.820312 -1.375 1.65625 -1.71875 C 1.5 -2.070312 1.421875 -2.445312 1.421875 -2.84375 C 1.421875 -3.375 1.523438 -3.835938 1.734375 -4.234375 C 1.953125 -4.628906 2.257812 -4.957031 2.65625 -5.21875 C 3.050781 -5.476562 3.523438 -5.671875 4.078125 -5.796875 C 4.640625 -5.929688 5.265625 -6 5.953125 -6 L 7.796875 -6 L 7.796875 -6.75 C 7.796875 -7.050781 7.738281 -7.316406 7.625 -7.546875 C 7.519531 -7.773438 7.363281 -7.96875 7.15625 -8.125 C 6.957031 -8.289062 6.710938 -8.414062 6.421875 -8.5 C 6.140625 -8.59375 5.820312 -8.640625 5.46875 -8.640625 C 5.125 -8.640625 4.820312 -8.597656 4.5625 -8.515625 C 4.300781 -8.429688 4.078125 -8.320312 3.890625 -8.1875 C 3.710938 -8.0625 3.570312 -7.90625 3.46875 -7.71875 C 3.363281 -7.53125 3.3125 -7.332031 3.3125 -7.125 L 1.625 -7.125 C 1.625 -7.476562 1.710938 -7.828125 1.890625 -8.171875 C 2.078125 -8.515625 2.335938 -8.816406 2.671875 -9.078125 C 3.015625 -9.347656 3.425781 -9.566406 3.90625 -9.734375 C 4.382812 -9.910156 4.929688 -10 5.546875 -10 C 6.109375 -10 6.628906 -9.929688 7.109375 -9.796875 C 7.585938 -9.660156 8 -9.457031 8.34375 -9.1875 C 8.695312 -8.925781 8.972656 -8.59375 9.171875 -8.1875 C 9.378906 -7.78125 9.484375 -7.304688 9.484375 -6.765625 L 9.484375 -2.296875 C 9.484375 -1.972656 9.515625 -1.628906 9.578125 -1.265625 C 9.640625 -0.910156 9.722656 -0.597656 9.828125 -0.328125 L 9.828125 -0.1875 Z M 5.09375 -1.46875 C 5.414062 -1.46875 5.71875 -1.503906 6 -1.578125 C 6.289062 -1.660156 6.550781 -1.769531 6.78125 -1.90625 C 7.019531 -2.039062 7.222656 -2.191406 7.390625 -2.359375 C 7.566406 -2.535156 7.703125 -2.71875 7.796875 -2.90625 L 7.796875 -4.8125 L 6.234375 -4.8125 C 5.242188 -4.8125 4.472656 -4.671875 3.921875 -4.390625 C 3.378906 -4.109375 3.109375 -3.671875 3.109375 -3.078125 C 3.109375 -2.847656 3.148438 -2.632812 3.234375 -2.4375 C 3.316406 -2.238281 3.4375 -2.066406 3.59375 -1.921875 C 3.757812 -1.773438 3.96875 -1.660156 4.21875 -1.578125 C 4.46875 -1.503906 4.757812 -1.46875 5.09375 -1.46875 Z M 5.09375 -1.46875 "/>
</symbol>
<symbol overflow="visible" id="glyph0-6">
<path style="stroke:none;" d="M 9.90625 -4.890625 C 9.90625 -4.203125 9.820312 -3.5625 9.65625 -2.96875 C 9.488281 -2.375 9.238281 -1.851562 8.90625 -1.40625 C 8.582031 -0.96875 8.175781 -0.625 7.6875 -0.375 C 7.207031 -0.125 6.65625 0 6.03125 0 C 5.4375 0 4.90625 -0.0976562 4.4375 -0.296875 C 3.976562 -0.492188 3.585938 -0.769531 3.265625 -1.125 L 3.265625 4 L 1.578125 4 L 1.578125 -10 L 3.125 -10 L 3.203125 -8.9375 C 3.523438 -9.28125 3.921875 -9.539062 4.390625 -9.71875 C 4.859375 -9.90625 5.398438 -10 6.015625 -10 C 6.640625 -10 7.195312 -9.875 7.6875 -9.625 C 8.175781 -9.382812 8.582031 -9.046875 8.90625 -8.609375 C 9.238281 -8.179688 9.488281 -7.664062 9.65625 -7.0625 C 9.820312 -6.46875 9.90625 -5.804688 9.90625 -5.078125 Z M 8.21875 -5.171875 C 8.21875 -5.648438 8.164062 -6.101562 8.0625 -6.53125 C 7.957031 -6.96875 7.789062 -7.351562 7.5625 -7.6875 C 7.34375 -8.019531 7.0625 -8.28125 6.71875 -8.46875 C 6.382812 -8.664062 5.976562 -8.765625 5.5 -8.765625 C 4.96875 -8.765625 4.515625 -8.640625 4.140625 -8.390625 C 3.773438 -8.140625 3.484375 -7.816406 3.265625 -7.421875 L 3.265625 -2.6875 C 3.484375 -2.300781 3.773438 -1.984375 4.140625 -1.734375 C 4.503906 -1.492188 4.96875 -1.375 5.53125 -1.375 C 6 -1.375 6.398438 -1.472656 6.734375 -1.671875 C 7.078125 -1.867188 7.359375 -2.132812 7.578125 -2.46875 C 7.796875 -2.800781 7.957031 -3.179688 8.0625 -3.609375 C 8.164062 -4.046875 8.21875 -4.503906 8.21875 -4.984375 Z M 8.21875 -5.171875 "/>
</symbol>
<symbol overflow="visible" id="glyph0-7">
<path style="stroke:none;" d="M 1.84375 -10 L 6.890625 -10 L 6.890625 -1.453125 L 10.109375 -1.453125 L 10.109375 0 L 1.84375 0 L 1.84375 -1.453125 L 5.203125 -1.453125 L 5.203125 -8.546875 L 1.84375 -8.546875 Z M 4.984375 -12 C 4.984375 -12.28125 5.066406 -12.515625 5.234375 -12.703125 C 5.398438 -12.898438 5.65625 -13 6 -13 C 6.332031 -13 6.582031 -12.898438 6.75 -12.703125 C 6.925781 -12.515625 7.015625 -12.28125 7.015625 -12 C 7.015625 -11.726562 6.925781 -11.5 6.75 -11.3125 C 6.582031 -11.132812 6.332031 -11.046875 6 -11.046875 C 5.65625 -11.046875 5.398438 -11.132812 5.234375 -11.3125 C 5.066406 -11.5 4.984375 -11.726562 4.984375 -12 Z M 4.984375 -12 "/>
</symbol>
<symbol overflow="visible" id="glyph0-8">
<path style="stroke:none;" d="M 4.515625 -1.265625 C 4.515625 -1.441406 4.546875 -1.609375 4.609375 -1.765625 C 4.671875 -1.921875 4.753906 -2.054688 4.859375 -2.171875 C 4.972656 -2.296875 5.109375 -2.390625 5.265625 -2.453125 C 5.429688 -2.523438 5.625 -2.5625 5.84375 -2.5625 C 6.0625 -2.5625 6.253906 -2.523438 6.421875 -2.453125 C 6.585938 -2.390625 6.726562 -2.296875 6.84375 -2.171875 C 6.957031 -2.054688 7.039062 -1.921875 7.09375 -1.765625 C 7.15625 -1.609375 7.1875 -1.441406 7.1875 -1.265625 C 7.1875 -1.085938 7.15625 -0.921875 7.09375 -0.765625 C 7.039062 -0.609375 6.957031 -0.472656 6.84375 -0.359375 C 6.726562 -0.242188 6.585938 -0.15625 6.421875 -0.09375 C 6.253906 -0.03125 6.0625 0 5.84375 0 C 5.625 0 5.429688 -0.03125 5.265625 -0.09375 C 5.109375 -0.15625 4.972656 -0.242188 4.859375 -0.359375 C 4.753906 -0.472656 4.671875 -0.609375 4.609375 -0.765625 C 4.546875 -0.921875 4.515625 -1.085938 4.515625 -1.265625 Z M 4.515625 -1.265625 "/>
</symbol>
<symbol overflow="visible" id="glyph0-9">
<path style="stroke:none;" d="M 5.9375 0 C 5.25 0 4.613281 -0.113281 4.03125 -0.34375 C 3.445312 -0.582031 2.945312 -0.910156 2.53125 -1.328125 C 2.125 -1.742188 1.804688 -2.238281 1.578125 -2.8125 C 1.347656 -3.382812 1.234375 -4 1.234375 -4.65625 L 1.234375 -5.046875 C 1.234375 -5.828125 1.359375 -6.519531 1.609375 -7.125 C 1.867188 -7.738281 2.207031 -8.257812 2.625 -8.6875 C 3.050781 -9.113281 3.53125 -9.4375 4.0625 -9.65625 C 4.601562 -9.882812 5.15625 -10 5.71875 -10 C 6.4375 -10 7.0625 -9.882812 7.59375 -9.65625 C 8.125 -9.425781 8.566406 -9.101562 8.921875 -8.6875 C 9.273438 -8.28125 9.535156 -7.796875 9.703125 -7.234375 C 9.878906 -6.679688 9.96875 -6.082031 9.96875 -5.4375 L 9.96875 -4.71875 L 2.921875 -4.71875 C 2.929688 -4.257812 3.015625 -3.828125 3.171875 -3.421875 C 3.328125 -3.015625 3.539062 -2.660156 3.8125 -2.359375 C 4.082031 -2.054688 4.40625 -1.816406 4.78125 -1.640625 C 5.164062 -1.460938 5.582031 -1.375 6.03125 -1.375 C 6.632812 -1.375 7.171875 -1.5 7.640625 -1.75 C 8.109375 -2.007812 8.5 -2.34375 8.8125 -2.75 L 9.84375 -1.921875 C 9.675781 -1.671875 9.46875 -1.425781 9.21875 -1.1875 C 8.976562 -0.957031 8.695312 -0.753906 8.375 -0.578125 C 8.050781 -0.410156 7.6875 -0.269531 7.28125 -0.15625 C 6.875 -0.0507812 6.425781 0 5.9375 0 Z M 5.71875 -8.625 C 5.382812 -8.625 5.0625 -8.566406 4.75 -8.453125 C 4.445312 -8.335938 4.175781 -8.171875 3.9375 -7.953125 C 3.695312 -7.742188 3.492188 -7.484375 3.328125 -7.171875 C 3.160156 -6.859375 3.039062 -6.5 2.96875 -6.09375 L 8.28125 -6.09375 L 8.28125 -6.203125 C 8.257812 -6.492188 8.195312 -6.785156 8.09375 -7.078125 C 7.988281 -7.367188 7.832031 -7.628906 7.625 -7.859375 C 7.414062 -8.085938 7.15625 -8.269531 6.84375 -8.40625 C 6.53125 -8.550781 6.15625 -8.625 5.71875 -8.625 Z M 5.71875 -8.625 "/>
</symbol>
<symbol overflow="visible" id="glyph0-10">
<path style="stroke:none;" d="M 5.65625 -6.375 L 8.296875 -10 L 10.28125 -10 L 6.59375 -5.0625 L 10.375 0 L 8.421875 0 L 5.703125 -3.8125 L 2.96875 0 L 1 0 L 4.78125 -5.0625 L 1.109375 -10 L 3.046875 -10 Z M 5.65625 -6.375 "/>
</symbol>
<symbol overflow="visible" id="glyph0-11">
<path style="stroke:none;" d="M 3.09375 -10 L 3.21875 -8.390625 C 3.570312 -8.898438 4.007812 -9.296875 4.53125 -9.578125 C 5.0625 -9.859375 5.648438 -10 6.296875 -10 C 6.804688 -10 7.269531 -9.925781 7.6875 -9.78125 C 8.113281 -9.632812 8.472656 -9.40625 8.765625 -9.09375 C 9.066406 -8.789062 9.296875 -8.398438 9.453125 -7.921875 C 9.617188 -7.453125 9.703125 -6.890625 9.703125 -6.234375 L 9.703125 0 L 8.015625 0 L 8.015625 -6.21875 C 8.015625 -6.644531 7.96875 -7.007812 7.875 -7.3125 C 7.78125 -7.625 7.632812 -7.875 7.4375 -8.0625 C 7.25 -8.25 7.015625 -8.382812 6.734375 -8.46875 C 6.460938 -8.550781 6.148438 -8.59375 5.796875 -8.59375 C 5.222656 -8.59375 4.722656 -8.453125 4.296875 -8.171875 C 3.867188 -7.890625 3.523438 -7.519531 3.265625 -7.0625 L 3.265625 0 L 1.59375 0 L 1.59375 -10 Z M 3.09375 -10 "/>
</symbol>
<symbol overflow="visible" id="glyph0-12">
<path style="stroke:none;" d="M 8.140625 -2.765625 C 8.140625 -2.960938 8.097656 -3.140625 8.015625 -3.296875 C 7.941406 -3.453125 7.8125 -3.59375 7.625 -3.71875 C 7.4375 -3.84375 7.1875 -3.960938 6.875 -4.078125 C 6.5625 -4.191406 6.175781 -4.289062 5.71875 -4.375 C 5.15625 -4.488281 4.640625 -4.625 4.171875 -4.78125 C 3.703125 -4.945312 3.300781 -5.140625 2.96875 -5.359375 C 2.644531 -5.578125 2.390625 -5.835938 2.203125 -6.140625 C 2.023438 -6.441406 1.9375 -6.789062 1.9375 -7.1875 C 1.9375 -7.570312 2.03125 -7.9375 2.21875 -8.28125 C 2.40625 -8.625 2.664062 -8.921875 3 -9.171875 C 3.34375 -9.429688 3.75 -9.632812 4.21875 -9.78125 C 4.695312 -9.925781 5.21875 -10 5.78125 -10 C 6.382812 -10 6.929688 -9.921875 7.421875 -9.765625 C 7.910156 -9.609375 8.320312 -9.390625 8.65625 -9.109375 C 9 -8.835938 9.265625 -8.519531 9.453125 -8.15625 C 9.640625 -7.789062 9.734375 -7.398438 9.734375 -6.984375 L 8.046875 -6.984375 C 8.046875 -7.179688 7.988281 -7.378906 7.875 -7.578125 C 7.769531 -7.773438 7.617188 -7.953125 7.421875 -8.109375 C 7.222656 -8.265625 6.984375 -8.390625 6.703125 -8.484375 C 6.429688 -8.578125 6.125 -8.625 5.78125 -8.625 C 5.425781 -8.625 5.113281 -8.582031 4.84375 -8.5 C 4.570312 -8.425781 4.34375 -8.320312 4.15625 -8.1875 C 3.976562 -8.0625 3.84375 -7.910156 3.75 -7.734375 C 3.664062 -7.566406 3.625 -7.390625 3.625 -7.203125 C 3.625 -7.015625 3.660156 -6.847656 3.734375 -6.703125 C 3.804688 -6.554688 3.929688 -6.421875 4.109375 -6.296875 C 4.285156 -6.179688 4.523438 -6.078125 4.828125 -5.984375 C 5.128906 -5.890625 5.507812 -5.796875 5.96875 -5.703125 C 6.582031 -5.578125 7.128906 -5.429688 7.609375 -5.265625 C 8.085938 -5.109375 8.488281 -4.914062 8.8125 -4.6875 C 9.144531 -4.457031 9.394531 -4.191406 9.5625 -3.890625 C 9.738281 -3.585938 9.828125 -3.238281 9.828125 -2.84375 C 9.828125 -2.414062 9.726562 -2.023438 9.53125 -1.671875 C 9.332031 -1.328125 9.054688 -1.03125 8.703125 -0.78125 C 8.347656 -0.53125 7.925781 -0.335938 7.4375 -0.203125 C 6.945312 -0.0664062 6.410156 0 5.828125 0 C 5.160156 0 4.5625 -0.0859375 4.03125 -0.265625 C 3.507812 -0.441406 3.066406 -0.675781 2.703125 -0.96875 C 2.347656 -1.257812 2.070312 -1.59375 1.875 -1.96875 C 1.6875 -2.351562 1.59375 -2.75 1.59375 -3.15625 L 3.28125 -3.15625 C 3.300781 -2.820312 3.390625 -2.539062 3.546875 -2.3125 C 3.710938 -2.082031 3.914062 -1.894531 4.15625 -1.75 C 4.394531 -1.613281 4.660156 -1.515625 4.953125 -1.453125 C 5.242188 -1.398438 5.535156 -1.375 5.828125 -1.375 C 6.535156 -1.375 7.09375 -1.5 7.5 -1.75 C 7.914062 -2 8.128906 -2.335938 8.140625 -2.765625 Z M 8.140625 -2.765625 "/>
</symbol>
<symbol overflow="visible" id="glyph0-13">
<path style="stroke:none;" d="M 8.890625 -5.703125 L 3.34375 -5.703125 L 3.34375 -1.421875 L 9.8125 -1.421875 L 9.8125 0 L 1.65625 0 L 1.65625 -13 L 9.734375 -13 L 9.734375 -11.5625 L 3.34375 -11.5625 L 3.34375 -7.109375 L 8.890625 -7.109375 Z M 8.890625 -5.703125 "/>
</symbol>
<symbol overflow="visible" id="glyph0-14">
<path style="stroke:none;" d=""/>
</symbol>
<symbol overflow="visible" id="glyph0-15">
<path style="stroke:none;" d="M 8.046875 -10 C 8.203125 -10 8.363281 -10 8.53125 -10 C 8.707031 -10 8.875 -9.988281 9.03125 -9.96875 C 9.1875 -9.945312 9.328125 -9.914062 9.453125 -9.875 C 9.585938 -9.84375 9.695312 -9.8125 9.78125 -9.78125 L 9.5625 -8.140625 C 9.226562 -8.210938 8.910156 -8.265625 8.609375 -8.296875 C 8.316406 -8.328125 8.007812 -8.34375 7.6875 -8.34375 C 6.90625 -8.34375 6.269531 -8.164062 5.78125 -7.8125 C 5.289062 -7.457031 4.929688 -6.957031 4.703125 -6.3125 L 4.703125 0 L 3 0 L 3 -10 L 4.609375 -10 L 4.6875 -8.265625 C 5.082031 -8.796875 5.5625 -9.21875 6.125 -9.53125 C 6.6875 -9.84375 7.328125 -10 8.046875 -10 Z M 8.046875 -10 "/>
</symbol>
<symbol overflow="visible" id="glyph0-16">
<path style="stroke:none;" d="M 2.71875 -10 L 7.703125 -10 L 7.703125 0.03125 C 7.703125 0.664062 7.613281 1.226562 7.4375 1.71875 C 7.269531 2.207031 7.019531 2.617188 6.6875 2.953125 C 6.351562 3.296875 5.945312 3.554688 5.46875 3.734375 C 5 3.910156 4.457031 4 3.84375 4 C 3.5 4 3.175781 4 2.875 4 C 2.570312 4 2.253906 3.957031 1.921875 3.875 L 2.046875 2.484375 C 2.148438 2.492188 2.28125 2.507812 2.4375 2.53125 C 2.59375 2.5625 2.75 2.578125 2.90625 2.578125 C 3.070312 2.578125 3.226562 2.578125 3.375 2.578125 C 3.519531 2.578125 3.640625 2.578125 3.734375 2.578125 C 4.046875 2.578125 4.34375 2.535156 4.625 2.453125 C 4.90625 2.367188 5.144531 2.226562 5.34375 2.03125 C 5.550781 1.832031 5.710938 1.570312 5.828125 1.25 C 5.953125 0.925781 6.015625 0.523438 6.015625 0.046875 L 6.015625 -8.546875 L 2.71875 -8.546875 Z M 5.78125 -12.015625 C 5.78125 -12.285156 5.859375 -12.515625 6.015625 -12.703125 C 6.179688 -12.898438 6.4375 -13 6.78125 -13 C 7.125 -13 7.378906 -12.898438 7.546875 -12.703125 C 7.710938 -12.515625 7.796875 -12.285156 7.796875 -12.015625 C 7.796875 -11.742188 7.710938 -11.515625 7.546875 -11.328125 C 7.378906 -11.140625 7.125 -11.046875 6.78125 -11.046875 C 6.4375 -11.046875 6.179688 -11.140625 6.015625 -11.328125 C 5.859375 -11.515625 5.78125 -11.742188 5.78125 -12.015625 Z M 5.78125 -12.015625 "/>
</symbol>
<symbol overflow="visible" id="glyph0-17">
<path style="stroke:none;" d="M 5.796875 -1.375 C 6.097656 -1.375 6.390625 -1.421875 6.671875 -1.515625 C 6.960938 -1.609375 7.21875 -1.738281 7.4375 -1.90625 C 7.664062 -2.070312 7.847656 -2.269531 7.984375 -2.5 C 8.128906 -2.726562 8.203125 -2.972656 8.203125 -3.234375 L 9.796875 -3.234375 C 9.796875 -2.804688 9.679688 -2.394531 9.453125 -2 C 9.234375 -1.613281 8.9375 -1.273438 8.5625 -0.984375 C 8.195312 -0.691406 7.773438 -0.453125 7.296875 -0.265625 C 6.816406 -0.0859375 6.316406 0 5.796875 0 C 5.046875 0 4.390625 -0.128906 3.828125 -0.390625 C 3.265625 -0.648438 2.796875 -1 2.421875 -1.4375 C 2.054688 -1.882812 1.773438 -2.394531 1.578125 -2.96875 C 1.390625 -3.550781 1.296875 -4.164062 1.296875 -4.8125 L 1.296875 -5.1875 C 1.296875 -5.832031 1.390625 -6.441406 1.578125 -7.015625 C 1.773438 -7.597656 2.054688 -8.109375 2.421875 -8.546875 C 2.796875 -8.992188 3.265625 -9.347656 3.828125 -9.609375 C 4.390625 -9.867188 5.046875 -10 5.796875 -10 C 6.378906 -10 6.910156 -9.910156 7.390625 -9.734375 C 7.878906 -9.554688 8.300781 -9.3125 8.65625 -9 C 9.019531 -8.6875 9.300781 -8.3125 9.5 -7.875 C 9.695312 -7.445312 9.796875 -6.988281 9.796875 -6.5 L 8.203125 -6.5 C 8.203125 -6.789062 8.140625 -7.0625 8.015625 -7.3125 C 7.890625 -7.570312 7.71875 -7.800781 7.5 -8 C 7.289062 -8.195312 7.035156 -8.347656 6.734375 -8.453125 C 6.441406 -8.566406 6.128906 -8.625 5.796875 -8.625 C 5.265625 -8.625 4.820312 -8.519531 4.46875 -8.3125 C 4.113281 -8.113281 3.828125 -7.847656 3.609375 -7.515625 C 3.390625 -7.191406 3.234375 -6.828125 3.140625 -6.421875 C 3.046875 -6.015625 3 -5.601562 3 -5.1875 L 3 -4.8125 C 3 -4.394531 3.046875 -3.976562 3.140625 -3.5625 C 3.234375 -3.15625 3.382812 -2.789062 3.59375 -2.46875 C 3.8125 -2.144531 4.097656 -1.878906 4.453125 -1.671875 C 4.816406 -1.472656 5.265625 -1.375 5.796875 -1.375 Z M 5.796875 -1.375 "/>
</symbol>
<symbol overflow="visible" id="glyph0-18">
<path style="stroke:none;" d="M 4.109375 0 L 4.109375 -8.703125 L 1.390625 -8.703125 L 1.390625 -10 L 4.109375 -10 L 4.109375 -10.640625 C 4.109375 -11.210938 4.195312 -11.710938 4.375 -12.140625 C 4.5625 -12.578125 4.820312 -12.941406 5.15625 -13.234375 C 5.5 -13.535156 5.90625 -13.757812 6.375 -13.90625 C 6.851562 -14.050781 7.382812 -14.125 7.96875 -14.125 C 8.363281 -14.125 8.75 -14.085938 9.125 -14.015625 C 9.507812 -13.953125 9.90625 -13.867188 10.3125 -13.765625 L 10.109375 -12.421875 C 9.859375 -12.492188 9.566406 -12.554688 9.234375 -12.609375 C 8.910156 -12.660156 8.554688 -12.6875 8.171875 -12.6875 C 7.390625 -12.6875 6.796875 -12.515625 6.390625 -12.171875 C 5.992188 -11.835938 5.796875 -11.316406 5.796875 -10.609375 L 5.796875 -10 L 9.59375 -10 L 9.59375 -8.703125 L 5.796875 -8.703125 L 5.796875 0 Z M 4.109375 0 "/>
</symbol>
<symbol overflow="visible" id="glyph0-19">
<path style="stroke:none;" d="M 2.359375 -10 L 2.40625 -8.90625 C 2.601562 -9.25 2.863281 -9.515625 3.1875 -9.703125 C 3.519531 -9.898438 3.914062 -10 4.375 -10 C 5.28125 -10 5.882812 -9.65625 6.1875 -8.96875 C 6.382812 -9.28125 6.640625 -9.53125 6.953125 -9.71875 C 7.273438 -9.90625 7.664062 -10 8.125 -10 C 8.84375 -10 9.394531 -9.773438 9.78125 -9.328125 C 10.175781 -8.890625 10.375 -8.222656 10.375 -7.328125 L 10.375 0 L 8.765625 0 L 8.765625 -7.359375 C 8.765625 -8.179688 8.382812 -8.59375 7.625 -8.59375 C 7.425781 -8.59375 7.253906 -8.5625 7.109375 -8.5 C 6.960938 -8.445312 6.835938 -8.375 6.734375 -8.28125 C 6.640625 -8.1875 6.566406 -8.078125 6.515625 -7.953125 C 6.460938 -7.835938 6.425781 -7.710938 6.40625 -7.578125 L 6.40625 0 L 4.8125 0 L 4.8125 -7.375 C 4.8125 -7.769531 4.722656 -8.070312 4.546875 -8.28125 C 4.367188 -8.488281 4.085938 -8.59375 3.703125 -8.59375 C 3.347656 -8.59375 3.070312 -8.519531 2.875 -8.375 C 2.6875 -8.238281 2.546875 -8.054688 2.453125 -7.828125 L 2.453125 0 L 0.84375 0 L 0.84375 -10 Z M 2.359375 -10 "/>
</symbol>
<symbol overflow="visible" id="glyph0-20">
<path style="stroke:none;" d="M 4.546875 -4.640625 L 3.296875 -3.453125 L 3.296875 0 L 1.609375 0 L 1.609375 -14 L 3.296875 -14 L 3.296875 -5.515625 L 4.40625 -6.71875 L 7.640625 -10 L 9.6875 -10 L 5.703125 -5.828125 L 10.296875 0 L 8.15625 0 Z M 4.546875 -4.640625 "/>
</symbol>
<symbol overflow="visible" id="glyph0-21">
<path style="stroke:none;" d="M 1.28125 -5.078125 C 1.28125 -5.804688 1.367188 -6.46875 1.546875 -7.0625 C 1.722656 -7.664062 1.976562 -8.179688 2.3125 -8.609375 C 2.65625 -9.046875 3.070312 -9.382812 3.5625 -9.625 C 4.0625 -9.875 4.628906 -10 5.265625 -10 C 5.847656 -10 6.359375 -9.898438 6.796875 -9.703125 C 7.242188 -9.503906 7.632812 -9.21875 7.96875 -8.84375 L 8.046875 -10 L 9.59375 -10 L 9.59375 4 L 7.90625 4 L 7.90625 -1.078125 C 7.570312 -0.734375 7.1875 -0.46875 6.75 -0.28125 C 6.3125 -0.09375 5.8125 0 5.25 0 C 4.613281 0 4.050781 -0.125 3.5625 -0.375 C 3.070312 -0.625 2.65625 -0.96875 2.3125 -1.40625 C 1.976562 -1.851562 1.722656 -2.375 1.546875 -2.96875 C 1.367188 -3.5625 1.28125 -4.203125 1.28125 -4.890625 Z M 2.96875 -4.890625 C 2.96875 -4.421875 3.019531 -3.972656 3.125 -3.546875 C 3.226562 -3.128906 3.390625 -2.757812 3.609375 -2.4375 C 3.828125 -2.113281 4.101562 -1.851562 4.4375 -1.65625 C 4.78125 -1.46875 5.1875 -1.375 5.65625 -1.375 C 6.195312 -1.375 6.648438 -1.492188 7.015625 -1.734375 C 7.378906 -1.972656 7.675781 -2.28125 7.90625 -2.65625 L 7.90625 -7.375 C 7.789062 -7.5625 7.65625 -7.726562 7.5 -7.875 C 7.351562 -8.019531 7.1875 -8.148438 7 -8.265625 C 6.820312 -8.378906 6.617188 -8.46875 6.390625 -8.53125 C 6.171875 -8.59375 5.929688 -8.625 5.671875 -8.625 C 5.203125 -8.625 4.796875 -8.523438 4.453125 -8.328125 C 4.117188 -8.128906 3.835938 -7.867188 3.609375 -7.546875 C 3.390625 -7.222656 3.226562 -6.847656 3.125 -6.421875 C 3.019531 -5.992188 2.96875 -5.546875 2.96875 -5.078125 Z M 2.96875 -4.890625 "/>
</symbol>
<symbol overflow="visible" id="glyph0-22">
<path style="stroke:none;" d="M 7.984375 -1.359375 C 7.660156 -0.867188 7.25 -0.519531 6.75 -0.3125 C 6.257812 -0.101562 5.691406 0 5.046875 0 C 4.535156 0 4.066406 -0.078125 3.640625 -0.234375 C 3.222656 -0.398438 2.863281 -0.648438 2.5625 -0.984375 C 2.269531 -1.328125 2.039062 -1.757812 1.875 -2.28125 C 1.71875 -2.8125 1.640625 -3.441406 1.640625 -4.171875 L 1.640625 -10 L 3.328125 -10 L 3.328125 -4.15625 C 3.328125 -3.625 3.367188 -3.179688 3.453125 -2.828125 C 3.535156 -2.472656 3.660156 -2.191406 3.828125 -1.984375 C 4.003906 -1.773438 4.210938 -1.628906 4.453125 -1.546875 C 4.703125 -1.460938 4.988281 -1.421875 5.3125 -1.421875 C 6 -1.421875 6.550781 -1.554688 6.96875 -1.828125 C 7.394531 -2.109375 7.710938 -2.488281 7.921875 -2.96875 L 7.921875 -10 L 9.625 -10 L 9.625 0 L 8.09375 0 Z M 7.984375 -1.359375 "/>
</symbol>
<symbol overflow="visible" id="glyph0-23">
<path style="stroke:none;" d="M 1.84375 -14 L 6.890625 -14 L 6.890625 -1.453125 L 10.109375 -1.453125 L 10.109375 0 L 1.84375 0 L 1.84375 -1.453125 L 5.203125 -1.453125 L 5.203125 -12.546875 L 1.84375 -12.546875 Z M 1.84375 -14 "/>
</symbol>
<symbol overflow="visible" id="glyph0-24">
<path style="stroke:none;" d="M 3.265625 -8.375 C 3.617188 -8.882812 4.054688 -9.28125 4.578125 -9.5625 C 5.097656 -9.851562 5.675781 -10 6.3125 -10 C 6.832031 -10 7.300781 -9.925781 7.71875 -9.78125 C 8.144531 -9.632812 8.503906 -9.398438 8.796875 -9.078125 C 9.097656 -8.765625 9.328125 -8.367188 9.484375 -7.890625 C 9.648438 -7.410156 9.734375 -6.84375 9.734375 -6.1875 L 9.734375 0 L 8.046875 0 L 8.046875 -6.21875 C 8.046875 -7.019531 7.851562 -7.613281 7.46875 -8 C 7.082031 -8.394531 6.53125 -8.59375 5.8125 -8.59375 C 5.269531 -8.59375 4.78125 -8.457031 4.34375 -8.1875 C 3.90625 -7.925781 3.546875 -7.578125 3.265625 -7.140625 L 3.265625 0 L 1.59375 0 L 1.59375 -14 L 3.265625 -14 Z M 3.265625 -8.375 "/>
</symbol>
<symbol overflow="visible" id="glyph0-25">
<path style="stroke:none;" d="M 10.546875 -11.5625 L 6.4375 -11.5625 L 6.4375 0 L 4.796875 0 L 4.796875 -11.5625 L 0.6875 -11.5625 L 0.6875 -13 L 10.546875 -13 Z M 10.546875 -11.5625 "/>
</symbol>
<symbol overflow="visible" id="glyph0-26">
<path style="stroke:none;" d="M 1.5625 0 L 1.5625 -13 L 5.515625 -13 C 6.066406 -13 6.601562 -12.925781 7.125 -12.78125 C 7.644531 -12.644531 8.109375 -12.425781 8.515625 -12.125 C 8.921875 -11.832031 9.242188 -11.457031 9.484375 -11 C 9.734375 -10.539062 9.851562 -9.984375 9.84375 -9.328125 C 9.84375 -8.972656 9.785156 -8.648438 9.671875 -8.359375 C 9.566406 -8.066406 9.421875 -7.800781 9.234375 -7.5625 C 9.054688 -7.320312 8.84375 -7.109375 8.59375 -6.921875 C 8.34375 -6.742188 8.078125 -6.597656 7.796875 -6.484375 C 8.148438 -6.390625 8.472656 -6.25 8.765625 -6.0625 C 9.054688 -5.882812 9.304688 -5.671875 9.515625 -5.421875 C 9.734375 -5.171875 9.898438 -4.890625 10.015625 -4.578125 C 10.140625 -4.265625 10.203125 -3.921875 10.203125 -3.546875 C 10.210938 -2.972656 10.09375 -2.460938 9.84375 -2.015625 C 9.601562 -1.578125 9.28125 -1.207031 8.875 -0.90625 C 8.46875 -0.613281 8 -0.390625 7.46875 -0.234375 C 6.9375 -0.078125 6.382812 0 5.8125 0 Z M 3.265625 -5.703125 L 3.265625 -1.421875 L 5.859375 -1.421875 C 6.210938 -1.421875 6.546875 -1.46875 6.859375 -1.5625 C 7.179688 -1.664062 7.460938 -1.804688 7.703125 -1.984375 C 7.941406 -2.171875 8.132812 -2.394531 8.28125 -2.65625 C 8.425781 -2.914062 8.5 -3.21875 8.5 -3.5625 C 8.5 -3.90625 8.429688 -4.207031 8.296875 -4.46875 C 8.171875 -4.726562 7.992188 -4.945312 7.765625 -5.125 C 7.535156 -5.3125 7.265625 -5.453125 6.953125 -5.546875 C 6.640625 -5.648438 6.304688 -5.703125 5.953125 -5.703125 Z M 3.265625 -7.109375 L 5.609375 -7.109375 C 5.929688 -7.109375 6.242188 -7.15625 6.546875 -7.25 C 6.847656 -7.351562 7.117188 -7.5 7.359375 -7.6875 C 7.597656 -7.882812 7.789062 -8.117188 7.9375 -8.390625 C 8.082031 -8.671875 8.15625 -8.992188 8.15625 -9.359375 C 8.15625 -9.742188 8.082031 -10.078125 7.9375 -10.359375 C 7.789062 -10.640625 7.597656 -10.867188 7.359375 -11.046875 C 7.117188 -11.222656 6.84375 -11.351562 6.53125 -11.4375 C 6.21875 -11.519531 5.898438 -11.5625 5.578125 -11.5625 L 3.265625 -11.5625 Z M 3.265625 -7.109375 "/>
</symbol>
<symbol overflow="visible" id="glyph0-27">
<path style="stroke:none;" d="M 7.921875 -3.6875 L 3.484375 -3.6875 L 2.421875 0 L 0.734375 0 L 5.03125 -13 L 6.4375 -13 L 10.65625 0 L 8.96875 0 Z M 3.953125 -5.125 L 7.46875 -5.125 L 5.71875 -10.546875 Z M 3.953125 -5.125 "/>
</symbol>
<symbol overflow="visible" id="glyph0-28">
<path style="stroke:none;" d="M 3.421875 -5.71875 L 3.421875 0 L 1.734375 0 L 1.734375 -13 L 6.046875 -13 C 6.640625 -13 7.203125 -12.914062 7.734375 -12.75 C 8.265625 -12.59375 8.726562 -12.359375 9.125 -12.046875 C 9.53125 -11.742188 9.847656 -11.363281 10.078125 -10.90625 C 10.316406 -10.457031 10.4375 -9.941406 10.4375 -9.359375 C 10.4375 -8.773438 10.316406 -8.253906 10.078125 -7.796875 C 9.847656 -7.347656 9.53125 -6.96875 9.125 -6.65625 C 8.726562 -6.351562 8.265625 -6.117188 7.734375 -5.953125 C 7.203125 -5.796875 6.640625 -5.71875 6.046875 -5.71875 Z M 3.421875 -7.09375 L 6.046875 -7.09375 C 6.429688 -7.09375 6.785156 -7.144531 7.109375 -7.25 C 7.441406 -7.351562 7.726562 -7.5 7.96875 -7.6875 C 8.21875 -7.882812 8.410156 -8.117188 8.546875 -8.390625 C 8.679688 -8.660156 8.75 -8.976562 8.75 -9.34375 C 8.75 -9.6875 8.679688 -10 8.546875 -10.28125 C 8.410156 -10.570312 8.222656 -10.816406 7.984375 -11.015625 C 7.742188 -11.210938 7.457031 -11.363281 7.125 -11.46875 C 6.789062 -11.570312 6.429688 -11.625 6.046875 -11.625 L 3.421875 -11.625 Z M 3.421875 -7.09375 "/>
</symbol>
<symbol overflow="visible" id="glyph0-29">
<path style="stroke:none;" d="M 1.59375 -13 L 9.609375 -13 L 9.609375 -11.53125 L 6.421875 -11.53125 L 6.421875 -1.453125 L 9.609375 -1.453125 L 9.609375 0 L 1.59375 0 L 1.59375 -1.453125 L 4.703125 -1.453125 L 4.703125 -11.53125 L 1.59375 -11.53125 Z M 1.59375 -13 "/>
</symbol>
<symbol overflow="visible" id="glyph0-30">
<path style="stroke:none;" d="M 1.265625 -5.078125 C 1.265625 -5.804688 1.359375 -6.46875 1.546875 -7.0625 C 1.734375 -7.664062 2 -8.179688 2.34375 -8.609375 C 2.6875 -9.046875 3.097656 -9.382812 3.578125 -9.625 C 4.066406 -9.875 4.613281 -10 5.21875 -10 C 5.800781 -10 6.3125 -9.898438 6.75 -9.703125 C 7.195312 -9.503906 7.582031 -9.21875 7.90625 -8.84375 L 7.90625 -14 L 9.59375 -14 L 9.59375 0 L 8.046875 0 L 7.96875 -1.046875 C 7.632812 -0.703125 7.238281 -0.441406 6.78125 -0.265625 C 6.332031 -0.0859375 5.804688 0 5.203125 0 C 4.597656 0 4.054688 -0.125 3.578125 -0.375 C 3.097656 -0.625 2.6875 -0.96875 2.34375 -1.40625 C 2 -1.851562 1.734375 -2.375 1.546875 -2.96875 C 1.359375 -3.5625 1.265625 -4.203125 1.265625 -4.890625 Z M 2.953125 -4.796875 C 2.953125 -4.316406 3.003906 -3.863281 3.109375 -3.4375 C 3.210938 -3.007812 3.367188 -2.628906 3.578125 -2.296875 C 3.796875 -1.972656 4.070312 -1.71875 4.40625 -1.53125 C 4.75 -1.34375 5.148438 -1.25 5.609375 -1.25 C 5.898438 -1.25 6.160156 -1.28125 6.390625 -1.34375 C 6.617188 -1.40625 6.828125 -1.5 7.015625 -1.625 C 7.203125 -1.75 7.367188 -1.894531 7.515625 -2.0625 C 7.660156 -2.238281 7.789062 -2.4375 7.90625 -2.65625 L 7.90625 -7.203125 C 7.6875 -7.597656 7.390625 -7.925781 7.015625 -8.1875 C 6.648438 -8.445312 6.191406 -8.578125 5.640625 -8.578125 C 5.160156 -8.578125 4.75 -8.476562 4.40625 -8.28125 C 4.070312 -8.09375 3.796875 -7.832031 3.578125 -7.5 C 3.367188 -7.164062 3.210938 -6.78125 3.109375 -6.34375 C 3.003906 -5.914062 2.953125 -5.460938 2.953125 -4.984375 Z M 2.953125 -4.796875 "/>
</symbol>
<symbol overflow="visible" id="glyph0-31">
<path style="stroke:none;" d="M 5.453125 -2.453125 L 5.609375 -1.84375 L 5.765625 -2.453125 L 8.53125 -10 L 10.25 -10 L 6.234375 0 L 4.953125 0 L 0.890625 -10 L 2.625 -10 Z M 5.453125 -2.453125 "/>
</symbol>
<symbol overflow="visible" id="glyph0-32">
<path style="stroke:none;" d="M 5.21875 -3.546875 L 5.65625 -2.34375 L 8.65625 -10 L 10.546875 -10 L 5.546875 1.515625 C 5.429688 1.765625 5.28125 2.035156 5.09375 2.328125 C 4.914062 2.617188 4.695312 2.882812 4.4375 3.125 C 4.1875 3.363281 3.890625 3.566406 3.546875 3.734375 C 3.210938 3.910156 2.820312 4 2.375 4 C 2.300781 4 2.210938 4 2.109375 4 C 2.015625 4 1.914062 3.988281 1.8125 3.96875 C 1.71875 3.957031 1.628906 3.941406 1.546875 3.921875 C 1.460938 3.910156 1.394531 3.898438 1.34375 3.890625 L 1.609375 2.5 C 1.648438 2.5 1.707031 2.5 1.78125 2.5 C 1.851562 2.5 1.929688 2.5 2.015625 2.5 C 2.097656 2.5 2.175781 2.5 2.25 2.5 C 2.320312 2.5 2.378906 2.5 2.421875 2.5 C 2.648438 2.5 2.859375 2.429688 3.046875 2.296875 C 3.242188 2.171875 3.414062 2.019531 3.5625 1.84375 C 3.707031 1.675781 3.832031 1.5 3.9375 1.3125 C 4.050781 1.125 4.132812 0.96875 4.1875 0.84375 L 4.875 -0.46875 L 0.625 -10 L 2.5 -10 Z M 5.21875 -3.546875 "/>
</symbol>
<symbol overflow="visible" id="glyph0-33">
<path style="stroke:none;" d="M 5.953125 -13 L 5.765625 -9.65625 L 4.5 -9.65625 L 4.515625 -12.84375 L 4.515625 -14 L 5.953125 -14 Z M 5.953125 -13 "/>
</symbol>
<symbol overflow="visible" id="glyph0-34">
<path style="stroke:none;" d="M 3.078125 -3.625 L 3.28125 -2.1875 L 3.53125 -3.625 L 5.109375 -10 L 6.1875 -10 L 7.765625 -3.625 L 8.015625 -2.046875 L 8.265625 -3.625 L 9.359375 -10 L 10.859375 -10 L 8.765625 0 L 7.4375 0 L 5.890625 -6.125 L 5.640625 -7.6875 L 5.390625 -6.125 L 3.859375 0 L 2.53125 0 L 0.4375 -10 L 1.9375 -10 Z M 3.078125 -3.625 "/>
</symbol>
<symbol overflow="visible" id="glyph0-35">
<path style="stroke:none;" d="M 8.96875 -5.6875 L 3.453125 -5.6875 L 3.453125 0 L 1.734375 0 L 1.734375 -13 L 9.890625 -13 L 9.890625 -11.5625 L 3.453125 -11.5625 L 3.453125 -7.125 L 8.96875 -7.125 Z M 8.96875 -5.6875 "/>
</symbol>
<symbol overflow="visible" id="glyph0-36">
<path style="stroke:none;" d="M 5.984375 -5.71875 L 3.328125 -5.71875 L 3.328125 0 L 1.65625 0 L 1.65625 -13 L 5.546875 -13 C 6.160156 -13 6.738281 -12.921875 7.28125 -12.765625 C 7.832031 -12.617188 8.3125 -12.394531 8.71875 -12.09375 C 9.132812 -11.789062 9.457031 -11.410156 9.6875 -10.953125 C 9.925781 -10.492188 10.046875 -9.953125 10.046875 -9.328125 C 10.046875 -8.929688 9.984375 -8.566406 9.859375 -8.234375 C 9.734375 -7.898438 9.5625 -7.597656 9.34375 -7.328125 C 9.125 -7.054688 8.863281 -6.816406 8.5625 -6.609375 C 8.257812 -6.398438 7.925781 -6.222656 7.5625 -6.078125 L 10.375 0 L 8.59375 0 Z M 3.328125 -7.09375 L 5.59375 -7.09375 C 5.96875 -7.09375 6.320312 -7.140625 6.65625 -7.234375 C 6.988281 -7.335938 7.28125 -7.484375 7.53125 -7.671875 C 7.78125 -7.867188 7.976562 -8.101562 8.125 -8.375 C 8.269531 -8.65625 8.34375 -8.972656 8.34375 -9.328125 C 8.34375 -9.710938 8.273438 -10.046875 8.140625 -10.328125 C 8.003906 -10.609375 7.8125 -10.84375 7.5625 -11.03125 C 7.3125 -11.226562 7.015625 -11.375 6.671875 -11.46875 C 6.328125 -11.570312 5.953125 -11.625 5.546875 -11.625 L 3.328125 -11.625 Z M 3.328125 -7.09375 "/>
</symbol>
<symbol overflow="visible" id="glyph0-37">
<path style="stroke:none;" d="M 9.90625 0 L 8.3125 0 L 8.3125 -5.703125 L 2.875 -5.703125 L 2.875 0 L 1.28125 0 L 1.28125 -13 L 2.875 -13 L 2.875 -7.109375 L 8.3125 -7.109375 L 8.3125 -13 L 9.90625 -13 Z M 9.90625 0 "/>
</symbol>
<symbol overflow="visible" id="glyph0-38">
<path style="stroke:none;" d="M 4.984375 -1.265625 C 4.984375 -1.441406 5.007812 -1.609375 5.0625 -1.765625 C 5.125 -1.921875 5.207031 -2.054688 5.3125 -2.171875 C 5.425781 -2.296875 5.5625 -2.390625 5.71875 -2.453125 C 5.882812 -2.523438 6.078125 -2.5625 6.296875 -2.5625 C 6.515625 -2.5625 6.707031 -2.523438 6.875 -2.453125 C 7.039062 -2.390625 7.179688 -2.296875 7.296875 -2.171875 C 7.410156 -2.054688 7.492188 -1.921875 7.546875 -1.765625 C 7.609375 -1.609375 7.640625 -1.441406 7.640625 -1.265625 C 7.640625 -1.085938 7.609375 -0.921875 7.546875 -0.765625 C 7.492188 -0.609375 7.410156 -0.472656 7.296875 -0.359375 C 7.179688 -0.242188 7.039062 -0.15625 6.875 -0.09375 C 6.707031 -0.03125 6.515625 0 6.296875 0 C 6.078125 0 5.882812 -0.03125 5.71875 -0.09375 C 5.5625 -0.15625 5.425781 -0.242188 5.3125 -0.359375 C 5.207031 -0.472656 5.125 -0.609375 5.0625 -0.765625 C 5.007812 -0.921875 4.984375 -1.085938 4.984375 -1.265625 Z M 4.984375 -8.6875 C 4.984375 -8.875 5.007812 -9.046875 5.0625 -9.203125 C 5.125 -9.359375 5.207031 -9.492188 5.3125 -9.609375 C 5.425781 -9.734375 5.5625 -9.828125 5.71875 -9.890625 C 5.882812 -9.960938 6.078125 -10 6.296875 -10 C 6.515625 -10 6.707031 -9.960938 6.875 -9.890625 C 7.039062 -9.828125 7.179688 -9.734375 7.296875 -9.609375 C 7.410156 -9.492188 7.492188 -9.359375 7.546875 -9.203125 C 7.609375 -9.046875 7.640625 -8.875 7.640625 -8.6875 C 7.640625 -8.519531 7.609375 -8.359375 7.546875 -8.203125 C 7.492188 -8.046875 7.410156 -7.910156 7.296875 -7.796875 C 7.179688 -7.679688 7.039062 -7.59375 6.875 -7.53125 C 6.707031 -7.46875 6.515625 -7.4375 6.296875 -7.4375 C 6.078125 -7.4375 5.882812 -7.46875 5.71875 -7.53125 C 5.5625 -7.59375 5.425781 -7.679688 5.3125 -7.796875 C 5.207031 -7.910156 5.125 -8.046875 5.0625 -8.203125 C 5.007812 -8.359375 4.984375 -8.519531 4.984375 -8.6875 Z M 4.984375 -8.6875 "/>
</symbol>
<symbol overflow="visible" id="glyph0-39">
<path style="stroke:none;" d="M 4.890625 -6.09375 L 1.453125 -6.953125 L 1.953125 -8.546875 L 5.28125 -7.171875 L 5.046875 -11 L 6.671875 -11 L 6.40625 -7.125 L 9.71875 -8.484375 L 10.21875 -6.875 L 6.734375 -6.015625 L 9.0625 -3.078125 L 7.734375 -2.078125 L 5.78125 -5.375 L 3.84375 -2.15625 L 2.515625 -3.125 Z M 4.890625 -6.09375 "/>
</symbol>
</g>
</defs>
<g id="surface46506">
<path style="fill:none;stroke-width:5;stroke-linecap:round;stroke-linejoin:miter;stroke:rgb(40.784314%,71.764706%,13.72549%);stroke-opacity:1;stroke-miterlimit:10;" d="M 984.889648 203.423416 C 984.889648 298.423416 984.889648 298.423416 984.889648 393.423416 " transform="matrix(1,0,0,1,-673.389648,-109.423416)"/>
<path style="fill-rule:nonzero;fill:rgb(40.784314%,71.764706%,13.72549%);fill-opacity:1;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke:rgb(100%,100%,100%);stroke-opacity:1;stroke-miterlimit:10;" d="M 984.889648 396.423416 L 992.920898 384.954666 L 976.858398 384.954666 Z M 984.889648 396.423416 " transform="matrix(1,0,0,1,-673.389648,-109.423416)"/>
<path style="fill:none;stroke-width:5;stroke-linecap:round;stroke-linejoin:miter;stroke:rgb(40.784314%,71.764706%,13.72549%);stroke-opacity:1;stroke-miterlimit:10;" d="M 984.889648 521.423416 C 984.889648 579.923416 831.389648 579.923416 831.389648 638.423416 " transform="matrix(1,0,0,1,-673.389648,-109.423416)"/>
<path style="fill-rule:nonzero;fill:rgb(40.784314%,71.764706%,13.72549%);fill-opacity:1;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke:rgb(100%,100%,100%);stroke-opacity:1;stroke-miterlimit:10;" d="M 831.389648 641.423416 L 840.776367 631.036697 L 824.842773 629.048416 Z M 831.389648 641.423416 " transform="matrix(1,0,0,1,-673.389648,-109.423416)"/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 21 534 L 295 534 L 295 703 L 21 703 Z M 21 534 "/>
<path style="fill:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:miter;stroke:rgb(40.784314%,71.764706%,13.72549%);stroke-opacity:1;stroke-miterlimit:10;" d="M 694.389648 653.423416 L 694.389648 643.423416 L 968.389648 643.423416 L 968.389648 653.423416 " transform="matrix(1,0,0,1,-673.389648,-109.423416)"/>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-1" x="26" y="557"/>
<use xlink:href="#glyph0-2" x="37" y="557"/>
<use xlink:href="#glyph0-3" x="48" y="557"/>
<use xlink:href="#glyph0-4" x="59" y="557"/>
<use xlink:href="#glyph0-1" x="70" y="557"/>
<use xlink:href="#glyph0-5" x="81" y="557"/>
<use xlink:href="#glyph0-6" x="92" y="557"/>
<use xlink:href="#glyph0-7" x="103" y="557"/>
<use xlink:href="#glyph0-8" x="114" y="557"/>
<use xlink:href="#glyph0-9" x="125" y="557"/>
<use xlink:href="#glyph0-10" x="136" y="557"/>
<use xlink:href="#glyph0-1" x="147" y="557"/>
<use xlink:href="#glyph0-9" x="158" y="557"/>
<use xlink:href="#glyph0-11" x="169" y="557"/>
<use xlink:href="#glyph0-12" x="180" y="557"/>
<use xlink:href="#glyph0-7" x="191" y="557"/>
<use xlink:href="#glyph0-4" x="202" y="557"/>
<use xlink:href="#glyph0-11" x="213" y="557"/>
<use xlink:href="#glyph0-12" x="224" y="557"/>
<use xlink:href="#glyph0-8" x="235" y="557"/>
<use xlink:href="#glyph0-5" x="246" y="557"/>
<use xlink:href="#glyph0-6" x="257" y="557"/>
<use xlink:href="#glyph0-7" x="268" y="557"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-13" x="26" y="601.875977"/>
<use xlink:href="#glyph0-10" x="37" y="601.875977"/>
<use xlink:href="#glyph0-1" x="48" y="601.875977"/>
<use xlink:href="#glyph0-9" x="59" y="601.875977"/>
<use xlink:href="#glyph0-11" x="70" y="601.875977"/>
<use xlink:href="#glyph0-12" x="81" y="601.875977"/>
<use xlink:href="#glyph0-7" x="92" y="601.875977"/>
<use xlink:href="#glyph0-4" x="103" y="601.875977"/>
<use xlink:href="#glyph0-11" x="114" y="601.875977"/>
<use xlink:href="#glyph0-12" x="125" y="601.875977"/>
<use xlink:href="#glyph0-14" x="136" y="601.875977"/>
<use xlink:href="#glyph0-6" x="147" y="601.875977"/>
<use xlink:href="#glyph0-15" x="158" y="601.875977"/>
<use xlink:href="#glyph0-4" x="169" y="601.875977"/>
<use xlink:href="#glyph0-16" x="180" y="601.875977"/>
<use xlink:href="#glyph0-9" x="191" y="601.875977"/>
<use xlink:href="#glyph0-17" x="202" y="601.875977"/>
<use xlink:href="#glyph0-1" x="213" y="601.875977"/>
<use xlink:href="#glyph0-14" x="224" y="601.875977"/>
<use xlink:href="#glyph0-18" x="235" y="601.875977"/>
<use xlink:href="#glyph0-4" x="246" y="601.875977"/>
<use xlink:href="#glyph0-15" x="257" y="601.875977"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-19" x="26" y="624.875977"/>
<use xlink:href="#glyph0-5" x="37" y="624.875977"/>
<use xlink:href="#glyph0-20" x="48" y="624.875977"/>
<use xlink:href="#glyph0-9" x="59" y="624.875977"/>
<use xlink:href="#glyph0-14" x="70" y="624.875977"/>
<use xlink:href="#glyph0-15" x="81" y="624.875977"/>
<use xlink:href="#glyph0-9" x="92" y="624.875977"/>
<use xlink:href="#glyph0-21" x="103" y="624.875977"/>
<use xlink:href="#glyph0-22" x="114" y="624.875977"/>
<use xlink:href="#glyph0-9" x="125" y="624.875977"/>
<use xlink:href="#glyph0-12" x="136" y="624.875977"/>
<use xlink:href="#glyph0-1" x="147" y="624.875977"/>
<use xlink:href="#glyph0-12" x="158" y="624.875977"/>
<use xlink:href="#glyph0-14" x="169" y="624.875977"/>
<use xlink:href="#glyph0-19" x="180" y="624.875977"/>
<use xlink:href="#glyph0-4" x="191" y="624.875977"/>
<use xlink:href="#glyph0-15" x="202" y="624.875977"/>
<use xlink:href="#glyph0-9" x="213" y="624.875977"/>
<use xlink:href="#glyph0-14" x="224" y="624.875977"/>
<use xlink:href="#glyph0-23" x="235" y="624.875977"/>
<use xlink:href="#glyph0-4" x="246" y="624.875977"/>
<use xlink:href="#glyph0-4" x="257" y="624.875977"/>
<use xlink:href="#glyph0-20" x="268" y="624.875977"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-23" x="26" y="647.875977"/>
<use xlink:href="#glyph0-7" x="37" y="647.875977"/>
<use xlink:href="#glyph0-20" x="48" y="647.875977"/>
<use xlink:href="#glyph0-9" x="59" y="647.875977"/>
<use xlink:href="#glyph0-14" x="70" y="647.875977"/>
<use xlink:href="#glyph0-7" x="81" y="647.875977"/>
<use xlink:href="#glyph0-11" x="92" y="647.875977"/>
<use xlink:href="#glyph0-14" x="103" y="647.875977"/>
<use xlink:href="#glyph0-1" x="114" y="647.875977"/>
<use xlink:href="#glyph0-24" x="125" y="647.875977"/>
<use xlink:href="#glyph0-9" x="136" y="647.875977"/>
<use xlink:href="#glyph0-14" x="147" y="647.875977"/>
<use xlink:href="#glyph0-25" x="158" y="647.875977"/>
<use xlink:href="#glyph0-9" x="169" y="647.875977"/>
<use xlink:href="#glyph0-23" x="180" y="647.875977"/>
<use xlink:href="#glyph0-9" x="191" y="647.875977"/>
<use xlink:href="#glyph0-2" x="202" y="647.875977"/>
<use xlink:href="#glyph0-15" x="213" y="647.875977"/>
<use xlink:href="#glyph0-5" x="224" y="647.875977"/>
<use xlink:href="#glyph0-19" x="235" y="647.875977"/>
<use xlink:href="#glyph0-14" x="246" y="647.875977"/>
<use xlink:href="#glyph0-26" x="257" y="647.875977"/>
<use xlink:href="#glyph0-4" x="268" y="647.875977"/>
<use xlink:href="#glyph0-1" x="279" y="647.875977"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-27" x="26" y="670.875977"/>
<use xlink:href="#glyph0-28" x="37" y="670.875977"/>
<use xlink:href="#glyph0-29" x="48" y="670.875977"/>
<use xlink:href="#glyph0-14" x="59" y="670.875977"/>
<use xlink:href="#glyph0-5" x="70" y="670.875977"/>
<use xlink:href="#glyph0-11" x="81" y="670.875977"/>
<use xlink:href="#glyph0-30" x="92" y="670.875977"/>
<use xlink:href="#glyph0-14" x="103" y="670.875977"/>
<use xlink:href="#glyph0-2" x="114" y="670.875977"/>
<use xlink:href="#glyph0-7" x="125" y="670.875977"/>
<use xlink:href="#glyph0-31" x="136" y="670.875977"/>
<use xlink:href="#glyph0-9" x="147" y="670.875977"/>
<use xlink:href="#glyph0-14" x="158" y="670.875977"/>
<use xlink:href="#glyph0-4" x="169" y="670.875977"/>
<use xlink:href="#glyph0-6" x="180" y="670.875977"/>
<use xlink:href="#glyph0-6" x="191" y="670.875977"/>
<use xlink:href="#glyph0-4" x="202" y="670.875977"/>
<use xlink:href="#glyph0-15" x="213" y="670.875977"/>
<use xlink:href="#glyph0-1" x="224" y="670.875977"/>
<use xlink:href="#glyph0-22" x="235" y="670.875977"/>
<use xlink:href="#glyph0-11" x="246" y="670.875977"/>
<use xlink:href="#glyph0-7" x="257" y="670.875977"/>
<use xlink:href="#glyph0-1" x="268" y="670.875977"/>
<use xlink:href="#glyph0-32" x="279" y="670.875977"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-1" x="26" y="693.875977"/>
<use xlink:href="#glyph0-4" x="37" y="693.875977"/>
<use xlink:href="#glyph0-14" x="48" y="693.875977"/>
<use xlink:href="#glyph0-22" x="59" y="693.875977"/>
<use xlink:href="#glyph0-12" x="70" y="693.875977"/>
<use xlink:href="#glyph0-9" x="81" y="693.875977"/>
<use xlink:href="#glyph0-14" x="92" y="693.875977"/>
<use xlink:href="#glyph0-7" x="103" y="693.875977"/>
<use xlink:href="#glyph0-1" x="114" y="693.875977"/>
<use xlink:href="#glyph0-33" x="125" y="693.875977"/>
<use xlink:href="#glyph0-12" x="136" y="693.875977"/>
<use xlink:href="#glyph0-14" x="147" y="693.875977"/>
<use xlink:href="#glyph0-9" x="158" y="693.875977"/>
<use xlink:href="#glyph0-5" x="169" y="693.875977"/>
<use xlink:href="#glyph0-12" x="180" y="693.875977"/>
<use xlink:href="#glyph0-7" x="191" y="693.875977"/>
<use xlink:href="#glyph0-9" x="202" y="693.875977"/>
<use xlink:href="#glyph0-15" x="213" y="693.875977"/>
</g>
<path style="fill:none;stroke-width:5;stroke-linecap:round;stroke-linejoin:miter;stroke:rgb(40.784314%,71.764706%,13.72549%);stroke-opacity:1;stroke-miterlimit:10;" d="M 984.889648 521.423416 C 984.889648 579.923416 1132.889648 579.923416 1132.889648 638.423416 " transform="matrix(1,0,0,1,-673.389648,-109.423416)"/>
<path style="fill-rule:nonzero;fill:rgb(40.784314%,71.764706%,13.72549%);fill-opacity:1;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke:rgb(100%,100%,100%);stroke-opacity:1;stroke-miterlimit:10;" d="M 1132.889648 641.423416 L 1139.491211 629.079666 L 1123.545898 630.997635 Z M 1132.889648 641.423416 " transform="matrix(1,0,0,1,-673.389648,-109.423416)"/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 317 534 L 602 534 L 602 680 L 317 680 Z M 317 534 "/>
<path style="fill:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:miter;stroke:rgb(40.784314%,71.764706%,13.72549%);stroke-opacity:1;stroke-miterlimit:10;" d="M 990.389648 653.423416 L 990.389648 643.423416 L 1275.389648 643.423416 L 1275.389648 653.423416 " transform="matrix(1,0,0,1,-673.389648,-109.423416)"/>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-1" x="322" y="557"/>
<use xlink:href="#glyph0-2" x="333" y="557"/>
<use xlink:href="#glyph0-3" x="344" y="557"/>
<use xlink:href="#glyph0-4" x="355" y="557"/>
<use xlink:href="#glyph0-1" x="366" y="557"/>
<use xlink:href="#glyph0-5" x="377" y="557"/>
<use xlink:href="#glyph0-6" x="388" y="557"/>
<use xlink:href="#glyph0-7" x="399" y="557"/>
<use xlink:href="#glyph0-8" x="410" y="557"/>
<use xlink:href="#glyph0-9" x="421" y="557"/>
<use xlink:href="#glyph0-10" x="432" y="557"/>
<use xlink:href="#glyph0-1" x="443" y="557"/>
<use xlink:href="#glyph0-9" x="454" y="557"/>
<use xlink:href="#glyph0-11" x="465" y="557"/>
<use xlink:href="#glyph0-12" x="476" y="557"/>
<use xlink:href="#glyph0-7" x="487" y="557"/>
<use xlink:href="#glyph0-4" x="498" y="557"/>
<use xlink:href="#glyph0-11" x="509" y="557"/>
<use xlink:href="#glyph0-12" x="520" y="557"/>
<use xlink:href="#glyph0-8" x="531" y="557"/>
<use xlink:href="#glyph0-22" x="542" y="557"/>
<use xlink:href="#glyph0-1" x="553" y="557"/>
<use xlink:href="#glyph0-7" x="564" y="557"/>
<use xlink:href="#glyph0-23" x="575" y="557"/>
<use xlink:href="#glyph0-12" x="586" y="557"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-13" x="322" y="601.875977"/>
<use xlink:href="#glyph0-10" x="333" y="601.875977"/>
<use xlink:href="#glyph0-1" x="344" y="601.875977"/>
<use xlink:href="#glyph0-9" x="355" y="601.875977"/>
<use xlink:href="#glyph0-11" x="366" y="601.875977"/>
<use xlink:href="#glyph0-12" x="377" y="601.875977"/>
<use xlink:href="#glyph0-7" x="388" y="601.875977"/>
<use xlink:href="#glyph0-4" x="399" y="601.875977"/>
<use xlink:href="#glyph0-11" x="410" y="601.875977"/>
<use xlink:href="#glyph0-12" x="421" y="601.875977"/>
<use xlink:href="#glyph0-14" x="432" y="601.875977"/>
<use xlink:href="#glyph0-6" x="443" y="601.875977"/>
<use xlink:href="#glyph0-15" x="454" y="601.875977"/>
<use xlink:href="#glyph0-4" x="465" y="601.875977"/>
<use xlink:href="#glyph0-16" x="476" y="601.875977"/>
<use xlink:href="#glyph0-9" x="487" y="601.875977"/>
<use xlink:href="#glyph0-17" x="498" y="601.875977"/>
<use xlink:href="#glyph0-1" x="509" y="601.875977"/>
<use xlink:href="#glyph0-14" x="520" y="601.875977"/>
<use xlink:href="#glyph0-34" x="531" y="601.875977"/>
<use xlink:href="#glyph0-7" x="542" y="601.875977"/>
<use xlink:href="#glyph0-1" x="553" y="601.875977"/>
<use xlink:href="#glyph0-24" x="564" y="601.875977"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-22" x="322" y="624.875977"/>
<use xlink:href="#glyph0-1" x="333" y="624.875977"/>
<use xlink:href="#glyph0-7" x="344" y="624.875977"/>
<use xlink:href="#glyph0-23" x="355" y="624.875977"/>
<use xlink:href="#glyph0-12" x="366" y="624.875977"/>
<use xlink:href="#glyph0-14" x="377" y="624.875977"/>
<use xlink:href="#glyph0-1" x="388" y="624.875977"/>
<use xlink:href="#glyph0-24" x="399" y="624.875977"/>
<use xlink:href="#glyph0-7" x="410" y="624.875977"/>
<use xlink:href="#glyph0-11" x="421" y="624.875977"/>
<use xlink:href="#glyph0-2" x="432" y="624.875977"/>
<use xlink:href="#glyph0-12" x="443" y="624.875977"/>
<use xlink:href="#glyph0-14" x="454" y="624.875977"/>
<use xlink:href="#glyph0-34" x="465" y="624.875977"/>
<use xlink:href="#glyph0-24" x="476" y="624.875977"/>
<use xlink:href="#glyph0-7" x="487" y="624.875977"/>
<use xlink:href="#glyph0-17" x="498" y="624.875977"/>
<use xlink:href="#glyph0-24" x="509" y="624.875977"/>
<use xlink:href="#glyph0-14" x="520" y="624.875977"/>
<use xlink:href="#glyph0-34" x="531" y="624.875977"/>
<use xlink:href="#glyph0-7" x="542" y="624.875977"/>
<use xlink:href="#glyph0-23" x="553" y="624.875977"/>
<use xlink:href="#glyph0-23" x="564" y="624.875977"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-19" x="322" y="647.875977"/>
<use xlink:href="#glyph0-5" x="333" y="647.875977"/>
<use xlink:href="#glyph0-20" x="344" y="647.875977"/>
<use xlink:href="#glyph0-9" x="355" y="647.875977"/>
<use xlink:href="#glyph0-14" x="366" y="647.875977"/>
<use xlink:href="#glyph0-9" x="377" y="647.875977"/>
<use xlink:href="#glyph0-5" x="388" y="647.875977"/>
<use xlink:href="#glyph0-12" x="399" y="647.875977"/>
<use xlink:href="#glyph0-7" x="410" y="647.875977"/>
<use xlink:href="#glyph0-9" x="421" y="647.875977"/>
<use xlink:href="#glyph0-15" x="432" y="647.875977"/>
<use xlink:href="#glyph0-14" x="443" y="647.875977"/>
<use xlink:href="#glyph0-30" x="454" y="647.875977"/>
<use xlink:href="#glyph0-7" x="465" y="647.875977"/>
<use xlink:href="#glyph0-18" x="476" y="647.875977"/>
<use xlink:href="#glyph0-18" x="487" y="647.875977"/>
<use xlink:href="#glyph0-9" x="498" y="647.875977"/>
<use xlink:href="#glyph0-15" x="509" y="647.875977"/>
<use xlink:href="#glyph0-9" x="520" y="647.875977"/>
<use xlink:href="#glyph0-11" x="531" y="647.875977"/>
<use xlink:href="#glyph0-1" x="542" y="647.875977"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-4" x="322" y="670.875977"/>
<use xlink:href="#glyph0-6" x="333" y="670.875977"/>
<use xlink:href="#glyph0-9" x="344" y="670.875977"/>
<use xlink:href="#glyph0-15" x="355" y="670.875977"/>
<use xlink:href="#glyph0-5" x="366" y="670.875977"/>
<use xlink:href="#glyph0-1" x="377" y="670.875977"/>
<use xlink:href="#glyph0-7" x="388" y="670.875977"/>
<use xlink:href="#glyph0-4" x="399" y="670.875977"/>
<use xlink:href="#glyph0-11" x="410" y="670.875977"/>
<use xlink:href="#glyph0-12" x="421" y="670.875977"/>
</g>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(100%,100%,100%);fill-opacity:1;" d="M 119.5 289 L 503.5 289 L 503.5 412 L 119.5 412 Z M 119.5 289 "/>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-25" x="124.5" y="312"/>
<use xlink:href="#glyph0-9" x="135.5" y="312"/>
<use xlink:href="#glyph0-23" x="146.5" y="312"/>
<use xlink:href="#glyph0-9" x="157.5" y="312"/>
<use xlink:href="#glyph0-2" x="168.5" y="312"/>
<use xlink:href="#glyph0-15" x="179.5" y="312"/>
<use xlink:href="#glyph0-5" x="190.5" y="312"/>
<use xlink:href="#glyph0-19" x="201.5" y="312"/>
<use xlink:href="#glyph0-26" x="212.5" y="312"/>
<use xlink:href="#glyph0-4" x="223.5" y="312"/>
<use xlink:href="#glyph0-1" x="234.5" y="312"/>
<use xlink:href="#glyph0-27" x="245.5" y="312"/>
<use xlink:href="#glyph0-28" x="256.5" y="312"/>
<use xlink:href="#glyph0-29" x="267.5" y="312"/>
<use xlink:href="#glyph0-14" x="278.5" y="312"/>
<use xlink:href="#glyph0-9" x="289.5" y="312"/>
<use xlink:href="#glyph0-10" x="300.5" y="312"/>
<use xlink:href="#glyph0-1" x="311.5" y="312"/>
<use xlink:href="#glyph0-9" x="322.5" y="312"/>
<use xlink:href="#glyph0-11" x="333.5" y="312"/>
<use xlink:href="#glyph0-12" x="344.5" y="312"/>
<use xlink:href="#glyph0-7" x="355.5" y="312"/>
<use xlink:href="#glyph0-4" x="366.5" y="312"/>
<use xlink:href="#glyph0-11" x="377.5" y="312"/>
<use xlink:href="#glyph0-12" x="388.5" y="312"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-35" x="124.5" y="356.875977"/>
<use xlink:href="#glyph0-5" x="135.5" y="356.875977"/>
<use xlink:href="#glyph0-19" x="146.5" y="356.875977"/>
<use xlink:href="#glyph0-7" x="157.5" y="356.875977"/>
<use xlink:href="#glyph0-23" x="168.5" y="356.875977"/>
<use xlink:href="#glyph0-32" x="179.5" y="356.875977"/>
<use xlink:href="#glyph0-14" x="190.5" y="356.875977"/>
<use xlink:href="#glyph0-4" x="201.5" y="356.875977"/>
<use xlink:href="#glyph0-18" x="212.5" y="356.875977"/>
<use xlink:href="#glyph0-14" x="223.5" y="356.875977"/>
<use xlink:href="#glyph0-6" x="234.5" y="356.875977"/>
<use xlink:href="#glyph0-15" x="245.5" y="356.875977"/>
<use xlink:href="#glyph0-4" x="256.5" y="356.875977"/>
<use xlink:href="#glyph0-16" x="267.5" y="356.875977"/>
<use xlink:href="#glyph0-9" x="278.5" y="356.875977"/>
<use xlink:href="#glyph0-17" x="289.5" y="356.875977"/>
<use xlink:href="#glyph0-1" x="300.5" y="356.875977"/>
<use xlink:href="#glyph0-12" x="311.5" y="356.875977"/>
<use xlink:href="#glyph0-14" x="322.5" y="356.875977"/>
<use xlink:href="#glyph0-34" x="333.5" y="356.875977"/>
<use xlink:href="#glyph0-24" x="344.5" y="356.875977"/>
<use xlink:href="#glyph0-7" x="355.5" y="356.875977"/>
<use xlink:href="#glyph0-17" x="366.5" y="356.875977"/>
<use xlink:href="#glyph0-24" x="377.5" y="356.875977"/>
<use xlink:href="#glyph0-14" x="388.5" y="356.875977"/>
<use xlink:href="#glyph0-5" x="399.5" y="356.875977"/>
<use xlink:href="#glyph0-15" x="410.5" y="356.875977"/>
<use xlink:href="#glyph0-9" x="421.5" y="356.875977"/>
<use xlink:href="#glyph0-14" x="432.5" y="356.875977"/>
<use xlink:href="#glyph0-18" x="443.5" y="356.875977"/>
<use xlink:href="#glyph0-22" x="454.5" y="356.875977"/>
<use xlink:href="#glyph0-23" x="465.5" y="356.875977"/>
<use xlink:href="#glyph0-23" x="476.5" y="356.875977"/>
<use xlink:href="#glyph0-32" x="487.5" y="356.875977"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-3" x="124.5" y="379.875977"/>
<use xlink:href="#glyph0-5" x="135.5" y="379.875977"/>
<use xlink:href="#glyph0-12" x="146.5" y="379.875977"/>
<use xlink:href="#glyph0-9" x="157.5" y="379.875977"/>
<use xlink:href="#glyph0-30" x="168.5" y="379.875977"/>
<use xlink:href="#glyph0-14" x="179.5" y="379.875977"/>
<use xlink:href="#glyph0-4" x="190.5" y="379.875977"/>
<use xlink:href="#glyph0-11" x="201.5" y="379.875977"/>
<use xlink:href="#glyph0-14" x="212.5" y="379.875977"/>
<use xlink:href="#glyph0-25" x="223.5" y="379.875977"/>
<use xlink:href="#glyph0-9" x="234.5" y="379.875977"/>
<use xlink:href="#glyph0-23" x="245.5" y="379.875977"/>
<use xlink:href="#glyph0-9" x="256.5" y="379.875977"/>
<use xlink:href="#glyph0-2" x="267.5" y="379.875977"/>
<use xlink:href="#glyph0-15" x="278.5" y="379.875977"/>
<use xlink:href="#glyph0-5" x="289.5" y="379.875977"/>
<use xlink:href="#glyph0-19" x="300.5" y="379.875977"/>
<use xlink:href="#glyph0-26" x="311.5" y="379.875977"/>
<use xlink:href="#glyph0-4" x="322.5" y="379.875977"/>
<use xlink:href="#glyph0-1" x="333.5" y="379.875977"/>
<use xlink:href="#glyph0-27" x="344.5" y="379.875977"/>
<use xlink:href="#glyph0-28" x="355.5" y="379.875977"/>
<use xlink:href="#glyph0-29" x="366.5" y="379.875977"/>
<use xlink:href="#glyph0-14" x="377.5" y="379.875977"/>
<use xlink:href="#glyph0-5" x="388.5" y="379.875977"/>
<use xlink:href="#glyph0-11" x="399.5" y="379.875977"/>
<use xlink:href="#glyph0-30" x="410.5" y="379.875977"/>
<use xlink:href="#glyph0-14" x="421.5" y="379.875977"/>
<use xlink:href="#glyph0-9" x="432.5" y="379.875977"/>
<use xlink:href="#glyph0-10" x="443.5" y="379.875977"/>
<use xlink:href="#glyph0-1" x="454.5" y="379.875977"/>
<use xlink:href="#glyph0-9" x="465.5" y="379.875977"/>
<use xlink:href="#glyph0-11" x="476.5" y="379.875977"/>
<use xlink:href="#glyph0-30" x="487.5" y="379.875977"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-7" x="124.5" y="402.875977"/>
<use xlink:href="#glyph0-1" x="135.5" y="402.875977"/>
<use xlink:href="#glyph0-12" x="146.5" y="402.875977"/>
<use xlink:href="#glyph0-14" x="157.5" y="402.875977"/>
<use xlink:href="#glyph0-18" x="168.5" y="402.875977"/>
<use xlink:href="#glyph0-22" x="179.5" y="402.875977"/>
<use xlink:href="#glyph0-11" x="190.5" y="402.875977"/>
<use xlink:href="#glyph0-17" x="201.5" y="402.875977"/>
<use xlink:href="#glyph0-1" x="212.5" y="402.875977"/>
<use xlink:href="#glyph0-7" x="223.5" y="402.875977"/>
<use xlink:href="#glyph0-4" x="234.5" y="402.875977"/>
<use xlink:href="#glyph0-11" x="245.5" y="402.875977"/>
<use xlink:href="#glyph0-5" x="256.5" y="402.875977"/>
<use xlink:href="#glyph0-23" x="267.5" y="402.875977"/>
<use xlink:href="#glyph0-7" x="278.5" y="402.875977"/>
<use xlink:href="#glyph0-1" x="289.5" y="402.875977"/>
<use xlink:href="#glyph0-32" x="300.5" y="402.875977"/>
</g>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(83.137255%,83.137255%,83.137255%);fill-opacity:1;" d="M 86.5 21 L 536.5 21 L 536.5 167 L 86.5 167 Z M 86.5 21 "/>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-1" x="91.5" y="44"/>
<use xlink:href="#glyph0-2" x="102.5" y="44"/>
<use xlink:href="#glyph0-3" x="113.5" y="44"/>
<use xlink:href="#glyph0-4" x="124.5" y="44"/>
<use xlink:href="#glyph0-1" x="135.5" y="44"/>
<use xlink:href="#glyph0-5" x="146.5" y="44"/>
<use xlink:href="#glyph0-6" x="157.5" y="44"/>
<use xlink:href="#glyph0-7" x="168.5" y="44"/>
<use xlink:href="#glyph0-8" x="179.5" y="44"/>
<use xlink:href="#glyph0-17" x="190.5" y="44"/>
<use xlink:href="#glyph0-4" x="201.5" y="44"/>
<use xlink:href="#glyph0-15" x="212.5" y="44"/>
<use xlink:href="#glyph0-9" x="223.5" y="44"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-36" x="91.5" y="88.875977"/>
<use xlink:href="#glyph0-4" x="102.5" y="88.875977"/>
<use xlink:href="#glyph0-4" x="113.5" y="88.875977"/>
<use xlink:href="#glyph0-1" x="124.5" y="88.875977"/>
<use xlink:href="#glyph0-14" x="135.5" y="88.875977"/>
<use xlink:href="#glyph0-6" x="146.5" y="88.875977"/>
<use xlink:href="#glyph0-15" x="157.5" y="88.875977"/>
<use xlink:href="#glyph0-4" x="168.5" y="88.875977"/>
<use xlink:href="#glyph0-16" x="179.5" y="88.875977"/>
<use xlink:href="#glyph0-9" x="190.5" y="88.875977"/>
<use xlink:href="#glyph0-17" x="201.5" y="88.875977"/>
<use xlink:href="#glyph0-1" x="212.5" y="88.875977"/>
<use xlink:href="#glyph0-14" x="223.5" y="88.875977"/>
<use xlink:href="#glyph0-34" x="234.5" y="88.875977"/>
<use xlink:href="#glyph0-7" x="245.5" y="88.875977"/>
<use xlink:href="#glyph0-1" x="256.5" y="88.875977"/>
<use xlink:href="#glyph0-24" x="267.5" y="88.875977"/>
<use xlink:href="#glyph0-14" x="278.5" y="88.875977"/>
<use xlink:href="#glyph0-27" x="289.5" y="88.875977"/>
<use xlink:href="#glyph0-28" x="300.5" y="88.875977"/>
<use xlink:href="#glyph0-29" x="311.5" y="88.875977"/>
<use xlink:href="#glyph0-8" x="322.5" y="88.875977"/>
<use xlink:href="#glyph0-14" x="333.5" y="88.875977"/>
<use xlink:href="#glyph0-29" x="344.5" y="88.875977"/>
<use xlink:href="#glyph0-1" x="355.5" y="88.875977"/>
<use xlink:href="#glyph0-14" x="366.5" y="88.875977"/>
<use xlink:href="#glyph0-7" x="377.5" y="88.875977"/>
<use xlink:href="#glyph0-12" x="388.5" y="88.875977"/>
<use xlink:href="#glyph0-14" x="399.5" y="88.875977"/>
<use xlink:href="#glyph0-11" x="410.5" y="88.875977"/>
<use xlink:href="#glyph0-4" x="421.5" y="88.875977"/>
<use xlink:href="#glyph0-1" x="432.5" y="88.875977"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-15" x="91.5" y="111.875977"/>
<use xlink:href="#glyph0-9" x="102.5" y="111.875977"/>
<use xlink:href="#glyph0-17" x="113.5" y="111.875977"/>
<use xlink:href="#glyph0-4" x="124.5" y="111.875977"/>
<use xlink:href="#glyph0-19" x="135.5" y="111.875977"/>
<use xlink:href="#glyph0-19" x="146.5" y="111.875977"/>
<use xlink:href="#glyph0-9" x="157.5" y="111.875977"/>
<use xlink:href="#glyph0-11" x="168.5" y="111.875977"/>
<use xlink:href="#glyph0-30" x="179.5" y="111.875977"/>
<use xlink:href="#glyph0-9" x="190.5" y="111.875977"/>
<use xlink:href="#glyph0-30" x="201.5" y="111.875977"/>
<use xlink:href="#glyph0-14" x="212.5" y="111.875977"/>
<use xlink:href="#glyph0-1" x="223.5" y="111.875977"/>
<use xlink:href="#glyph0-4" x="234.5" y="111.875977"/>
<use xlink:href="#glyph0-14" x="245.5" y="111.875977"/>
<use xlink:href="#glyph0-22" x="256.5" y="111.875977"/>
<use xlink:href="#glyph0-12" x="267.5" y="111.875977"/>
<use xlink:href="#glyph0-9" x="278.5" y="111.875977"/>
<use xlink:href="#glyph0-14" x="289.5" y="111.875977"/>
<use xlink:href="#glyph0-7" x="300.5" y="111.875977"/>
<use xlink:href="#glyph0-1" x="311.5" y="111.875977"/>
<use xlink:href="#glyph0-12" x="322.5" y="111.875977"/>
<use xlink:href="#glyph0-14" x="333.5" y="111.875977"/>
<use xlink:href="#glyph0-15" x="344.5" y="111.875977"/>
<use xlink:href="#glyph0-9" x="355.5" y="111.875977"/>
<use xlink:href="#glyph0-21" x="366.5" y="111.875977"/>
<use xlink:href="#glyph0-22" x="377.5" y="111.875977"/>
<use xlink:href="#glyph0-9" x="388.5" y="111.875977"/>
<use xlink:href="#glyph0-12" x="399.5" y="111.875977"/>
<use xlink:href="#glyph0-1" x="410.5" y="111.875977"/>
<use xlink:href="#glyph0-12" x="421.5" y="111.875977"/>
<use xlink:href="#glyph0-14" x="432.5" y="111.875977"/>
<use xlink:href="#glyph0-30" x="443.5" y="111.875977"/>
<use xlink:href="#glyph0-7" x="454.5" y="111.875977"/>
<use xlink:href="#glyph0-15" x="465.5" y="111.875977"/>
<use xlink:href="#glyph0-9" x="476.5" y="111.875977"/>
<use xlink:href="#glyph0-17" x="487.5" y="111.875977"/>
<use xlink:href="#glyph0-1" x="498.5" y="111.875977"/>
<use xlink:href="#glyph0-23" x="509.5" y="111.875977"/>
<use xlink:href="#glyph0-32" x="520.5" y="111.875977"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-5" x="91.5" y="134.875977"/>
<use xlink:href="#glyph0-11" x="102.5" y="134.875977"/>
<use xlink:href="#glyph0-30" x="113.5" y="134.875977"/>
<use xlink:href="#glyph0-14" x="124.5" y="134.875977"/>
<use xlink:href="#glyph0-3" x="135.5" y="134.875977"/>
<use xlink:href="#glyph0-9" x="146.5" y="134.875977"/>
<use xlink:href="#glyph0-1" x="157.5" y="134.875977"/>
<use xlink:href="#glyph0-1" x="168.5" y="134.875977"/>
<use xlink:href="#glyph0-9" x="179.5" y="134.875977"/>
<use xlink:href="#glyph0-15" x="190.5" y="134.875977"/>
<use xlink:href="#glyph0-14" x="201.5" y="134.875977"/>
<use xlink:href="#glyph0-1" x="212.5" y="134.875977"/>
<use xlink:href="#glyph0-4" x="223.5" y="134.875977"/>
<use xlink:href="#glyph0-14" x="234.5" y="134.875977"/>
<use xlink:href="#glyph0-22" x="245.5" y="134.875977"/>
<use xlink:href="#glyph0-12" x="256.5" y="134.875977"/>
<use xlink:href="#glyph0-9" x="267.5" y="134.875977"/>
<use xlink:href="#glyph0-14" x="278.5" y="134.875977"/>
<use xlink:href="#glyph0-5" x="289.5" y="134.875977"/>
<use xlink:href="#glyph0-1" x="300.5" y="134.875977"/>
<use xlink:href="#glyph0-14" x="311.5" y="134.875977"/>
<use xlink:href="#glyph0-23" x="322.5" y="134.875977"/>
<use xlink:href="#glyph0-9" x="333.5" y="134.875977"/>
<use xlink:href="#glyph0-5" x="344.5" y="134.875977"/>
<use xlink:href="#glyph0-12" x="355.5" y="134.875977"/>
<use xlink:href="#glyph0-1" x="366.5" y="134.875977"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-1" x="91.5" y="157.875977"/>
<use xlink:href="#glyph0-2" x="102.5" y="157.875977"/>
<use xlink:href="#glyph0-3" x="113.5" y="157.875977"/>
<use xlink:href="#glyph0-4" x="124.5" y="157.875977"/>
<use xlink:href="#glyph0-1" x="135.5" y="157.875977"/>
<use xlink:href="#glyph0-5" x="146.5" y="157.875977"/>
<use xlink:href="#glyph0-6" x="157.5" y="157.875977"/>
<use xlink:href="#glyph0-7" x="168.5" y="157.875977"/>
<use xlink:href="#glyph0-8" x="179.5" y="157.875977"/>
<use xlink:href="#glyph0-9" x="190.5" y="157.875977"/>
<use xlink:href="#glyph0-10" x="201.5" y="157.875977"/>
<use xlink:href="#glyph0-1" x="212.5" y="157.875977"/>
<use xlink:href="#glyph0-9" x="223.5" y="157.875977"/>
<use xlink:href="#glyph0-11" x="234.5" y="157.875977"/>
<use xlink:href="#glyph0-12" x="245.5" y="157.875977"/>
<use xlink:href="#glyph0-7" x="256.5" y="157.875977"/>
<use xlink:href="#glyph0-4" x="267.5" y="157.875977"/>
<use xlink:href="#glyph0-11" x="278.5" y="157.875977"/>
<use xlink:href="#glyph0-12" x="289.5" y="157.875977"/>
<use xlink:href="#glyph0-8" x="300.5" y="157.875977"/>
<use xlink:href="#glyph0-5" x="311.5" y="157.875977"/>
<use xlink:href="#glyph0-6" x="322.5" y="157.875977"/>
<use xlink:href="#glyph0-7" x="333.5" y="157.875977"/>
</g>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(83.137255%,83.137255%,83.137255%);fill-opacity:1;" d="M 153.132812 849.621094 L 460.132812 849.621094 L 460.132812 1040.621094 L 153.132812 1040.621094 Z M 153.132812 849.621094 "/>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-1" x="158.132812" y="872.621094"/>
<use xlink:href="#glyph0-2" x="169.132812" y="872.621094"/>
<use xlink:href="#glyph0-3" x="180.132812" y="872.621094"/>
<use xlink:href="#glyph0-4" x="191.132812" y="872.621094"/>
<use xlink:href="#glyph0-1" x="202.132812" y="872.621094"/>
<use xlink:href="#glyph0-5" x="213.132812" y="872.621094"/>
<use xlink:href="#glyph0-6" x="224.132812" y="872.621094"/>
<use xlink:href="#glyph0-7" x="235.132812" y="872.621094"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-37" x="158.132812" y="917.49707"/>
<use xlink:href="#glyph0-9" x="169.132812" y="917.49707"/>
<use xlink:href="#glyph0-15" x="180.132812" y="917.49707"/>
<use xlink:href="#glyph0-9" x="191.132812" y="917.49707"/>
<use xlink:href="#glyph0-14" x="202.132812" y="917.49707"/>
<use xlink:href="#glyph0-7" x="213.132812" y="917.49707"/>
<use xlink:href="#glyph0-11" x="224.132812" y="917.49707"/>
<use xlink:href="#glyph0-17" x="235.132812" y="917.49707"/>
<use xlink:href="#glyph0-23" x="246.132812" y="917.49707"/>
<use xlink:href="#glyph0-22" x="257.132812" y="917.49707"/>
<use xlink:href="#glyph0-30" x="268.132812" y="917.49707"/>
<use xlink:href="#glyph0-9" x="279.132812" y="917.49707"/>
<use xlink:href="#glyph0-30" x="290.132812" y="917.49707"/>
<use xlink:href="#glyph0-14" x="301.132812" y="917.49707"/>
<use xlink:href="#glyph0-5" x="312.132812" y="917.49707"/>
<use xlink:href="#glyph0-23" x="323.132812" y="917.49707"/>
<use xlink:href="#glyph0-23" x="334.132812" y="917.49707"/>
<use xlink:href="#glyph0-14" x="345.132812" y="917.49707"/>
<use xlink:href="#glyph0-5" x="356.132812" y="917.49707"/>
<use xlink:href="#glyph0-31" x="367.132812" y="917.49707"/>
<use xlink:href="#glyph0-5" x="378.132812" y="917.49707"/>
<use xlink:href="#glyph0-7" x="389.132812" y="917.49707"/>
<use xlink:href="#glyph0-23" x="400.132812" y="917.49707"/>
<use xlink:href="#glyph0-5" x="411.132812" y="917.49707"/>
<use xlink:href="#glyph0-3" x="422.132812" y="917.49707"/>
<use xlink:href="#glyph0-23" x="433.132812" y="917.49707"/>
<use xlink:href="#glyph0-9" x="444.132812" y="917.49707"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-25" x="158.132812" y="940.49707"/>
<use xlink:href="#glyph0-9" x="169.132812" y="940.49707"/>
<use xlink:href="#glyph0-23" x="180.132812" y="940.49707"/>
<use xlink:href="#glyph0-9" x="191.132812" y="940.49707"/>
<use xlink:href="#glyph0-2" x="202.132812" y="940.49707"/>
<use xlink:href="#glyph0-15" x="213.132812" y="940.49707"/>
<use xlink:href="#glyph0-5" x="224.132812" y="940.49707"/>
<use xlink:href="#glyph0-19" x="235.132812" y="940.49707"/>
<use xlink:href="#glyph0-26" x="246.132812" y="940.49707"/>
<use xlink:href="#glyph0-4" x="257.132812" y="940.49707"/>
<use xlink:href="#glyph0-1" x="268.132812" y="940.49707"/>
<use xlink:href="#glyph0-27" x="279.132812" y="940.49707"/>
<use xlink:href="#glyph0-28" x="290.132812" y="940.49707"/>
<use xlink:href="#glyph0-29" x="301.132812" y="940.49707"/>
<use xlink:href="#glyph0-14" x="312.132812" y="940.49707"/>
<use xlink:href="#glyph0-23" x="323.132812" y="940.49707"/>
<use xlink:href="#glyph0-7" x="334.132812" y="940.49707"/>
<use xlink:href="#glyph0-3" x="345.132812" y="940.49707"/>
<use xlink:href="#glyph0-15" x="356.132812" y="940.49707"/>
<use xlink:href="#glyph0-5" x="367.132812" y="940.49707"/>
<use xlink:href="#glyph0-15" x="378.132812" y="940.49707"/>
<use xlink:href="#glyph0-7" x="389.132812" y="940.49707"/>
<use xlink:href="#glyph0-9" x="400.132812" y="940.49707"/>
<use xlink:href="#glyph0-12" x="411.132812" y="940.49707"/>
<use xlink:href="#glyph0-38" x="422.132812" y="940.49707"/>
</g>
<g style="fill:rgb(100%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-39" x="158.132812" y="985.373047"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-14" x="169.132812" y="985.373047"/>
<use xlink:href="#glyph0-1" x="180.132812" y="985.373047"/>
<use xlink:href="#glyph0-2" x="191.132812" y="985.373047"/>
<use xlink:href="#glyph0-3" x="202.132812" y="985.373047"/>
<use xlink:href="#glyph0-4" x="213.132812" y="985.373047"/>
<use xlink:href="#glyph0-1" x="224.132812" y="985.373047"/>
<use xlink:href="#glyph0-5" x="235.132812" y="985.373047"/>
<use xlink:href="#glyph0-6" x="246.132812" y="985.373047"/>
<use xlink:href="#glyph0-7" x="257.132812" y="985.373047"/>
<use xlink:href="#glyph0-8" x="268.132812" y="985.373047"/>
<use xlink:href="#glyph0-17" x="279.132812" y="985.373047"/>
<use xlink:href="#glyph0-4" x="290.132812" y="985.373047"/>
<use xlink:href="#glyph0-15" x="301.132812" y="985.373047"/>
<use xlink:href="#glyph0-9" x="312.132812" y="985.373047"/>
</g>
<g style="fill:rgb(100%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-39" x="158.132812" y="1008.373047"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-14" x="169.132812" y="1008.373047"/>
<use xlink:href="#glyph0-1" x="180.132812" y="1008.373047"/>
<use xlink:href="#glyph0-2" x="191.132812" y="1008.373047"/>
<use xlink:href="#glyph0-3" x="202.132812" y="1008.373047"/>
<use xlink:href="#glyph0-4" x="213.132812" y="1008.373047"/>
<use xlink:href="#glyph0-1" x="224.132812" y="1008.373047"/>
<use xlink:href="#glyph0-5" x="235.132812" y="1008.373047"/>
<use xlink:href="#glyph0-6" x="246.132812" y="1008.373047"/>
<use xlink:href="#glyph0-7" x="257.132812" y="1008.373047"/>
<use xlink:href="#glyph0-8" x="268.132812" y="1008.373047"/>
<use xlink:href="#glyph0-9" x="279.132812" y="1008.373047"/>
<use xlink:href="#glyph0-10" x="290.132812" y="1008.373047"/>
<use xlink:href="#glyph0-1" x="301.132812" y="1008.373047"/>
<use xlink:href="#glyph0-9" x="312.132812" y="1008.373047"/>
<use xlink:href="#glyph0-11" x="323.132812" y="1008.373047"/>
<use xlink:href="#glyph0-12" x="334.132812" y="1008.373047"/>
<use xlink:href="#glyph0-7" x="345.132812" y="1008.373047"/>
<use xlink:href="#glyph0-4" x="356.132812" y="1008.373047"/>
<use xlink:href="#glyph0-11" x="367.132812" y="1008.373047"/>
<use xlink:href="#glyph0-12" x="378.132812" y="1008.373047"/>
<use xlink:href="#glyph0-8" x="389.132812" y="1008.373047"/>
<use xlink:href="#glyph0-5" x="400.132812" y="1008.373047"/>
<use xlink:href="#glyph0-6" x="411.132812" y="1008.373047"/>
<use xlink:href="#glyph0-7" x="422.132812" y="1008.373047"/>
</g>
<g style="fill:rgb(100%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-39" x="158.132812" y="1031.373047"/>
</g>
<g style="fill:rgb(0%,0%,0%);fill-opacity:1;">
<use xlink:href="#glyph0-14" x="169.132812" y="1031.373047"/>
<use xlink:href="#glyph0-1" x="180.132812" y="1031.373047"/>
<use xlink:href="#glyph0-2" x="191.132812" y="1031.373047"/>
<use xlink:href="#glyph0-3" x="202.132812" y="1031.373047"/>
<use xlink:href="#glyph0-4" x="213.132812" y="1031.373047"/>
<use xlink:href="#glyph0-1" x="224.132812" y="1031.373047"/>
<use xlink:href="#glyph0-5" x="235.132812" y="1031.373047"/>
<use xlink:href="#glyph0-6" x="246.132812" y="1031.373047"/>
<use xlink:href="#glyph0-7" x="257.132812" y="1031.373047"/>
<use xlink:href="#glyph0-8" x="268.132812" y="1031.373047"/>
<use xlink:href="#glyph0-9" x="279.132812" y="1031.373047"/>
<use xlink:href="#glyph0-10" x="290.132812" y="1031.373047"/>
<use xlink:href="#glyph0-1" x="301.132812" y="1031.373047"/>
<use xlink:href="#glyph0-9" x="312.132812" y="1031.373047"/>
<use xlink:href="#glyph0-11" x="323.132812" y="1031.373047"/>
<use xlink:href="#glyph0-12" x="334.132812" y="1031.373047"/>
<use xlink:href="#glyph0-7" x="345.132812" y="1031.373047"/>
<use xlink:href="#glyph0-4" x="356.132812" y="1031.373047"/>
<use xlink:href="#glyph0-11" x="367.132812" y="1031.373047"/>
<use xlink:href="#glyph0-12" x="378.132812" y="1031.373047"/>
<use xlink:href="#glyph0-8" x="389.132812" y="1031.373047"/>
<use xlink:href="#glyph0-22" x="400.132812" y="1031.373047"/>
<use xlink:href="#glyph0-1" x="411.132812" y="1031.373047"/>
<use xlink:href="#glyph0-7" x="422.132812" y="1031.373047"/>
<use xlink:href="#glyph0-23" x="433.132812" y="1031.373047"/>
<use xlink:href="#glyph0-12" x="444.132812" y="1031.373047"/>
</g>
<path style="fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke:rgb(46.666667%,46.666667%,46.666667%);stroke-opacity:1;stroke-dasharray:2,8;stroke-miterlimit:10;" d="M 877.31543 816.423416 C 896.026367 869.962479 915.170898 916.16951 934.745117 955.04451 " transform="matrix(1,0,0,1,-673.389648,-109.423416)"/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(46.666667%,46.666667%,46.666667%);fill-opacity:1;" d="M 261.355469 845.621094 L 263.226562 832.757812 L 249.90625 839.464844 Z M 261.355469 845.621094 "/>
<path style="fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke:rgb(46.666667%,46.666667%,46.666667%);stroke-opacity:1;stroke-dasharray:2,8;stroke-miterlimit:10;" d="M 1082.803711 793.423416 C 1066.94043 862.298416 1047.674805 916.16951 1025.006836 955.04451 " transform="matrix(1,0,0,1,-673.389648,-109.423416)"/>
<path style=" stroke:none;fill-rule:nonzero;fill:rgb(46.666667%,46.666667%,46.666667%);fill-opacity:1;" d="M 351.617188 845.621094 L 363.421875 840.175781 L 350.539062 832.664062 Z M 351.617188 845.621094 "/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 80 KiB

View File

@@ -1 +1,12 @@
rootProject.name = 'TelegramBotAPI'
pluginManagement {
repositories {
gradlePluginPortal()
jcenter()
}
}
include ":tgbotapi.core"
include ":tgbotapi.extensions.api"
include ":tgbotapi.extensions.utils"
include ":tgbotapi"
include ":docs"

View File

@@ -1,18 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts
import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.ParseMode
import com.github.insanusmokrassar.TelegramBotAPI.utils.fullListOfSubSource
interface Captioned {
val caption: String?
}
interface CaptionedOutput : Captioned {
val parseMode: ParseMode?
}
interface CaptionedInput : Captioned {
val captionEntities: List<TextPart>
}
fun CaptionedInput.fullEntitiesList() = caption ?.fullListOfSubSource(captionEntities) ?.map { it.source } ?: emptyList()

View File

@@ -1,8 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts
interface CommonVenueData : Titled {
override val title: String
val address: String
val foursquareId: String?
val foursquareType: String? // TODO:: Rewrite with enum or interface
}

View File

@@ -1,8 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts
interface Livable {
/**
* Period in SECONDS
*/
val livePeriod: Int?
}

View File

@@ -1,5 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts
interface MimeTyped {
val mimeType: String? // TODO::replace by something like enum or interface
}

View File

@@ -1,5 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts
interface Performerable {
val performer: String?
}

View File

@@ -1,17 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts
interface TextSource {
val asMarkdownSource: String
val asMarkdownV2Source: String
val asHtmlSource: String
}
interface MultilevelTextSource : TextSource {
val textParts: List<TextPart>
}
data class TextPart(
val range: IntRange,
val source: TextSource
)

View File

@@ -1,5 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts
interface Titled {
val title: String?
}

View File

@@ -1,7 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier
interface ChatRequest {
val chatId: ChatIdentifier
}

View File

@@ -1,5 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types
interface DisableNotification {
val disableNotification: Boolean
}

View File

@@ -1,7 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types
import com.github.insanusmokrassar.TelegramBotAPI.types.InlineMessageIdentifier
interface InlineMessageAction {
val inlineMessageId: InlineMessageIdentifier
}

View File

@@ -1,7 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types
import com.github.insanusmokrassar.TelegramBotAPI.types.MessageIdentifier
interface MessageAction: ChatRequest {
val messageId: MessageIdentifier
}

View File

@@ -1,7 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.KeyboardMarkup
interface ReplyMarkup {
val replyMarkup: KeyboardMarkup?
}

View File

@@ -1,7 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types
import com.github.insanusmokrassar.TelegramBotAPI.types.MessageIdentifier
interface ReplyMessageId {
val replyToMessageId: MessageIdentifier?
}

View File

@@ -1,7 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types
import com.github.insanusmokrassar.TelegramBotAPI.types.TelegramDate
interface UntilDate {
val untilDate: TelegramDate?
}

View File

@@ -1,7 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.bot
import com.github.insanusmokrassar.TelegramBotAPI.utils.TelegramAPIUrlsKeeper
abstract class BaseRequestsExecutor(
protected val telegramAPIUrlsKeeper: TelegramAPIUrlsKeeper
) : RequestsExecutor

View File

@@ -1,13 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.bot.Ktor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.Request
import io.ktor.client.HttpClient
import io.ktor.client.statement.HttpStatement
interface KtorCallFactory {
suspend fun <T: Any> prepareCall(
client: HttpClient,
baseUrl: String,
request: Request<T>
) : HttpStatement?
}

View File

@@ -1,87 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.bot.Ktor
import com.github.insanusmokrassar.TelegramBotAPI.bot.BaseRequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.bot.Ktor.base.MultipartRequestCallFactory
import com.github.insanusmokrassar.TelegramBotAPI.bot.Ktor.base.SimpleRequestCallFactory
import com.github.insanusmokrassar.TelegramBotAPI.bot.exceptions.newRequestException
import com.github.insanusmokrassar.TelegramBotAPI.bot.settings.limiters.EmptyLimiter
import com.github.insanusmokrassar.TelegramBotAPI.bot.settings.limiters.RequestLimiter
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.Request
import com.github.insanusmokrassar.TelegramBotAPI.types.Response
import com.github.insanusmokrassar.TelegramBotAPI.types.RetryAfterError
import com.github.insanusmokrassar.TelegramBotAPI.utils.TelegramAPIUrlsKeeper
import io.ktor.client.HttpClient
import io.ktor.client.call.receive
import io.ktor.client.features.ClientRequestException
import io.ktor.client.statement.HttpStatement
import io.ktor.client.statement.readText
import kotlinx.coroutines.delay
import kotlinx.serialization.json.Json
class KtorRequestsExecutor(
telegramAPIUrlsKeeper: TelegramAPIUrlsKeeper,
private val client: HttpClient = HttpClient(),
callsFactories: List<KtorCallFactory> = emptyList(),
excludeDefaultFactories: Boolean = false,
private val requestsLimiter: RequestLimiter = EmptyLimiter,
private val jsonFormatter: Json = Json.nonstrict
) : BaseRequestsExecutor(telegramAPIUrlsKeeper) {
private val callsFactories: List<KtorCallFactory> = callsFactories.run {
if (!excludeDefaultFactories) {
asSequence().plus(SimpleRequestCallFactory()).plus(MultipartRequestCallFactory()).toList()
} else {
this
}
}
override suspend fun <T : Any> execute(request: Request<T>): T {
return requestsLimiter.limit {
var statement: HttpStatement? = null
for (factory in callsFactories) {
statement = factory.prepareCall(
client,
telegramAPIUrlsKeeper.commonAPIUrl,
request
)
if (statement != null) {
break
}
}
try {
val response = statement ?.execute() ?: throw IllegalArgumentException("Can't execute request: $request")
val content = response.receive<String>()
val responseObject = jsonFormatter.parse(Response.serializer(), content)
(responseObject.result?.let {
jsonFormatter.fromJson(request.resultDeserializer, it)
} ?: responseObject.parameters?.let {
val error = it.error
if (error is RetryAfterError) {
delay(error.leftToRetry)
execute(request)
} else {
null
}
} ?: response.let {
throw newRequestException(
responseObject,
content,
"Can't get result object from $content"
)
})
} catch (e: ClientRequestException) {
val content = e.response.readText()
val responseObject = jsonFormatter.parse(Response.serializer(), content)
throw newRequestException(
responseObject,
content,
"Can't get result object from $content"
)
}
}
}
override fun close() {
client.close()
}
}

View File

@@ -1,42 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.bot.Ktor.base
import com.github.insanusmokrassar.TelegramBotAPI.bot.Ktor.KtorCallFactory
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.Request
import io.ktor.client.HttpClient
import io.ktor.client.request.*
import io.ktor.client.statement.HttpStatement
import io.ktor.http.ContentType
import io.ktor.http.HttpMethod
import kotlin.collections.set
abstract class AbstractRequestCallFactory : KtorCallFactory {
private val methodsCache: MutableMap<String, String> = mutableMapOf()
override suspend fun <T : Any> prepareCall(
client: HttpClient,
baseUrl: String,
request: Request<T>
): HttpStatement? {
val preparedBody = prepareCallBody(client, baseUrl, request) ?: return null
return HttpStatement(
HttpRequestBuilder().apply {
url(
methodsCache[request.method()] ?: "$baseUrl/${request.method()}".also {
methodsCache[request.method()] = it
}
)
method = HttpMethod.Post
accept(ContentType.Application.Json)
body = preparedBody
},
client
)
}
protected abstract fun <T : Any> prepareCallBody(
client: HttpClient,
baseUrl: String,
request: Request<T>
): Any?
}

View File

@@ -1,11 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.bot
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.Request
import io.ktor.utils.io.core.Closeable
interface RequestsExecutor : Closeable {
/**
* @throws com.github.insanusmokrassar.TelegramBotAPI.bot.exceptions.RequestException
*/
suspend fun <T : Any> execute(request: Request<T>): T
}

View File

@@ -1,9 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.bot
import io.ktor.utils.io.core.Closeable
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.Dispatchers
interface UpdatesPoller : Closeable {
fun start(scope: CoroutineScope = CoroutineScope(Dispatchers.Default))
}

View File

@@ -1,67 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.bot.settings.limiters
import com.soywiz.klock.DateTime
import kotlinx.coroutines.*
import kotlinx.coroutines.channels.Channel
private fun now(): Long = DateTime.nowUnixLong()
class CommonLimiter(
private val lockCount: Int = 10,
private val regenTime: Long = 20 * 1000L // 20 seconds for full regen of opportunity to send message
) : RequestLimiter {
private var doLimit: Boolean = false
private val counterChannel = Channel<Unit>(Channel.UNLIMITED)
private val scope = CoroutineScope(Dispatchers.Default)
private val counterJob = scope.launch {
var wasLastSecond = 0
var lastCountTime = now()
var limitManagementJob: Job? = null
var removeLimitTime: Long = lastCountTime
for (counter in counterChannel) {
val now = now()
if (now - lastCountTime > 1000) {
lastCountTime = now
wasLastSecond = 1
} else {
wasLastSecond++
}
if (wasLastSecond >= lockCount) {
removeLimitTime = now + regenTime
if (limitManagementJob == null) {
limitManagementJob = launch {
doLimit = true
var internalNow = now()
while (internalNow < removeLimitTime) {
delay(removeLimitTime - internalNow)
internalNow = now()
}
doLimit = false
}
}
}
if (now > removeLimitTime) {
limitManagementJob = null
}
}
}
private val quoterChannel = Channel<Unit>(Channel.CONFLATED)
private val tickerJob = scope.launch {
while (isActive) {
quoterChannel.send(Unit)
delay(1000L)
}
}
override suspend fun <T> limit(block: suspend () -> T): T {
counterChannel.send(Unit)
return if (!doLimit) {
block()
} else {
quoterChannel.receive()
block()
}
}
}

View File

@@ -1,5 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.bot.settings.limiters
object EmptyLimiter : RequestLimiter {
override suspend fun <T> limit(block: suspend () -> T): T = block()
}

View File

@@ -1,70 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.bot.settings.limiters
import kotlinx.coroutines.*
import kotlinx.coroutines.channels.Channel
import kotlinx.serialization.Serializable
import kotlinx.serialization.Transient
import kotlin.coroutines.*
import kotlin.math.pow
private sealed class RequestEvent
private class AddRequest(
val continuation: Continuation<Long>
) : RequestEvent()
private object CompleteRequest : RequestEvent()
@Serializable
data class PowLimiter(
private val minAwaitTime: Long = 0L,
private val maxAwaitTime: Long = 10000L,
private val powValue: Double = 4.0,
private val powK: Double = 0.0016
) : RequestLimiter {
@Transient
private val scope = CoroutineScope(Dispatchers.Default)
@Transient
private val eventsChannel = Channel<RequestEvent>(Channel.UNLIMITED)
@Transient
private val awaitTimeRange = minAwaitTime .. maxAwaitTime
init {
scope.launch {
var requestsInWork: Double = 0.0
for (event in eventsChannel) {
when (event) {
is AddRequest -> {
val awaitTime = (((requestsInWork.pow(powValue) * powK) * 1000L).toLong())
requestsInWork++
event.continuation.resume(
if (awaitTime in awaitTimeRange) {
awaitTime
} else {
if (awaitTime < minAwaitTime) {
minAwaitTime
} else {
maxAwaitTime
}
}
)
}
is CompleteRequest -> requestsInWork--
}
}
}
}
override suspend fun <T> limit(
block: suspend () -> T
): T {
val delayMillis = suspendCoroutine<Long> {
scope.launch { eventsChannel.send(AddRequest(it)) }
}
delay(delayMillis)
return try {
block()
} finally {
eventsChannel.send(CompleteRequest)
}
}
}

View File

@@ -1,45 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.MessageAction
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.Message
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class DeleteMessage(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(messageIdField)
override val messageId: MessageIdentifier
) : SimpleRequest<Boolean>, MessageAction {
override fun method(): String = "deleteMessage"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.deleteMessage(
chatId: ChatIdentifier,
messageId: MessageIdentifier
) = execute(
DeleteMessage(chatId, messageId)
)
suspend fun RequestsExecutor.deleteMessage(
chat: Chat,
messageId: MessageIdentifier
) = deleteMessage(chat.id, messageId)
suspend fun RequestsExecutor.deleteMessage(
message: Message
) = deleteMessage(message.chat, message.messageId)
suspend fun Message.delete(
requestsExecutor: RequestsExecutor
) = requestsExecutor.deleteMessage(this)

View File

@@ -1,76 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.MessageAction
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.*
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.TelegramBotAPIMessageDeserializationStrategyClass
import kotlinx.serialization.*
private val AbleToBeForwardedMessageDeserializer = TelegramBotAPIMessageDeserializationStrategyClass<PossiblyForwardedMessage>()
@Serializable
data class ForwardMessage(
@SerialName(fromChatIdField)
val fromChatId: ChatIdentifier,
@SerialName(chatIdField)
val toChatId: ChatIdentifier,
@SerialName(messageIdField)
override val messageId: MessageIdentifier,
@SerialName(disableNotificationField)
val disableNotification: Boolean = false
): SimpleRequest<PossiblyForwardedMessage>, MessageAction {
override val chatId: ChatIdentifier
get() = fromChatId
override fun method(): String = "forwardMessage"
override val resultDeserializer: DeserializationStrategy<PossiblyForwardedMessage>
get() = AbleToBeForwardedMessageDeserializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.forwardMessage(
fromChatId: ChatIdentifier,
toChatId: ChatIdentifier,
messageId: MessageIdentifier,
disableNotification: Boolean = false
) = execute(
ForwardMessage(fromChatId, toChatId, messageId, disableNotification)
)
suspend fun RequestsExecutor.forwardMessage(
fromChat: Chat,
toChatId: ChatIdentifier,
messageId: MessageIdentifier,
disableNotification: Boolean = false
) = forwardMessage(fromChat.id, toChatId, messageId, disableNotification)
suspend fun RequestsExecutor.forwardMessage(
fromChatId: ChatIdentifier,
toChat: Chat,
messageId: MessageIdentifier,
disableNotification: Boolean = false
) = forwardMessage(fromChatId, toChat.id, messageId, disableNotification)
suspend fun RequestsExecutor.forwardMessage(
fromChat: Chat,
toChat: Chat,
messageId: MessageIdentifier,
disableNotification: Boolean = false
) = forwardMessage(fromChat.id, toChat.id, messageId, disableNotification)
suspend fun RequestsExecutor.forwardMessage(
toChatId: ChatIdentifier,
message: Message,
disableNotification: Boolean = false
) = forwardMessage(message.chat, toChatId, message.messageId, disableNotification)
suspend fun RequestsExecutor.forwardMessage(
toChat: Chat,
message: Message,
disableNotification: Boolean = false
) = forwardMessage(message.chat, toChat, message.messageId, disableNotification)

View File

@@ -1,17 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import kotlinx.serialization.*
@Serializable
class GetMe : SimpleRequest<ExtendedBot> {
override fun method(): String = "getMe"
override val resultDeserializer: DeserializationStrategy<ExtendedBot>
get() = ExtendedBot.serializer()
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.getMe() = execute(GetMe())

View File

@@ -1,50 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.ALL_UPDATES_LIST
import com.github.insanusmokrassar.TelegramBotAPI.types.UpdateIdentifier
import com.github.insanusmokrassar.TelegramBotAPI.types.update.abstracts.Update
import com.github.insanusmokrassar.TelegramBotAPI.types.update.abstracts.UpdateSerializerWithoutDeserialization
import kotlinx.serialization.*
import kotlinx.serialization.internal.ArrayListSerializer
private val updatesListSerializer = ArrayListSerializer(
UpdateSerializerWithoutDeserialization
)
@Serializable
data class GetUpdates(
val offset: UpdateIdentifier? = null,// set `last update id + 1` to receive next part of updates
val limit: Int? = null,
val timeout: Int? = null,
val allowed_updates: List<String>? = ALL_UPDATES_LIST
): SimpleRequest<List<Update>> {
override fun method(): String = "getUpdates"
override val resultDeserializer: DeserializationStrategy<List<Update>>
get() = updatesListSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.getUpdates(
offset: UpdateIdentifier? = null,
limit: Int? = null,
timeout: Int? = null,
allowed_updates: List<String>? = ALL_UPDATES_LIST
) = execute(
GetUpdates(
offset, limit, timeout, allowed_updates
)
)
suspend fun RequestsExecutor.getUpdates(
lastUpdate: Update,
limit: Int? = null,
timeout: Int? = null,
allowed_updates: List<String>? = ALL_UPDATES_LIST
) = getUpdates(
lastUpdate.updateId + 1, limit, timeout, allowed_updates
)

View File

@@ -1,133 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.LiveLocation.*
import com.github.insanusmokrassar.TelegramBotAPI.requests.send.SendLocation
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.KeyboardMarkup
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.ContentMessage
import com.github.insanusmokrassar.TelegramBotAPI.types.message.content.LocationContent
import com.soywiz.klock.DateTime
import com.soywiz.klock.TimeSpan
import io.ktor.utils.io.core.Closeable
import kotlinx.coroutines.*
import kotlin.math.ceil
private val livePeriodDelayMillis = (livePeriodLimit.last - 60L) * 1000L
class LiveLocation internal constructor(
private val requestsExecutor: RequestsExecutor,
scope: CoroutineScope,
autoCloseTimeDelay: Double,
initMessage: ContentMessage<LocationContent>
) : Closeable {
private val doWhenClose = {
scope.launch {
requestsExecutor.stopLiveLocation(message)
}
}
private val autoCloseTime = DateTime.now() + TimeSpan(autoCloseTimeDelay)
val leftUntilCloseMillis: TimeSpan
get() = autoCloseTime - DateTime.now()
var isClosed: Boolean = false
private set
get() = field || leftUntilCloseMillis.millisecondsLong < 0L
private var message: ContentMessage<LocationContent> = initMessage
val lastLocation: Location
get() = message.content.location
suspend fun updateLocation(
location: Location,
replyMarkup: InlineKeyboardMarkup? = null
): Location {
if (!isClosed) {
message = requestsExecutor.editLiveLocation(
message,
location,
replyMarkup
)
return lastLocation
} else {
error("LiveLocation is closed")
}
}
override fun close() {
if (isClosed) {
return
}
isClosed = true
doWhenClose()
}
}
suspend fun RequestsExecutor.startLiveLocation(
scope: CoroutineScope,
chatId: ChatIdentifier,
latitude: Double,
longitude: Double,
liveTimeMillis: Long = livePeriodDelayMillis,
disableNotification: Boolean = false,
replyToMessageId: MessageIdentifier? = null,
replyMarkup: KeyboardMarkup? = null
): LiveLocation {
val liveTimeAsDouble = liveTimeMillis.toDouble()
val locationMessage = execute(
SendLocation(
chatId,
latitude,
longitude,
ceil(liveTimeAsDouble / 1000).toLong(),
disableNotification,
replyToMessageId,
replyMarkup
)
)
return LiveLocation(
this,
scope,
liveTimeAsDouble,
locationMessage
)
}
suspend fun RequestsExecutor.startLiveLocation(
scope: CoroutineScope,
chat: Chat,
latitude: Double,
longitude: Double,
liveTimeMillis: Long = livePeriodDelayMillis,
disableNotification: Boolean = false,
replyToMessageId: MessageIdentifier? = null,
replyMarkup: KeyboardMarkup? = null
): LiveLocation = startLiveLocation(
scope, chat.id, latitude, longitude, liveTimeMillis, disableNotification, replyToMessageId, replyMarkup
)
suspend fun RequestsExecutor.startLiveLocation(
scope: CoroutineScope,
chatId: ChatId,
location: Location,
liveTimeMillis: Long = livePeriodDelayMillis,
disableNotification: Boolean = false,
replyToMessageId: MessageIdentifier? = null,
replyMarkup: KeyboardMarkup? = null
): LiveLocation = startLiveLocation(
scope, chatId, location.latitude, location.longitude, liveTimeMillis, disableNotification, replyToMessageId, replyMarkup
)
suspend fun RequestsExecutor.startLiveLocation(
scope: CoroutineScope,
chat: Chat,
location: Location,
liveTimeMillis: Long = livePeriodDelayMillis,
disableNotification: Boolean = false,
replyToMessageId: MessageIdentifier? = null,
replyMarkup: KeyboardMarkup? = null
): LiveLocation = startLiveLocation(
scope, chat.id, location.latitude, location.longitude, liveTimeMillis, disableNotification, replyToMessageId, replyMarkup
)

View File

@@ -1,55 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.MessageAction
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ReplyMarkup
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.ReplyMarkup.EditChatMessageReplyMarkup
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.Message
import com.github.insanusmokrassar.TelegramBotAPI.types.polls.Poll
import kotlinx.serialization.*
@Serializable
data class StopPoll(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(messageIdField)
override val messageId: MessageIdentifier,
@SerialName(replyMarkupField)
override val replyMarkup: InlineKeyboardMarkup? = null
) : MessageAction, SimpleRequest<Poll>, ReplyMarkup {
override fun method(): String = "stopPoll"
override val resultDeserializer: DeserializationStrategy<Poll>
get() = Poll.serializer()
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.stopPoll(
chatId: ChatIdentifier,
messageId: MessageIdentifier,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(
StopPoll(chatId, messageId, replyMarkup)
)
suspend fun RequestsExecutor.stopPoll(
chat: Chat,
messageId: MessageIdentifier,
replyMarkup: InlineKeyboardMarkup? = null
) = stopPoll(chat.id, messageId, replyMarkup)
suspend fun RequestsExecutor.stopPoll(
chatId: ChatId,
message: Message,
replyMarkup: InlineKeyboardMarkup? = null
) = stopPoll(chatId, message.messageId, replyMarkup)
suspend fun RequestsExecutor.stopPoll(
chat: Chat,
message: Message,
replyMarkup: InlineKeyboardMarkup? = null
) = stopPoll(chat.id, message.messageId, replyMarkup)

View File

@@ -1,41 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts
import com.github.insanusmokrassar.TelegramBotAPI.utils.StorageFile
import kotlinx.serialization.*
import kotlinx.serialization.internal.StringDescriptor
@Serializable(InputFileSerializer::class)
sealed class InputFile {
abstract val fileId: String
}
// TODO:: add checks for file url/file id regex
/**
* Contains file id or file url
*/
@Serializable(InputFileSerializer::class)
data class FileId(
override val fileId: String
) : InputFile()
fun String.toInputFile() = FileId(this)
@Serializer(InputFile::class)
internal object InputFileSerializer : KSerializer<InputFile> {
override val descriptor: SerialDescriptor = StringDescriptor.withName(FileId::class.toString())
override fun serialize(encoder: Encoder, obj: InputFile) = encoder.encodeString(obj.fileId)
override fun deserialize(decoder: Decoder): FileId = FileId(decoder.decodeString())
}
// TODO:: add checks for files size
/**
* Contains info about file for sending
*/
@Serializable(InputFileSerializer::class)
data class MultipartFile (
val file: StorageFile,
val mimeType: String = file.contentType,
val filename: String = file.fileName
) : InputFile() {
override val fileId: String = file.generateCustomName()
}

View File

@@ -1,12 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts
import com.github.insanusmokrassar.TelegramBotAPI.utils.toJsonWithoutNulls
import kotlinx.serialization.SerializationStrategy
import kotlinx.serialization.json.JsonObject
interface SimpleRequest<T: Any> : Request<T> {
val requestSerializer: SerializationStrategy<*>
}
@Suppress("UNCHECKED_CAST")
inline fun <T: Any, K: SimpleRequest<T>> K.json(): JsonObject = toJsonWithoutNulls(requestSerializer as SerializationStrategy<K>)

View File

@@ -1,51 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.answers
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.CallbackQuery.CallbackQuery
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class AnswerCallbackQuery(
@SerialName(callbackQueryIdField)
val callbackQueryId: CallbackQueryIdentifier,
@SerialName(textField)
val text: String? = null,
@SerialName(showAlertField)
val showAlert: Boolean? = null,
@SerialName(urlField)
val url: String? = null,
@SerialName(cachedTimeField)
val cachedTimeSeconds: Int? = null
) : SimpleRequest<Boolean> {
override fun method(): String = "answerCallbackQuery"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
fun CallbackQuery.createAnswer(
text: String? = null,
showAlert: Boolean? = null,
url: String? = null,
cachedTimeSeconds: Int? = null
): AnswerCallbackQuery = AnswerCallbackQuery(id, text, showAlert, url, cachedTimeSeconds)
suspend fun RequestsExecutor.answerCallbackQuery(
callbackQueryId: CallbackQueryIdentifier,
text: String? = null,
showAlert: Boolean? = null,
url: String? = null,
cachedTimeSeconds: Int? = null
) = execute(AnswerCallbackQuery(callbackQueryId, text, showAlert, url, cachedTimeSeconds))
suspend fun RequestsExecutor.answerCallbackQuery(
callbackQuery: CallbackQuery,
text: String? = null,
showAlert: Boolean? = null,
url: String? = null,
cachedTimeSeconds: Int? = null
) = answerCallbackQuery(callbackQuery.id, text, showAlert, url, cachedTimeSeconds)

View File

@@ -1,79 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.answers
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.InlineQueryResult.abstracts.InlineQueryResult
import com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.InlineQueryResult.serializers.InlineQueryResultSerializer
import com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.abstracts.InlineQuery
import kotlinx.serialization.*
import kotlinx.serialization.internal.ArrayListSerializer
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class AnswerInlineQuery(
@SerialName(inlineQueryIdField)
val inlineQueryID: InlineQueryIdentifier,
@Serializable(InlineQueryAnswersResultsSerializer::class)
@SerialName(resultsField)
val results: List<InlineQueryResult> = emptyList(),
@SerialName(cachedTimeField)
val cachedTime: Int? = null,
@SerialName(isPersonalField)
val isPersonal: Boolean? = null,
@SerialName(nextOffsetField)
val nextOffset: String? = null,
@SerialName(switchPmTextField)
val switchPmText: String? = null,
@SerialName(switchPmParameterField)
val switchPmParameter: String? = null
): SimpleRequest<Boolean> {
override fun method(): String = "answerInlineQuery"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
fun InlineQuery.createAnswer(
results: List<InlineQueryResult> = emptyList(),
cachedTime: Int? = null,
isPersonal: Boolean? = null,
nextOffset: String? = null,
switchPmText: String? = null,
switchPmParameter: String? = null
) = AnswerInlineQuery(
id,
results,
cachedTime,
isPersonal,
nextOffset,
switchPmText,
switchPmParameter
)
suspend fun RequestsExecutor.answerInlineQuery(
inlineQueryID: InlineQueryIdentifier,
results: List<InlineQueryResult> = emptyList(),
cachedTime: Int? = null,
isPersonal: Boolean? = null,
nextOffset: String? = null,
switchPmText: String? = null,
switchPmParameter: String? = null
) = execute(
AnswerInlineQuery(inlineQueryID, results, cachedTime, isPersonal, nextOffset, switchPmText, switchPmParameter)
)
suspend fun RequestsExecutor.answerInlineQuery(
inlineQuery: InlineQuery,
results: List<InlineQueryResult> = emptyList(),
cachedTime: Int? = null,
isPersonal: Boolean? = null,
nextOffset: String? = null,
switchPmText: String? = null,
switchPmParameter: String? = null
) = answerInlineQuery(inlineQuery.id, results, cachedTime, isPersonal, nextOffset, switchPmText, switchPmParameter)
internal object InlineQueryAnswersResultsSerializer: KSerializer<List<InlineQueryResult>> by ArrayListSerializer(
InlineQueryResultSerializer
)

View File

@@ -1,15 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.answers.payments.abstracts
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.PreCheckoutQueryId
import kotlinx.serialization.KSerializer
import kotlinx.serialization.internal.BooleanSerializer
interface AnswerPreCheckoutQuery : SimpleRequest<Boolean> {
override fun method(): String = "answerPreCheckoutQuery"
override val resultDeserializer: KSerializer<Boolean>
get() = BooleanSerializer
val preCheckoutQueryId: PreCheckoutQueryId
val isOk: Boolean
}

View File

@@ -1,15 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.answers.payments.abstracts
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.ShippingQueryIdentifier
import kotlinx.serialization.DeserializationStrategy
import kotlinx.serialization.internal.BooleanSerializer
interface AnswerShippingQuery : SimpleRequest<Boolean> {
override fun method(): String = "answerShippingQuery"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
val shippingQueryId: ShippingQueryIdentifier
val isOk: Boolean
}

View File

@@ -1,31 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField
import kotlinx.serialization.*
import kotlinx.serialization.internal.StringSerializer
@Serializable
data class ExportChatInviteLink(
@SerialName(chatIdField)
override val chatId: ChatIdentifier
): ChatRequest, SimpleRequest<String> {
override fun method(): String = "exportChatInviteLink"
override val resultDeserializer: DeserializationStrategy<String>
get() = StringSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.exportChatInviteLink(
chatId: ChatIdentifier
) = execute(ExportChatInviteLink(chatId))
suspend fun RequestsExecutor.exportChatInviteLink(
chat: PublicChat
) = exportChatInviteLink(chat.id)

View File

@@ -1,31 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class LeaveChat(
@SerialName(chatIdField)
override val chatId: ChatIdentifier
): ChatRequest, SimpleRequest<Boolean> {
override fun method(): String = "leaveChat"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.leaveChat(
chatId: ChatIdentifier
) = execute(LeaveChat(chatId))
suspend fun RequestsExecutor.leaveChat(
chat: PublicChat
) = leaveChat(chat.id)

View File

@@ -1,9 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.abstracts
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.UserId
interface ChatMemberRequest<T: Any> : ChatRequest, SimpleRequest<T> {
val userId: UserId
}

View File

@@ -1,31 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.get
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.ExtendedChatSerializer
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.extended.ExtendedChat
import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField
import kotlinx.serialization.*
@Serializable
data class GetChat(
@SerialName(chatIdField)
override val chatId: ChatIdentifier
): ChatRequest, SimpleRequest<ExtendedChat> {
override fun method(): String = "getChat"
override val resultDeserializer: DeserializationStrategy<ExtendedChat>
get() = ExtendedChatSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.getChat(
chatId: ChatIdentifier
) = execute(GetChat(chatId))
suspend fun RequestsExecutor.getChat(
chat: Chat
) = getChat(chat.id)

View File

@@ -1,37 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.get
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatMember.abstracts.AdministratorChatMember
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatMember.abstracts.AdministratorChatMemberSerializerWithoutDeserialization
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField
import kotlinx.serialization.*
import kotlinx.serialization.internal.ArrayListSerializer
private val chatMembersListSerializer = ArrayListSerializer(
AdministratorChatMemberSerializerWithoutDeserialization
)
@Serializable
data class GetChatAdministrators(
@SerialName(chatIdField)
override val chatId: ChatIdentifier
): ChatRequest, SimpleRequest<List<AdministratorChatMember>> {
override fun method(): String = "getChatAdministrators"
override val resultDeserializer: DeserializationStrategy<List<AdministratorChatMember>>
get() = chatMembersListSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.getChatAdministrators(
chatId: ChatIdentifier
) = execute(GetChatAdministrators(chatId))
suspend fun RequestsExecutor.getChatAdministrators(
chat: PublicChat
) = getChatAdministrators(chat.id)

View File

@@ -1,31 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.get
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField
import kotlinx.serialization.*
import kotlinx.serialization.internal.IntSerializer
@Serializable
data class GetChatMembersCount(
@SerialName(chatIdField)
override val chatId: ChatIdentifier
): ChatRequest, SimpleRequest<Int> {
override fun method(): String = "getChatMembersCount"
override val resultDeserializer: DeserializationStrategy<Int>
get() = IntSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.getChatMembersCount(
chatId: ChatIdentifier
) = execute(GetChatMembersCount(chatId))
suspend fun RequestsExecutor.getChatMembersCount(
chat: PublicChat
) = getChatMembersCount(chat.id)

View File

@@ -1,45 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.members
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.chat.abstracts.ChatMemberRequest
import com.github.insanusmokrassar.TelegramBotAPI.requests.chat.get.getChatMembersCount
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatMember.abstracts.ChatMember
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatMember.abstracts.ChatMemberDeserializationStrategy
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import kotlinx.serialization.*
@Serializable
data class GetChatMember(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(userIdField)
override val userId: UserId
) : ChatMemberRequest<ChatMember> {
override fun method(): String = "getChatMember"
override val resultDeserializer: DeserializationStrategy<ChatMember>
get() = ChatMemberDeserializationStrategy
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.getChatMember(
chatId: ChatIdentifier,
userId: UserId
) = execute(GetChatMember(chatId, userId))
suspend fun RequestsExecutor.getChatMember(
chat: PublicChat,
userId: UserId
) = getChatMember(chat.id, userId)
suspend fun RequestsExecutor.getChatMember(
chatId: ChatId,
user: User
) = getChatMember(chatId, user.id)
suspend fun RequestsExecutor.getChatMember(
chat: PublicChat,
user: User
) = getChatMember(chat.id, user.id)

View File

@@ -1,50 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.members
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.UntilDate
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.chat.abstracts.ChatMemberRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class KickChatMember(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(userIdField)
override val userId: UserId,
@SerialName(untilDateField)
override val untilDate: TelegramDate? = null
) : ChatMemberRequest<Boolean>, UntilDate {
override fun method(): String = "kickChatMember"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.kickChatMember(
chatId: ChatIdentifier,
userId: UserId,
untilDate: TelegramDate? = null
) = execute(KickChatMember(chatId, userId, untilDate))
suspend fun RequestsExecutor.kickChatMember(
chat: PublicChat,
userId: UserId,
untilDate: TelegramDate? = null
) = kickChatMember(chat.id, userId, untilDate)
suspend fun RequestsExecutor.kickChatMember(
chatId: ChatId,
user: User,
untilDate: TelegramDate? = null
) = kickChatMember(chatId, user.id, untilDate)
suspend fun RequestsExecutor.kickChatMember(
chat: PublicChat,
user: User,
untilDate: TelegramDate? = null
) = kickChatMember(chat.id, user.id, untilDate)

View File

@@ -1,58 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.members
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.UntilDate
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.chat.abstracts.ChatMemberRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.ChatPermissions
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class RestrictChatMember(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(userIdField)
override val userId: UserId,
@SerialName(untilDateField)
override val untilDate: TelegramDate? = null,
@SerialName(permissionsField)
val permissions: ChatPermissions = ChatPermissions()
) : ChatMemberRequest<Boolean>, UntilDate {
override fun method(): String = "restrictChatMember"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.restrictChatMember(
chatId: ChatIdentifier,
userId: UserId,
untilDate: TelegramDate? = null,
permissions: ChatPermissions = ChatPermissions()
) = execute(RestrictChatMember(chatId, userId, untilDate, permissions))
suspend fun RequestsExecutor.restrictChatMember(
chat: PublicChat,
userId: UserId,
untilDate: TelegramDate? = null,
permissions: ChatPermissions = ChatPermissions()
) = restrictChatMember(chat.id, userId, untilDate, permissions)
suspend fun RequestsExecutor.restrictChatMember(
chatId: ChatId,
user: User,
untilDate: TelegramDate? = null,
permissions: ChatPermissions = ChatPermissions()
) = restrictChatMember(chatId, user.id, untilDate, permissions)
suspend fun RequestsExecutor.restrictChatMember(
chat: PublicChat,
user: User,
untilDate: TelegramDate? = null,
permissions: ChatPermissions = ChatPermissions()
) = restrictChatMember(chat.id, user.id, untilDate, permissions)

View File

@@ -1,60 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.members
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.chat.abstracts.ChatMemberRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
/**
* Representation of https://core.telegram.org/bots/api#setchatadministratorcustomtitle
*
* Please, remember about restrictions for characters in custom title
*/
@Serializable
data class SetChatAdministratorCustomTitle(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(userIdField)
override val userId: UserId,
@SerialName(customTitleField)
val customTitle: String
) : ChatMemberRequest<Boolean> {
override fun method(): String = "setChatAdministratorCustomTitle"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = RestrictChatMember.serializer()
init {
if (customTitle.length !in customTitleLength) {
throw IllegalArgumentException("Custom title length must be in range $customTitleLength, but was ${customTitle.length}")
}
}
}
suspend fun RequestsExecutor.setChatAdministratorCustomTitle(
chatId: ChatId,
userId: UserId,
customTitle: String
) = execute(SetChatAdministratorCustomTitle(chatId, userId, customTitle))
suspend fun RequestsExecutor.setChatAdministratorCustomTitle(
chat: PublicChat,
userId: UserId,
customTitle: String
) = setChatAdministratorCustomTitle(chat.id, userId, customTitle)
suspend fun RequestsExecutor.setChatAdministratorCustomTitle(
chatId: ChatId,
user: User,
customTitle: String
) = setChatAdministratorCustomTitle(chatId, user.id, customTitle)
suspend fun RequestsExecutor.setChatAdministratorCustomTitle(
chat: PublicChat,
user: User,
customTitle: String
) = setChatAdministratorCustomTitle(chat.id, user.id, customTitle)

View File

@@ -1,44 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.members
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.chat.abstracts.ChatMemberRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class UnbanChatMember(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(userIdField)
override val userId: UserId
) : ChatMemberRequest<Boolean> {
override fun method(): String = "unbanChatMember"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.unbanChatMember(
chatId: ChatIdentifier,
userId: UserId
) = execute(UnbanChatMember(chatId, userId))
suspend fun RequestsExecutor.unbanChatMember(
chat: PublicChat,
userId: UserId
) = unbanChatMember(chat.id, userId)
suspend fun RequestsExecutor.unbanChatMember(
chatId: ChatId,
user: User
) = unbanChatMember(chatId, user.id)
suspend fun RequestsExecutor.unbanChatMember(
chat: PublicChat,
user: User
) = unbanChatMember(chat.id, user.id)

View File

@@ -1,32 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.requests.chat.get.GetChat
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class DeleteChatPhoto(
@SerialName(chatIdField)
override val chatId: ChatIdentifier
): ChatRequest, SimpleRequest<Boolean> {
override fun method(): String = "deleteChatPhoto"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.deleteChatPhoto(
chatId: ChatIdentifier
) = execute(DeleteChatPhoto(chatId))
suspend fun RequestsExecutor.deleteChatPhoto(
chat: PublicChat
) = deleteChatPhoto(chat.id)

View File

@@ -1,48 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.*
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.Message
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class PinChatMessage (
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(messageIdField)
override val messageId: MessageIdentifier,
@SerialName(disableNotificationField)
override val disableNotification: Boolean = false
): ChatRequest, SimpleRequest<Boolean>, MessageAction, DisableNotification {
override fun method(): String = "pinChatMessage"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.pinChatMessage(
chatId: ChatIdentifier,
messageId: MessageIdentifier,
disableNotification: Boolean = false
) = execute(PinChatMessage(chatId, messageId, disableNotification))
suspend fun RequestsExecutor.pinChatMessage(
chat: PublicChat,
messageId: MessageIdentifier,
disableNotification: Boolean = false
) = pinChatMessage(chat.id, messageId, disableNotification)
suspend fun RequestsExecutor.pinChatMessage(
message: Message,
disableNotification: Boolean = false
) = if (message.chat is PublicChat) {
pinChatMessage(message.chat.id, message.messageId, disableNotification)
} else {
error("It is possible to pin messages only in non one-to-one chats")
}

View File

@@ -1,40 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class SetChatDescription (
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(descriptionField)
val description: String
): ChatRequest, SimpleRequest<Boolean> {
init {
if (description.length !in chatDescriptionLength) {
throw IllegalArgumentException("Chat description must be in $chatDescriptionLength range")
}
}
override fun method(): String = "setChatDescription"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.setChatDescription(
chatId: ChatIdentifier,
description: String
) = execute(SetChatDescription(chatId, description))
suspend fun RequestsExecutor.setChatDescription(
chat: PublicChat,
description: String
) = setChatDescription(chat.id, description)

View File

@@ -1,34 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.ChatPermissions
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class SetChatPermissions (
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(permissionsField)
val permissions: ChatPermissions
): ChatRequest, SimpleRequest<Boolean> {
override fun method(): String = "setChatPermissions"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.setDefaultChatMembersPermissions(
chatId: ChatIdentifier,
permissions: ChatPermissions
) = execute(SetChatPermissions(chatId, permissions))
suspend fun RequestsExecutor.setDefaultChatMembersPermissions(
chat: PublicChat,
permissions: ChatPermissions
) = setDefaultChatMembersPermissions(chat.id, permissions)

View File

@@ -1,37 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.MultipartFile
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.MultipartRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.ChatPermissions
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import com.github.insanusmokrassar.TelegramBotAPI.utils.toJson
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
import kotlinx.serialization.json.JsonObject
@Serializable
data class SetChatPhoto (
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
val photo: MultipartFile = throw IllegalArgumentException("Unfortunately, this type of objects can't be parsed automatically")
): ChatRequest, MultipartRequest<Boolean> {
override fun method(): String = "setChatPhoto"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val mediaMap: Map<String, MultipartFile> = mapOf(photoField to photo)
override val paramsJson: JsonObject = toJson(serializer())
}
suspend fun RequestsExecutor.setChatPhoto(
chatId: ChatIdentifier,
photo: MultipartFile
) = execute(SetChatPhoto(chatId, photo))
suspend fun RequestsExecutor.setChatPhoto(
chat: PublicChat,
photo: MultipartFile
) = setChatPhoto(chat.id, photo)

View File

@@ -1,41 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.MultipartFile
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class SetChatTitle (
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(titleField)
val title: String
): ChatRequest, SimpleRequest<Boolean> {
init {
if (title.length !in chatTitleLength) {
throw IllegalArgumentException("Chat title must be in $chatTitleLength range")
}
}
override fun method(): String = "setChatTitle"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.setChatTitle(
chatId: ChatIdentifier,
title: String
) = execute(SetChatTitle(chatId, title))
suspend fun RequestsExecutor.setChatTitle(
chat: PublicChat,
title: String
) = setChatTitle(chat.id, title)

View File

@@ -1,31 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.PublicChat
import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class UnpinChatMessage(
@SerialName(chatIdField)
override val chatId: ChatIdentifier
): ChatRequest, SimpleRequest<Boolean> {
override fun method(): String = "unpinChatMessage"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.unpinChatMessage(
chatId: ChatIdentifier
) = execute(UnpinChatMessage(chatId))
suspend fun RequestsExecutor.unpinChatMessage(
chat: PublicChat
) = unpinChatMessage(chat.id)

View File

@@ -1,31 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.stickers
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify.DeleteChatPhoto
import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class DeleteChatStickerSet(
@SerialName(chatIdField)
override val chatId: ChatIdentifier
): ChatRequest, SimpleRequest<Boolean> {
override fun method(): String = "deleteChatStickerSet"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.deleteChatStickerSet(
chatId: ChatIdentifier
) = execute(DeleteChatStickerSet(chatId))
suspend fun RequestsExecutor.deleteChatStickerSet(
chat: SupergroupChat
) = deleteChatStickerSet(chat.id)

View File

@@ -1,33 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.stickers
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.*
import kotlinx.serialization.*
import kotlinx.serialization.internal.BooleanSerializer
@Serializable
data class SetChatStickerSet(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(stickerSetNameField)
val stickerSetName: StickerSetName
): ChatRequest, SimpleRequest<Boolean> {
override fun method(): String = "setChatStickerSet"
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.setChatStickerSet(
chatId: ChatIdentifier,
stickerSetName: StickerSetName
) = execute(SetChatStickerSet(chatId, stickerSetName))
suspend fun RequestsExecutor.setChatStickerSet(
chat: SupergroupChat,
stickerSetName: StickerSetName
) = setChatStickerSet(chat.id, stickerSetName)

View File

@@ -1,84 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.LiveLocation
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.*
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.ContentMessage
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.TelegramBotAPIMessageDeserializationStrategyClass
import com.github.insanusmokrassar.TelegramBotAPI.types.message.content.LocationContent
import kotlinx.serialization.*
private val commonResultDeserializer = TelegramBotAPIMessageDeserializationStrategyClass<ContentMessage<LocationContent>>()
@Serializable
data class EditChatMessageLiveLocation(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(messageIdField)
override val messageId: MessageIdentifier,
@SerialName(latitudeField)
override val latitude: Double,
@SerialName(longitudeField)
override val longitude: Double,
@SerialName(replyMarkupField)
override val replyMarkup: InlineKeyboardMarkup? = null
) : EditChatMessage<LocationContent>, EditReplyMessage, EditLocationMessage {
override fun method(): String = "editMessageLiveLocation"
override val resultDeserializer: DeserializationStrategy<ContentMessage<LocationContent>>
get() = commonResultDeserializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.editLiveLocation(
chatId: ChatIdentifier,
messageId: MessageIdentifier,
latitude: Double,
longitude: Double,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(
EditChatMessageLiveLocation(
chatId, messageId, latitude, longitude, replyMarkup
)
)
suspend fun RequestsExecutor.editLiveLocation(
chat: Chat,
messageId: MessageIdentifier,
latitude: Double,
longitude: Double,
replyMarkup: InlineKeyboardMarkup? = null
) = editLiveLocation(chat.id, messageId, latitude, longitude, replyMarkup)
suspend fun RequestsExecutor.editLiveLocation(
message: ContentMessage<LocationContent>,
latitude: Double,
longitude: Double,
replyMarkup: InlineKeyboardMarkup? = null
) = editLiveLocation(message.chat, message.messageId, latitude, longitude, replyMarkup)
suspend fun RequestsExecutor.editLiveLocation(
chatId: ChatIdentifier,
messageId: MessageIdentifier,
location: Location,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(
EditChatMessageLiveLocation(
chatId, messageId, location.latitude, location.longitude, replyMarkup
)
)
suspend fun RequestsExecutor.editLiveLocation(
chat: Chat,
messageId: MessageIdentifier,
location: Location,
replyMarkup: InlineKeyboardMarkup? = null
) = editLiveLocation(chat.id, messageId, location.latitude, location.longitude, replyMarkup)
suspend fun RequestsExecutor.editLiveLocation(
message: ContentMessage<LocationContent>,
location: Location,
replyMarkup: InlineKeyboardMarkup? = null
) = editLiveLocation(message.chat, message.messageId, location.latitude, location.longitude, replyMarkup)

View File

@@ -1,39 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.LiveLocation
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.*
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import kotlinx.serialization.*
@Serializable
data class EditInlineMessageLiveLocation(
@SerialName(inlineMessageIdField)
override val inlineMessageId: InlineMessageIdentifier,
@SerialName(latitudeField)
override val latitude: Double,
@SerialName(longitudeField)
override val longitude: Double,
@SerialName(replyMarkupField)
override val replyMarkup: InlineKeyboardMarkup? = null
) : EditInlineMessage, EditReplyMessage, EditLocationMessage {
override fun method(): String = "editMessageLiveLocation"
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.editLiveLocation(
inlineMessageId: InlineMessageIdentifier,
latitude: Double,
longitude: Double,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(
EditInlineMessageLiveLocation(
inlineMessageId, latitude, longitude, replyMarkup
)
)
suspend fun RequestsExecutor.editLiveLocation(
inlineMessageId: InlineMessageIdentifier,
location: Location,
replyMarkup: InlineKeyboardMarkup? = null
) = editLiveLocation(inlineMessageId, location.latitude, location.longitude, replyMarkup)

View File

@@ -1,52 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.LiveLocation
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.EditChatMessage
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.EditReplyMessage
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.ContentMessage
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.TelegramBotAPIMessageDeserializationStrategyClass
import com.github.insanusmokrassar.TelegramBotAPI.types.message.content.LocationContent
import kotlinx.serialization.*
private val commonResultDeserializer = TelegramBotAPIMessageDeserializationStrategyClass<ContentMessage<LocationContent>>()
@Serializable
data class StopChatMessageLiveLocation(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(messageIdField)
override val messageId: MessageIdentifier,
@SerialName(replyMarkupField)
override val replyMarkup: InlineKeyboardMarkup? = null
) : EditChatMessage<LocationContent>, EditReplyMessage {
override fun method(): String = "stopMessageLiveLocation"
override val resultDeserializer: DeserializationStrategy<ContentMessage<LocationContent>>
get() = commonResultDeserializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.stopLiveLocation(
chatId: ChatIdentifier,
messageId: MessageIdentifier,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(
StopChatMessageLiveLocation(
chatId, messageId, replyMarkup
)
)
suspend fun RequestsExecutor.stopLiveLocation(
chat: Chat,
messageId: MessageIdentifier,
replyMarkup: InlineKeyboardMarkup? = null
) = stopLiveLocation(chat.id, messageId, replyMarkup)
suspend fun RequestsExecutor.stopLiveLocation(
message: ContentMessage<LocationContent>,
replyMarkup: InlineKeyboardMarkup? = null
) = stopLiveLocation(message.chat, message.messageId, replyMarkup)

View File

@@ -1,29 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.LiveLocation
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.EditInlineMessage
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.EditReplyMessage
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import kotlinx.serialization.*
@Serializable
data class StopInlineMessageLiveLocation(
@SerialName(inlineMessageIdField)
override val inlineMessageId: InlineMessageIdentifier,
@SerialName(replyMarkupField)
override val replyMarkup: InlineKeyboardMarkup? = null
) : EditInlineMessage, EditReplyMessage {
override fun method(): String = "stopMessageLiveLocation"
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.stopLiveLocation(
inlineMessageId: InlineMessageIdentifier,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(
StopInlineMessageLiveLocation(
inlineMessageId, replyMarkup
)
)

View File

@@ -1,55 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.ReplyMarkup
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.EditChatMessage
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.EditReplyMessage
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.media.EditChatMessageMedia
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.InputMedia.InputMedia
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.*
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.TelegramBotAPIMessageDeserializationStrategyClass
import com.github.insanusmokrassar.TelegramBotAPI.types.message.content.abstracts.MessageContent
import kotlinx.serialization.*
const val editMessageReplyMarkupMethod = "editMessageReplyMarkup"
private val commonResultDeserializer = TelegramBotAPIMessageDeserializationStrategyClass<ContentMessage<MessageContent>>()
@Serializable
data class EditChatMessageReplyMarkup(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(messageIdField)
override val messageId: MessageIdentifier,
@SerialName(replyMarkupField)
override val replyMarkup: InlineKeyboardMarkup? = null
) : EditChatMessage<MessageContent>, EditReplyMessage {
override fun method(): String = editMessageReplyMarkupMethod
override val resultDeserializer: DeserializationStrategy<ContentMessage<MessageContent>>
get() = commonResultDeserializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.editMessageReplyMarkup(
chatId: ChatIdentifier,
messageId: MessageIdentifier,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(
EditChatMessageReplyMarkup(chatId, messageId, replyMarkup)
)
suspend fun RequestsExecutor.editMessageReplyMarkup(
chat: Chat,
messageId: MessageIdentifier,
replyMarkup: InlineKeyboardMarkup? = null
) = editMessageReplyMarkup(chat.id, messageId, replyMarkup)
suspend fun RequestsExecutor.editMessageReplyMarkup(
message: Message,
replyMarkup: InlineKeyboardMarkup? = null
) = editMessageReplyMarkup(message.chat.id, message.messageId, replyMarkup)

View File

@@ -1,27 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.ReplyMarkup
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.EditInlineMessage
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.EditReplyMessage
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.media.EditInlineMessageMedia
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.InputMedia.InputMedia
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import kotlinx.serialization.*
@Serializable
data class EditInlineMessageReplyMarkup(
@SerialName(inlineMessageIdField)
override val inlineMessageId: InlineMessageIdentifier,
@SerialName(replyMarkupField)
override val replyMarkup: InlineKeyboardMarkup? = null
) : EditInlineMessage, EditReplyMessage {
override fun method(): String = editMessageReplyMarkupMethod
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.editMessageReplyMarkup(
inlineMessageId: InlineMessageIdentifier,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(EditInlineMessageReplyMarkup(inlineMessageId, replyMarkup))

View File

@@ -1,8 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.MessageAction
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.ContentMessage
import com.github.insanusmokrassar.TelegramBotAPI.types.message.content.abstracts.MessageContent
interface EditChatMessage<MT: MessageContent> : SimpleRequest<ContentMessage<MT>>, MessageAction

View File

@@ -1,12 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest
import com.github.insanusmokrassar.TelegramBotAPI.types.InlineMessageIdentifier
import kotlinx.serialization.DeserializationStrategy
import kotlinx.serialization.internal.BooleanSerializer
interface EditInlineMessage : SimpleRequest<Boolean> {
val inlineMessageId: InlineMessageIdentifier
override val resultDeserializer: DeserializationStrategy<Boolean>
get() = BooleanSerializer
}

View File

@@ -1,6 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts
interface EditLocationMessage {
val latitude: Double
val longitude: Double
}

View File

@@ -1,7 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts
import com.github.insanusmokrassar.TelegramBotAPI.types.InputMedia.InputMedia
interface EditMediaMessage {
val media: InputMedia
}

View File

@@ -1,8 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ReplyMarkup
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
interface EditReplyMessage : ReplyMarkup {
override val replyMarkup: InlineKeyboardMarkup?
}

View File

@@ -1,8 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts
import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.ParseMode
interface EditTextChatMessage {
val text: String
val parseMode: ParseMode?
}

View File

@@ -1,69 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.caption
import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.CaptionedInput
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.*
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.media.MediaContentMessageResultDeserializer
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.text.EditChatMessageText
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.ParseMode
import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.parseModeField
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.message.CommonMessageImpl
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.ContentMessage
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.Message
import com.github.insanusmokrassar.TelegramBotAPI.types.message.content.abstracts.MediaContent
import com.github.insanusmokrassar.TelegramBotAPI.types.message.content.abstracts.MessageContent
import com.github.insanusmokrassar.TelegramBotAPI.types.message.content.media.PhotoContent
import kotlinx.serialization.*
const val editMessageCaptionMethod = "editMessageCaption"
@Serializable
data class EditChatMessageCaption(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(messageIdField)
override val messageId: MessageIdentifier,
@SerialName(captionField)
override val text: String,
@SerialName(parseModeField)
override val parseMode: ParseMode? = null,
@SerialName(replyMarkupField)
override val replyMarkup: InlineKeyboardMarkup? = null
) : EditChatMessage<MediaContent>, EditTextChatMessage, EditReplyMessage {
override fun method(): String = editMessageCaptionMethod
override val resultDeserializer: DeserializationStrategy<ContentMessage<MediaContent>>
get() = MediaContentMessageResultDeserializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.editMessageCaption(
chatId: ChatIdentifier,
messageId: MessageIdentifier,
text: String,
parseMode: ParseMode? = null,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(
EditChatMessageCaption(chatId, messageId, text, parseMode, replyMarkup)
)
suspend fun RequestsExecutor.editMessageCaption(
chat: Chat,
messageId: MessageIdentifier,
text: String,
parseMode: ParseMode? = null,
replyMarkup: InlineKeyboardMarkup? = null
) = editMessageCaption(chat.id, messageId, text, parseMode, replyMarkup)
suspend fun <T> RequestsExecutor.editMessageCaption(
message: ContentMessage<T>,
text: String,
parseMode: ParseMode? = null,
replyMarkup: InlineKeyboardMarkup? = null
): ContentMessage<MediaContent> where T : CaptionedInput, T : MediaContent {
return editMessageCaption(message.chat.id, message.messageId, text, parseMode, replyMarkup)
}

View File

@@ -1,33 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.caption
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.*
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.text.EditInlineMessageText
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.ParseMode
import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.parseModeField
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import kotlinx.serialization.*
@Serializable
data class EditInlineMessageCaption(
@SerialName(inlineMessageIdField)
override val inlineMessageId: InlineMessageIdentifier,
@SerialName(captionField)
override val text: String,
@SerialName(parseModeField)
override val parseMode: ParseMode? = null,
@SerialName(replyMarkupField)
override val replyMarkup: InlineKeyboardMarkup? = null
) : EditInlineMessage, EditTextChatMessage, EditReplyMessage {
override fun method(): String = editMessageCaptionMethod
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.editMessageCaption(
inlineMessageId: InlineMessageIdentifier,
text: String,
parseMode: ParseMode? = null,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(EditInlineMessageCaption(inlineMessageId, text, parseMode, replyMarkup))

View File

@@ -1,69 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.media
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.MultipartFile
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.*
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.caption.EditChatMessageCaption
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.InputMedia.InputMedia
import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.ParseMode
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.message.CommonMessageImpl
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.*
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.TelegramBotAPIMessageDeserializationStrategyClass
import com.github.insanusmokrassar.TelegramBotAPI.types.message.content.TextContent
import com.github.insanusmokrassar.TelegramBotAPI.types.message.content.abstracts.MediaContent
import com.github.insanusmokrassar.TelegramBotAPI.types.message.content.media.PhotoContent
import kotlinx.serialization.*
const val editMessageMediaMethod = "editMessageMedia"
internal val MediaContentMessageResultDeserializer = TelegramBotAPIMessageDeserializationStrategyClass<ContentMessage<MediaContent>>()
@Serializable
data class EditChatMessageMedia(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(messageIdField)
override val messageId: MessageIdentifier,
@SerialName(mediaField)
override val media: InputMedia,
@SerialName(replyMarkupField)
override val replyMarkup: InlineKeyboardMarkup? = null
) : EditChatMessage<MediaContent>, EditReplyMessage, EditMediaMessage {
init {
if (media.file is MultipartFile) {
throw IllegalArgumentException("For editing of media messages you MUST use file id (according to documentation)")
}
}
override fun method(): String = editMessageMediaMethod
override val resultDeserializer: DeserializationStrategy<ContentMessage<MediaContent>>
get() = MediaContentMessageResultDeserializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.editMessageMedia(
chatId: ChatIdentifier,
messageId: MessageIdentifier,
media: InputMedia,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(
EditChatMessageMedia(chatId, messageId, media, replyMarkup)
)
suspend fun RequestsExecutor.editMessageMedia(
chat: Chat,
messageId: MessageIdentifier,
media: InputMedia,
replyMarkup: InlineKeyboardMarkup? = null
) = editMessageMedia(chat.id, messageId, media, replyMarkup)
suspend fun RequestsExecutor.editMessageMedia(
message: ContentMessage<out MediaContent>,
media: InputMedia,
replyMarkup: InlineKeyboardMarkup? = null
) = editMessageMedia(message.chat.id, message.messageId, media, replyMarkup)

View File

@@ -1,38 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.media
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.MultipartFile
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.*
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.caption.EditInlineMessageCaption
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.InputMedia.InputMedia
import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.ParseMode
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import kotlinx.serialization.*
@Serializable
data class EditInlineMessageMedia(
@SerialName(inlineMessageIdField)
override val inlineMessageId: InlineMessageIdentifier,
@SerialName(mediaField)
override val media: InputMedia,
@SerialName(replyMarkupField)
override val replyMarkup: InlineKeyboardMarkup? = null
) : EditInlineMessage, EditReplyMessage, EditMediaMessage {
init {
if (media.file is MultipartFile) {
throw IllegalArgumentException("For editing of media messages you MUST use file id (according to documentation)")
}
}
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
override fun method(): String = editMessageMediaMethod
}
suspend fun RequestsExecutor.editMessageCaption(
inlineMessageId: InlineMessageIdentifier,
media: InputMedia,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(EditInlineMessageMedia(inlineMessageId, media, replyMarkup))

View File

@@ -1,67 +0,0 @@
package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.text
import com.github.insanusmokrassar.TelegramBotAPI.bot.RequestsExecutor
import com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts.*
import com.github.insanusmokrassar.TelegramBotAPI.requests.send.TextContentMessageResultDeserializer
import com.github.insanusmokrassar.TelegramBotAPI.types.*
import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.ParseMode
import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.parseModeField
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.ContentMessage
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.Message
import com.github.insanusmokrassar.TelegramBotAPI.types.message.content.TextContent
import kotlinx.serialization.*
const val editMessageTextMethod = "editMessageText"
@Serializable
data class EditChatMessageText(
@SerialName(chatIdField)
override val chatId: ChatIdentifier,
@SerialName(messageIdField)
override val messageId: MessageIdentifier,
@SerialName(textField)
override val text: String,
@SerialName(parseModeField)
override val parseMode: ParseMode? = null,
@SerialName(disableWebPagePreviewField)
override val disableWebPagePreview: Boolean? = null,
@SerialName(replyMarkupField)
override val replyMarkup: InlineKeyboardMarkup? = null
) : EditChatMessage<TextContent>, EditTextChatMessage, EditReplyMessage, EditDisableWebPagePreviewMessage {
override fun method(): String = editMessageTextMethod
override val resultDeserializer: DeserializationStrategy<ContentMessage<TextContent>>
get() = TextContentMessageResultDeserializer
override val requestSerializer: SerializationStrategy<*>
get() = serializer()
}
suspend fun RequestsExecutor.editMessageText(
chatId: ChatIdentifier,
messageId: MessageIdentifier,
text: String,
parseMode: ParseMode? = null,
disableWebPagePreview: Boolean? = null,
replyMarkup: InlineKeyboardMarkup? = null
) = execute(
EditChatMessageText(chatId, messageId, text, parseMode, disableWebPagePreview, replyMarkup)
)
suspend fun RequestsExecutor.editMessageText(
chat: Chat,
messageId: MessageIdentifier,
text: String,
parseMode: ParseMode? = null,
disableWebPagePreview: Boolean? = null,
replyMarkup: InlineKeyboardMarkup? = null
) = editMessageText(chat.id, messageId, text, parseMode, disableWebPagePreview, replyMarkup)
suspend fun RequestsExecutor.editMessageText(
message: ContentMessage<TextContent>,
text: String,
parseMode: ParseMode? = null,
disableWebPagePreview: Boolean? = null,
replyMarkup: InlineKeyboardMarkup? = null
) = editMessageText(message.chat.id, message.messageId, text, parseMode, disableWebPagePreview, replyMarkup)

Some files were not shown because too many files have changed in this diff Show More