{"id":318323,"date":"2021-02-20T09:00:20","date_gmt":"2021-02-20T09:00:20","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=318323"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=318323","title":{"rendered":"\u0413\u043e\u0442\u043e\u0432\u0438\u043c \u0411\u043e\u043b\u044c\u0448\u0443\u044e \u0424\u0438\u0447\u0443\u2122 \u043d\u0430 Kotlin Multiplatform. \u0414\u043e\u043a\u043b\u0430\u0434 \u042f\u043d\u0434\u0435\u043a\u0441\u0430"},"content":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\">\u041f\u0440\u0435\u0434\u043f\u043e\u043b\u043e\u0436\u0438\u043c, \u0432\u044b \u0440\u0435\u0448\u0438\u043b\u0438 \u0432\u043d\u0435\u0434\u0440\u0438\u0442\u044c Kotlin Multiplatform \u0432 \u0441\u0432\u043e\u0439 \u043f\u0440\u043e\u0435\u043a\u0442, \u0447\u0442\u043e\u0431\u044b \u043f\u0435\u0440\u0435\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043b\u043e\u0433\u0438\u043a\u0443 \u043d\u0430 iOS \u0438 Android. \u0420\u0430\u043d\u043e \u0438\u043b\u0438 \u043f\u043e\u0437\u0434\u043d\u043e \u0432\u044b \u0437\u0430\u0445\u043e\u0442\u0438\u0442\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0411\u043e\u043b\u044c\u0448\u0443\u044e \u0424\u0438\u0447\u0443, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0431\u0443\u0434\u0435\u0442 \u0432\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u0432 \u0441\u0435\u0431\u044f \u0438 \u0441\u043b\u043e\u0436\u043d\u0443\u044e \u043c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043d\u0443\u044e \u043b\u043e\u0433\u0438\u043a\u0443, \u043f\u043e\u0445\u043e\u0434\u044b \u0432 \u0441\u0435\u0442\u044c, \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435. \u041a\u0430\u0436\u0434\u044b\u0439 \u0438\u0437 \u044d\u0442\u0438\u0445 \u044d\u0442\u0430\u043f\u043e\u0432 \u0432\u044b \u043f\u0440\u0438\u0432\u044b\u043a\u043b\u0438 \u0434\u0435\u043b\u0430\u0442\u044c \u043d\u0430 \u0441\u0432\u043e\u0435\u0439 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435 (\u0432\u0435\u0434\u044c \u0434\u0435\u043b\u0430\u043b\u0438 \u044d\u0442\u043e \u0442\u044b\u0441\u044f\u0447\u0443 \u0440\u0430\u0437). \u041d\u043e \u0432 \u043c\u0443\u043b\u044c\u0442\u0438\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435 \u043d\u0435\u0442 \u043f\u0440\u0438\u0432\u044b\u0447\u043d\u044b\u0445 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a \u0438 \u043f\u043e\u0434\u0445\u043e\u0434\u043e\u0432, \u0437\u0430\u0442\u043e \u0435\u0441\u0442\u044c \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u043e \u043d\u043e\u0432\u044b\u0439 \u0441\u0442\u0435\u043a \u0438 \u0442\u044b\u0441\u044f\u0447\u0430 \u043d\u043e\u0432\u044b\u0445 \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u0432 \u044d\u043b\u0435\u0433\u0430\u043d\u0442\u043d\u043e \u0432\u044b\u0441\u0442\u0440\u0435\u043b\u0438\u0442\u044c \u0441\u0435\u0431\u0435 \u0432 \u043d\u043e\u0433\u0443. \u042f\u043d\u0434\u0435\u043a\u0441.\u041a\u0430\u0440\u0442\u044b \u0438 \u0414\u043c\u0438\u0442\u0440\u0438\u0439 \u042f\u043a\u043e\u0432\u043b\u0435\u0432 <a href=\"https:\/\/habr.com\/ru\/users\/yakdmt\/\" class=\"user_link\">yakdmt<\/a> \u043f\u0440\u043e\u0448\u043b\u0438 \u0442\u0435\u0440\u043d\u0438\u0441\u0442\u044b\u0439 \u043f\u0443\u0442\u044c \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0444\u0438\u0447\u0438 \u0432 \u043c\u0443\u043b\u044c\u0442\u0438\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435. <\/p>\n<div class=\"oembed\"><iframe allowfullscreen id=\"602a432030f707d266c0ec49\" src=\"https:\/\/embedd.srv.habr.com\/iframe\/602a432030f707d266c0ec49\"><\/iframe><\/div>\n<p>\u2014 \u0414\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u0430 \u043f\u0430\u0440\u0443 \u0441\u043b\u043e\u0432 \u043e \u0441\u0435\u0431\u0435. \u041c\u0435\u043d\u044f \u0437\u043e\u0432\u0443\u0442 \u0414\u043c\u0438\u0442\u0440\u0438\u0439 \u042f\u043a\u043e\u0432\u043b\u0435\u0432. \u042f \u043f\u043e\u0440\u0430\u0431\u043e\u0442\u0430\u043b \u0432 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u0441\u0442\u0430\u0440\u0442\u0430\u043f\u0430\u0445, \u0432 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u0431\u0430\u043d\u043a\u0430\u0445, \u0430 \u0441\u0435\u0439\u0447\u0430\u0441 \u0440\u0430\u0431\u043e\u0442\u0430\u044e \u0432 \u042f\u043d\u0434\u0435\u043a\u0441\u0435 \u043d\u0430\u0434 Android-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435\u043c \u042f\u043d\u0434\u0435\u043a\u0441.\u041a\u0430\u0440\u0442. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0435\u0449\u0435 \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u0438\u0448\u0443 \u043d\u0430 Kotlin Multiplatform \u043a\u0440\u043e\u0441\u0441\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u0443\u044e \u043b\u043e\u0433\u0438\u043a\u0443.<br \/>  <a name=\"habracut\"><\/a><br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/7d\/po\/gt\/7dpogt1wavf9ym94wwn21o3qw7o.jpeg\"><\/p>\n<p>  \u0412\u0441\u043f\u043e\u043c\u043d\u0438\u0442\u0435 \u0441\u0430\u043c\u0443\u044e \u043f\u0435\u0440\u0432\u0443\u044e \u0444\u0438\u0447\u0443, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u0432\u044b \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043b\u0438 \u0432 \u043f\u0440\u043e\u0434\u0430\u043a\u0448\u0435\u043d. \u041f\u0443\u0441\u0442\u044c \u043e\u043d\u0430 \u0431\u044b\u043b\u0430 \u043c\u0430\u043b\u0435\u043d\u044c\u043a\u0430\u044f, \u043d\u043e \u0432\u0441\u043f\u043e\u043c\u043d\u0438\u0442\u0435, \u043a\u0430\u043a \u0432\u044b \u0431\u044b\u043b\u0438 \u0433\u043e\u0440\u0434\u044b \u0441\u043e\u0431\u043e\u0439, \u043a\u0430\u043a \u0431\u044b\u043b\u0438 \u0441\u0447\u0430\u0441\u0442\u043b\u0438\u0432\u044b. \u0421 \u0442\u0435\u0445 \u043f\u043e\u0440 \u043d\u0430\u0432\u0435\u0440\u043d\u044f\u043a\u0430 \u043f\u0440\u043e\u0448\u043b\u043e \u043c\u043d\u043e\u0433\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438, \u0432\u044b \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043b\u0438 \u0434\u0435\u0441\u044f\u0442\u043a\u0438 \u0444\u0438\u0447, \u0437\u0430\u043a\u043e\u043c\u043c\u0438\u0442\u0438\u043b\u0438 \u0442\u044b\u0441\u044f\u0447\u0438 \u0441\u0442\u0440\u043e\u043a \u043a\u043e\u0434\u0430.<\/p>\n<p>  \u0423 \u0432\u0430\u0441, \u0441\u043a\u043e\u0440\u0435\u0435 \u0432\u0441\u0435\u0433\u043e, \u0441\u043b\u043e\u0436\u0438\u043b\u043e\u0441\u044c \u043f\u043e\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u0441\u0440\u0435\u0434\u043d\u0435\u0441\u0442\u0430\u0442\u0438\u0441\u0442\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0431\u043e\u043b\u044c\u0448\u0430\u044f \u0444\u0438\u0447\u0430 \u0441\u043e\u0441\u0442\u043e\u0438\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0438\u0437 \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u044b\u0445 \u044d\u0442\u0430\u043f\u043e\u0432. \u041e\u0431\u044b\u0447\u043d\u043e \u043d\u0443\u0436\u043d\u043e \u0441\u0445\u043e\u0434\u0438\u0442\u044c \u0432 \u0441\u0435\u0442\u044c, \u0440\u0430\u0441\u043f\u0430\u0440\u0441\u0438\u0442\u044c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442, \u0441\u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c, \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435 \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435. \u041b\u0443\u0447\u0448\u0435 \u044d\u0442\u043e \u0434\u0435\u043b\u0430\u0442\u044c \u0432 \u0444\u043e\u043d\u0435. \u0414\u0430\u043b\u044c\u0448\u0435 \u043c\u044b \u043a\u043b\u0430\u0434\u0435\u043c \u044d\u0442\u043e \u0432 \u043a\u044d\u0448 \u0438 \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u043c \u043d\u0430 \u044d\u043a\u0440\u0430\u043d\u0435.<\/p>\n<p>  \u0423 \u043c\u0435\u043d\u044f \u0442\u043e\u0436\u0435 \u0431\u044b\u043b\u0438 \u043b\u0443\u0447\u0448\u0438\u0435 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0438, \u0441\u0444\u043e\u0440\u043c\u0438\u0440\u043e\u0432\u0430\u0432\u0448\u0438\u0439\u0441\u044f \u043f\u043e\u0434\u0445\u043e\u0434 \u043a \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044e \u0444\u0438\u0447. \u041d\u043e, \u043a \u0441\u043e\u0436\u0430\u043b\u0435\u043d\u0438\u044e, \u044d\u0442\u043e \u0432\u0441\u0435 \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u0432\u044b\u043a\u0438\u043d\u0443\u0442\u044c, \u043a\u043e\u0433\u0434\u0430 \u043f\u0440\u0438\u0448\u043b\u043e \u0432\u0440\u0435\u043c\u044f \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043c\u0443\u043b\u044c\u0442\u0438\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u0443\u044e \u0444\u0438\u0447\u0443 \u043d\u0430 Kotlin Multiplatform \u2014 \u0441\u0442\u0430\u0440\u044b\u0435 \u043f\u043e\u0434\u0445\u043e\u0434\u044b \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u043b\u0438 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c.<\/p>\n<p>  \u0414\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u0430 \u0432\u0435\u0440\u043d\u0435\u043c\u0441\u044f \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043d\u0430\u0437\u0430\u0434, \u0432 \u043c\u043e\u043c\u0435\u043d\u0442, \u043a\u043e\u0433\u0434\u0430 \u043c\u044b \u0434\u0443\u043c\u0430\u043b\u0438 \u043d\u0430\u0434 \u0432\u043d\u0435\u0434\u0440\u0435\u043d\u0438\u0435\u043c Kotlin Multiplatform. \u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043a\u0430\u043a \u043c\u044b \u043a \u044d\u0442\u043e\u043c\u0443 \u043f\u0440\u0438\u0448\u043b\u0438. \u041e\u043a\u043e\u043b\u043e \u0433\u043e\u0434\u0430 \u043d\u0430\u0437\u0430\u0434 \u043c\u044b \u0441\u0434\u0435\u043b\u0430\u043b\u0438 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u0445\u0430\u043a\u0430\u0442\u043e\u043d, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0440\u0430\u0437\u0434\u0435\u043b\u0438\u043b\u0438\u0441\u044c \u043d\u0430 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0438 \u0440\u0435\u0448\u0438\u043b\u0438 \u0437\u0430\u043f\u0438\u043b\u0438\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0444\u0438\u0447 \u043d\u0430 Kotlin Multiplatform. \u041d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u0437 \u044d\u0442\u0438\u0445 \u0432\u0435\u0449\u0435\u0439 \u043c\u044b \u043f\u043e\u0442\u043e\u043c \u0434\u043e\u0434\u0435\u043b\u0430\u043b\u0438 \u0438 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043b\u0438 \u0432 \u043f\u0440\u043e\u0434\u0430\u043a\u0448\u0435\u043d. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0441\u0435\u0439\u0447\u0430\u0441 \u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438 \u042f\u043d\u0434\u0435\u043a\u0441.\u041a\u0430\u0440\u0442 \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0443\u0432\u0438\u0434\u0435\u0442\u044c \u0440\u0443\u043b\u0435\u0442\u043a\u0443 \u2014 \u0438\u043b\u0438, \u043f\u043e-\u0434\u0440\u0443\u0433\u043e\u043c\u0443, \u043b\u0438\u043d\u0435\u0439\u043a\u0443, \u2014 \u0442\u043e \u0435\u0441\u0442\u044c \u0444\u0438\u0447\u0443, \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043c\u043e\u0436\u043d\u043e \u0438\u0437\u043c\u0435\u0440\u0438\u0442\u044c \u0440\u0430\u0441\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0442\u043e\u0447\u043a\u0430\u043c\u0438. \u041a\u0430\u043a \u0440\u0430\u0437 \u043e\u043d\u0430 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0430 \u043d\u0430 Kotlin Multiplatform.<\/p>\n<p>  \u0421 \u0442\u0435\u0445 \u043f\u043e\u0440 \u043c\u044b \u0434\u043e\u0433\u043e\u0432\u043e\u0440\u0438\u043b\u0438\u0441\u044c, \u0447\u0442\u043e \u0431\u0443\u0434\u0435\u043c \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u043e \u043d\u043e\u0432\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0434\u0435\u043b\u0430\u0442\u044c \u043a\u0440\u043e\u0441\u0441\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u043e, \u0442\u043e \u0435\u0441\u0442\u044c \u043d\u0430 Kotlin Multiplatform.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/bp\/jn\/35\/bpjn35cqdq3cdqbtnwt00a5ld20.jpeg\"><\/p>\n<p>  \u0427\u0435\u0433\u043e \u043d\u0430\u043c \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c? \u0418\u0437\u043d\u0430\u0447\u0430\u043b\u044c\u043d\u043e \u043c\u044b \u0441\u0435\u0431\u0435 \u0441\u0442\u0430\u0432\u0438\u043b\u0438 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0446\u0435\u043b\u0438, \u0434\u0443\u043c\u0430\u043b\u0438, \u0447\u0442\u043e \u0435\u0441\u043b\u0438 \u0431\u0443\u0434\u0435\u0442 \u043c\u0435\u043d\u044c\u0448\u0435 \u043a\u043e\u0434\u0430, \u043d\u0435 \u0434\u0432\u0435 \u043a\u043e\u0434\u043e\u0432\u044b\u0445 \u0431\u0430\u0437\u044b, \u0430 \u043e\u0434\u043d\u0430, \u0442\u043e \u0431\u0443\u0434\u0435\u0442 \u043c\u0435\u043d\u044c\u0448\u0435 \u0431\u0430\u0433\u043e\u0432, \u043f\u0440\u0438\u0434\u0435\u0442\u0441\u044f \u043c\u0435\u043d\u044c\u0448\u0435 \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0442\u0440\u0430\u0442\u0438\u0442\u044c \u043d\u0430 \u0438\u0445 \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435.<\/p>\n<p>  \u0412\u0442\u043e\u0440\u043e\u0439 \u043c\u043e\u043c\u0435\u043d\u0442: \u043c\u044b \u0441\u0447\u0438\u0442\u0430\u043b\u0438, \u0447\u0442\u043e, \u0435\u0441\u043b\u0438 \u043e\u0434\u043d\u0443 \u0444\u0438\u0447\u0443 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0437\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u043e\u0434\u0438\u043d \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a, \u0442\u043e \u043b\u043e\u0433\u0438\u043a\u0430 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0437\u044a\u0435\u0437\u0436\u0430\u0442\u044c\u0441\u044f, \u0447\u0435\u043b\u043e\u0432\u0435\u043a \u0432\u0441\u0435\u0433\u0434\u0430 \u0431\u0443\u0434\u0435\u0442 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u044c\u0441\u044f \u0432 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0435 \u0438 \u043e\u0442\u0432\u0435\u0447\u0430\u0442\u044c \u0437\u0430 \u0434\u0432\u0435 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u044b \u0441\u0440\u0430\u0437\u0443.<\/p>\n<p>  \u0415\u0449\u0435 \u043e\u0434\u043d\u0438 \u0432\u0430\u0436\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442: \u043c\u044b \u0445\u043e\u0442\u0435\u043b\u0438 \u043f\u0435\u0440\u0435\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043a\u043e\u0434 \u0438\u0437 Android. \u0423 \u043d\u0430\u0441 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0431\u043e\u043b\u044c\u0448\u0430\u044f \u043a\u043e\u0434\u043e\u0432\u0430\u044f \u0431\u0430\u0437\u0430 \u043d\u0430 Android, \u043c\u043d\u043e\u0433\u043e \u0440\u0435\u0430\u043a\u0442\u0438\u0432\u043d\u043e\u0439 \u0438 \u0441\u043b\u043e\u0436\u043d\u043e\u0439 \u043b\u043e\u0433\u0438\u043a\u0438. \u041c\u044b \u0445\u043e\u0442\u0435\u043b\u0438 \u0432\u0437\u044f\u0442\u044c \u0435\u0435 \u0438 \u043f\u0435\u0440\u0435\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043d\u0430 iOS \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u0430 \u0432 common-\u0447\u0430\u0441\u0442\u044c. \u041a \u0442\u043e\u043c\u0443 \u0436\u0435 \u044d\u0442\u043e \u043d\u043e\u0432\u0430\u044f \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u044f, \u043d\u0430\u043c \u0431\u044b\u043b\u043e \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e \u0441 \u043d\u0435\u0439 \u0440\u0430\u0437\u043e\u0431\u0440\u0430\u0442\u044c\u0441\u044f.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/sw\/he\/up\/swheupcwsht7l-c5myyof-z9qem.jpeg\"><\/p>\n<p>  \u0427\u0442\u043e \u043c\u044b \u043f\u043e\u043d\u044f\u043b\u0438 \u043f\u0440\u043e Kotlin Multiplatform? \u0420\u0435\u0430\u043b\u044c\u043d\u044b\u0439 \u043f\u0440\u043e\u0435\u043a\u0442 \u043d\u0430\u043c\u043d\u043e\u0433\u043e \u0441\u043b\u043e\u0436\u043d\u0435\u0435, \u0447\u0435\u043c \u0432\u0441\u0435 \u0442\u0443\u0442\u043e\u0440\u0438\u0430\u043b\u044b \u0438 \u0441\u0442\u0430\u0442\u044c\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0435\u0441\u0442\u044c \u0432 \u0441\u0435\u0442\u0438. \u0412\u0441\u0435\u0433\u0434\u0430 \u0432\u043e\u0437\u043d\u0438\u043a\u0430\u044e\u0442 \u043d\u0435\u043e\u0436\u0438\u0434\u0430\u043d\u043d\u044b\u0435 \u043f\u043e\u0434\u0432\u043e\u0434\u043d\u044b\u0435 \u043a\u0430\u043c\u043d\u0438, \u043d\u0435\u043e\u0436\u0438\u0434\u0430\u043d\u043d\u044b\u0435 \u0431\u0430\u0433\u0438 \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435. \u041a\u0430\u043a \u0440\u0430\u0437 \u043e\u0431 \u044d\u0442\u043e\u043c \u043f\u0443\u0442\u0438, \u043e \u0442\u043e\u043c, \u043a\u0430\u043a \u043c\u044b \u043f\u0438\u043b\u0438\u043b\u0438 \u044d\u0442\u0443 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u043d\u0430 Kotlin Multiplatform \u0438 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u043b\u0438 \u0435\u0435 \u0432 \u043f\u0440\u043e\u0434\u0430\u043a\u0448\u0435\u043d, \u044f \u0438 \u0445\u043e\u0442\u0435\u043b \u0441\u0435\u0433\u043e\u0434\u043d\u044f \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u0430\u0442\u044c.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/wf\/lf\/l3\/wflfl3he6oytkbeolrq-u5px9te.jpeg\"><\/p>\n<p>  \u042f \u043d\u0435 \u0431\u0443\u0434\u0443 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u043f\u0440\u043e \u043a\u0440\u043e\u0441\u0441\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u044b\u0439 UI, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0438\u0441\u0442\u043e\u0440\u0438\u0447\u0435\u0441\u043a\u0438 \u0441\u043b\u043e\u0436\u0438\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u0432 Android- \u0438 iOS-\u0447\u0430\u0441\u0442\u0438 \u041a\u0430\u0440\u0442 \u0443 \u043d\u0430\u0441 \u043e\u0447\u0435\u043d\u044c \u0440\u0430\u0437\u043d\u0430\u044f \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0430. \u041f\u043e\u043a\u0430 \u043c\u044b \u043d\u0435 \u043f\u0440\u0438\u0448\u043b\u0438 \u043a \u0435\u0434\u0438\u043d\u043e\u043c\u0443 \u0440\u0435\u0448\u0435\u043d\u0438\u044e, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043f\u043e\u0437\u0432\u043e\u043b\u0438\u043b\u043e \u0431\u044b \u043d\u0430\u043c \u043f\u0435\u0440\u0435\u043d\u0435\u0441\u0442\u0438 UI \u0432 \u043a\u0440\u043e\u0441\u0441\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0443. \u041d\u043e \u0437\u0430\u0442\u043e \u043c\u044b \u043f\u043e\u0433\u043e\u0432\u043e\u0440\u0438\u043c \u043e \u0442\u043e\u043c, \u043a\u0430\u043a \u0433\u043e\u0442\u043e\u0432\u0438\u0442\u044c \u043c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043d\u043e\u0441\u0442\u044c, \u043a\u0430\u043a\u0438\u0435 \u0435\u0441\u0442\u044c \u043f\u043e\u0434\u0445\u043e\u0434\u044b \u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438, \u043e \u0441\u0435\u0442\u0435\u0432\u043e\u043c \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0438 \u0432 common-\u043a\u043e\u0434\u0435 \u0438 \u0432\u0437\u0433\u043b\u044f\u043d\u0435\u043c \u043d\u0430 \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u2014 \u043a\u0430\u043a \u0432\u0441\u0435 \u044d\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0432 common-\u0447\u0430\u0441\u0442\u0438.<\/p>\n<h2>\u0427\u0442\u043e, \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u043f\u0438\u043b\u0438\u043c?<\/h2>\n<p>  \u041d\u043e \u0434\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u0430 \u0434\u0430\u0432\u0430\u0439\u0442\u0435 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u0447\u0442\u043e \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u043f\u0438\u043b\u0438\u0442\u044c, \u0447\u0442\u043e \u0437\u0430 \u0444\u0438\u0447\u0443 \u043c\u044b \u0441\u0434\u0435\u043b\u0430\u043b\u0438.<\/p>\n<p>  \u0412\u043e\u0437\u043c\u043e\u0436\u043d\u043e, \u0432\u044b \u0432\u0438\u0434\u0435\u043b\u0438 \u2014 \u0432 \u042f\u043d\u0434\u0435\u043a\u0441.\u041a\u0430\u0440\u0442\u0430\u0445 \u043f\u043e\u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u043f\u0438\u043d\u044b \u0441 \u043a\u043e\u043d\u0446\u0435\u0440\u0442\u0430\u043c\u0438, \u0432\u044b\u0441\u0442\u0430\u0432\u043a\u0430\u043c\u0438, \u0441 \u043a\u043e\u0440\u043e\u0442\u043a\u043e\u0436\u0438\u0432\u0443\u0449\u0438\u043c\u0438 \u0441\u043e\u0431\u044b\u0442\u0438\u044f\u043c\u0438. \u041a\u0430\u043a \u0440\u0430\u0437 \u044d\u0442\u043e\u0442 \u0441\u0435\u0440\u0432\u0438\u0441 \u043f\u043e \u043f\u043e\u043a\u0430\u0437\u0443 \u0441\u043e\u0431\u044b\u0442\u0438\u0439 \u043d\u0430 \u043a\u0430\u0440\u0442\u0435 \u043c\u044b \u0438 \u0445\u043e\u0442\u0435\u043b\u0438 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0432 \u043c\u0443\u043b\u044c\u0442\u0438\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435 \u2014 \u0447\u0442\u043e\u0431\u044b \u043e\u043d \u043f\u043e\u0434 \u043a\u0430\u043f\u043e\u0442\u043e\u043c \u0441\u0430\u043c \u0445\u043e\u0434\u0438\u043b \u0432 \u0441\u0435\u0442\u044c, \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043b, \u0440\u0435\u0448\u0430\u043b, \u0447\u0442\u043e \u0435\u043c\u0443 \u0434\u0435\u043b\u0430\u0442\u044c. \u0410 \u043c\u044b \u0431\u044b \u0433\u043e\u0432\u043e\u0440\u0438\u043b\u0438 \u0435\u043c\u0443: \u00ab\u0420\u0438\u0441\u0443\u0439\u00bb, \u2014 \u0438 \u043e\u043d \u0431\u044b \u0434\u0435\u043b\u0430\u043b \u0432\u0441\u0451 \u0432 common-\u0447\u0430\u0441\u0442\u0438.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/zq\/xw\/al\/zqxwalqhusdcd8jgopy3z_iob9w.jpeg\"><\/p>\n<p>  \u041d\u0443\u0436\u0435\u043d \u0431\u044b\u043b \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0442\u0430\u043a\u043e\u0439 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441, EventsService, \u0443 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0432\u0441\u0435\u0433\u043e \u0434\u0432\u0430 \u043c\u0435\u0442\u043e\u0434\u0430 \u2014 \u00ab\u043d\u0430\u0440\u0438\u0441\u0443\u0439 \u043d\u0430 \u043a\u0430\u0440\u0442\u0435\u00bb \u0438 \u0447\u0442\u043e\u0431\u044b \u043e\u043d \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u043b \u0442\u0430\u043f\u044b \u043d\u0430 \u0441\u043e\u0431\u044b\u0442\u0438\u044f. \u0422\u043e \u0435\u0441\u0442\u044c \u0447\u0442\u043e\u0431\u044b \u043c\u044b \u043d\u0430 iOS \u0438 Android \u043e\u0442\u043b\u0430\u0432\u043b\u0438\u0432\u0430\u043b\u0438, \u043a\u043e\u0433\u0434\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0442\u0430\u043f\u0430\u0435\u0442 \u043d\u0430 \u0441\u043e\u0431\u044b\u0442\u0438\u0435. \u041f\u0440\u0438\u0447\u0435\u043c, \u0442\u0430\u043a \u043a\u0430\u043a \u043b\u043e\u0433\u0438\u043a\u0430 \u0443 \u043d\u0430\u0441 \u0438 \u0432 iOS-, \u0438 \u0432 Android-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u043c\u043d\u043e\u0433\u043e \u0440\u0435\u0430\u043a\u0442\u0438\u0432\u0449\u0438\u043d\u044b, RxSwift \u0438 RxJava, \u0442\u043e \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u043a\u0430\u043a-\u0442\u043e \u0441\u0432\u044f\u0437\u0430\u0442\u044c, \u0447\u0442\u043e\u0431\u044b \u044d\u0442\u043e \u043b\u043e\u0436\u0438\u043b\u043e\u0441\u044c \u043d\u0430 \u0440\u0435\u0430\u043a\u0442\u0438\u0432\u043d\u0443\u044e \u043b\u043e\u0433\u0438\u043a\u0443, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0443\u0436\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0443\u0435\u0442 \u043d\u0430 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430\u0445. \u0425\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u0441\u0432\u044f\u0437\u044c \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u044b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043a\u0430\u043a Observable, \u0430 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043e\u0442\u043c\u0435\u043d\u044f\u0442\u044c \u043f\u043e\u0434\u043f\u0438\u0441\u043a\u0443 \u2014 \u043a\u0430\u043a \u043d\u0435\u0447\u0442\u043e \u0442\u0438\u043f\u0430 Disposable.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/ho\/ei\/a0\/hoeia0noacbxcllwcypq0yjpl0k.jpeg\"><\/p>\n<p>  \u0417\u0434\u0435\u0441\u044c \u0443\u0436\u0435 \u0435\u0441\u0442\u044c \u0442\u043e\u043d\u043a\u043e\u0441\u0442\u044c, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u043c\u044b \u043d\u0435 \u043c\u043e\u0436\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 Observable \u0438\u0437 RxJava \u0438 Observable \u0438\u0437 RxSwift \u0432 common-\u043a\u043e\u0434\u0435. \u041c\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0435\u0433\u043e \u0430\u043d\u0430\u043b\u043e\u0433, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u0436\u0438\u0442\u044c \u0432 common-\u0447\u0430\u0441\u0442\u0438.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/2w\/ar\/zo\/2warzojmh43x3uhtvy8axo-ywrs.jpeg\"><\/p>\n<p>  \u041c\u044b \u0440\u0435\u0448\u0438\u043b\u0438 \u044d\u0442\u043e \u0442\u0430\u043a: \u0441\u0434\u0435\u043b\u0430\u043b\u0438 expect-\u043a\u043b\u0430\u0441\u0441 PlatformObservable, \u0443 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0440\u0430\u0437\u043d\u044b\u0435 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043d\u0430 Android \u0438 iOS. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043d\u0430 Android \u044d\u0442\u043e typealias \u0434\u043b\u044f RxJava Observable, \u043d\u0430 iOS \u2014 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u0430\u044f \u043e\u0431\u0435\u0440\u0442\u043a\u0430.<\/p>\n<p>  \u042f \u0445\u043e\u0442\u0435\u043b \u0431\u044b \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u0430\u0442\u044c \u043e \u0442\u043e\u043c, \u043f\u043e\u0447\u0435\u043c\u0443 \u044d\u0442\u043e\u0442 \u043a\u043b\u0430\u0441\u0441 \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0442\u043d\u044b\u0439. \u0414\u0435\u043b\u043e \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e, \u0435\u0441\u043b\u0438 \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435 \u0434\u0435\u043b\u0430\u0442\u044c expect- \u0438 actual-\u043a\u043b\u0430\u0441\u0441\u044b, \u044d\u0442\u043e \u0438\u043c\u0435\u0435\u0442 \u0441\u043c\u044b\u0441\u043b \u0442\u043e\u0433\u0434\u0430, \u043a\u043e\u0433\u0434\u0430 \u0432\u044b \u043d\u0430 \u043e\u0434\u043d\u043e\u0439 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435 \u043c\u043e\u0436\u0435\u0442\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c typealias, \u0442\u043e \u0435\u0441\u0442\u044c \u043a\u043e\u0433\u0434\u0430 \u0432\u0430\u0448 expect-\u043a\u043b\u0430\u0441\u0441 \u0432 \u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u0435 \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0435\u0442 \u0441 \u043e\u0434\u043d\u0438\u043c \u0438\u0437 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u044b\u0445. \u042d\u0442\u043e \u0434\u0430\u0441\u0442 \u043d\u0430\u0438\u0431\u043e\u043b\u044c\u0448\u0443\u044e \u043f\u043e\u043b\u044c\u0437\u0443.<\/p>\n<p>  \u0427\u0442\u043e\u0431\u044b \u043a\u0430\u043a \u0440\u0430\u0437 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0435\u0433\u043e \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u043c \u0441 Observable \u0438\u0437 RxJava, \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043a\u043b\u0430\u0441\u0441 PlatformObservable \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0442\u043d\u044b\u043c: \u0438 iOS-\u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e, \u0438 \u043e\u0431\u0435\u0440\u0442\u043a\u0443.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/c0\/ej\/bd\/c0ejbd7_x7d2kweifkhef6uaonq.jpeg\"><\/p>\n<p>  \u0415\u0441\u043b\u0438 \u044d\u0442\u043e\u0433\u043e \u043d\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c, \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0442\u043e\u0440 \u0431\u0443\u0434\u0435\u0442 \u0440\u0443\u0433\u0430\u0442\u044c\u0441\u044f, \u0441\u043a\u0430\u0436\u0435\u0442, \u0447\u0442\u043e expect \u0438 actual \u043d\u0435 \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u044e\u0442 \u043f\u043e \u043c\u043e\u0434\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u0438, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043a\u043e\u0434 \u043d\u0435 \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u0443\u0435\u0442\u0441\u044f.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/o1\/a0\/gz\/o1a0gzfeixtjcjenqzav-iw6gma.jpeg\"><\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/gh\/du\/hk\/ghduhkt-gzoy2utlr0f5vi22e64.jpeg\"><\/p>\n<p>  \u041f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u043e \u0442\u043e\u043c, \u0437\u0430\u0447\u0435\u043c \u043d\u0443\u0436\u043d\u0430 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u0430\u044f \u043e\u0431\u0435\u0440\u0442\u043a\u0430, \u043f\u043e\u0447\u0435\u043c\u0443 \u043d\u0435\u043b\u044c\u0437\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0440\u0430\u0437\u0443 RxSwift. \u0414\u0435\u043b\u043e \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u0442\u0438\u043f\u043e\u0432\u044b\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b (Generics), \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0435\u0441\u0442\u044c \u0432 Kotlin \u0432 iOSMain-\u0447\u0430\u0441\u0442\u0438, \u043d\u0435 \u0432\u0438\u0434\u043d\u044b \u0432 iOS, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u043a\u043e\u0434 \u0442\u0440\u0430\u043d\u0441\u043b\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u0432 Objective-C, \u0438 \u0438\u0437 Objective-C \u044d\u0442\u043e\u0442 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 \u043d\u0435 \u0432\u0438\u0434\u043d\u043e. \u0414\u043b\u044f \u0441\u043e\u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0442\u0438\u043f\u0430 \u043c\u044b \u0438 \u0441\u0434\u0435\u043b\u0430\u043b\u0438 \u0442\u0430\u043a\u0443\u044e \u043e\u0431\u0435\u0440\u0442\u043a\u0443, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0435\u0442 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043c\u0435\u0442\u043e\u0434\u044b Observable. \u042d\u0442\u0430 \u043e\u0431\u0435\u0440\u0442\u043a\u0430 \u0436\u0438\u0432\u0435\u0442 \u0442\u043e\u043b\u044c\u043a\u043e \u0432 \u0447\u0430\u0441\u0442\u0438 iOSMain. \u0412 \u043d\u0435\u0439 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u044b \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043c\u0435\u0442\u043e\u0434\u044b: subscribe(), onNext(), onError() \u0438 onComplete().<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/hl\/6_\/mv\/hl6_mvm6p2rbxmqlds6b7ghuyak.jpeg\"><\/p>\n<p>  \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0443\u0436\u0435 \u0432 Swift-\u0447\u0430\u0441\u0442\u0438 iOS-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0441\u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u044d\u0442\u0443 \u043e\u0431\u0435\u0440\u0442\u043a\u0443 \u0432 RxSwift.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/7o\/of\/xj\/7oofxj3klqmgkmfbvo2iak55k94.jpeg\"><\/p>\n<p>  \u041f\u043e\u0434 \u043a\u0430\u043f\u043e\u0442\u043e\u043c \u044d\u0442\u043e \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/2s\/hj\/f1\/2shjf1uihwc4-ljyzhzm6clyrkg.jpeg\"><\/p>\n<p>  \u0422\u043e \u0435\u0441\u0442\u044c \u043c\u044b \u0441\u043e\u0437\u0434\u0430\u0435\u043c RxSwift Observable.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/1r\/yh\/zo\/1ryhzo2udq9kor1ungheotizmns.jpeg\"><\/p>\n<p>  \u0414\u0430\u043b\u0435\u0435 \u043d\u0430 \u043a\u0430\u0436\u0434\u044b\u0439 \u0432\u044b\u0437\u043e\u0432 onNext \u0432 Kotlin Observable \u043c\u044b \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0435 \u0432 RxSwift Observable.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/43\/jt\/wr\/43jtwru9_bgymdrwtuqyhu6kj50.jpeg\"><\/p>\n<p>  \u041a\u043e\u043d\u0435\u0447\u043d\u043e, \u043f\u043e\u0434\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u043c\u0441\u044f.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/98\/co\/rj\/98corjlmmoytiaxfxsjfmvknrlk.jpeg\"><\/p>\n<p>  \u042d\u0442\u0443 \u043f\u043e\u0434\u043f\u0438\u0441\u043a\u0443 \u0437\u0430\u0432\u043e\u0440\u0430\u0447\u0438\u0432\u0430\u0435\u043c \u0432 Disposable \u0443\u0436\u0435 \u0432 RxSwift. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u043c\u0430\u043f\u043f\u0438\u043d\u0433 \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0438 \u0432 RxSwift \u043d\u0435 \u0442\u0435\u0440\u044f\u0435\u0442\u0441\u044f \u0442\u0438\u043f\u043e\u0432\u043e\u0439 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/lz\/n6\/ya\/lzn6yaw7f0i8ho91fq1w35y4m8u.jpeg\"><\/p>\n<p>  \u0414\u043b\u044f \u0447\u0435\u0433\u043e \u043d\u0443\u0436\u0435\u043d Disposer? \u042d\u0442\u043e \u0442\u0430\u043a\u043e\u0439 \u0430\u043d\u0430\u043b\u043e\u0433 Disposable \u0438\u0437 Rx \u0434\u043b\u044f \u043e\u0442\u043c\u0435\u043d\u044b \u043f\u043e\u0434\u043f\u0438\u0441\u043e\u043a. Disposable \u043c\u044b \u0442\u043e\u0436\u0435 \u043d\u0435 \u043c\u043e\u0436\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432 common-\u0447\u0430\u0441\u0442\u0438, \u043c\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0441\u0432\u043e\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u0435.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/6u\/tc\/h0\/6utch0c4kik5la-0iiexrxjw-gs.jpeg\"><\/p>\n<p>  \u042d\u0442\u043e \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043e\u0434\u043d\u0438\u043c \u043c\u0435\u0442\u043e\u0434\u043e\u043c dispose() \u0441\u043b\u0443\u0436\u0438\u0442 \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0441\u043e\u0435\u0434\u0438\u043d\u044f\u0442\u044c \u0432 common-\u0447\u0430\u0441\u0442\u0438 \u0434\u0432\u0430 \u043c\u0438\u0440\u0430: common \u0441 \u0435\u0433\u043e \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u0430\u043c\u0438 \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u0443\u044e \u0447\u0430\u0441\u0442\u044c, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0430 \u043d\u0430 RxJava\/RxSwift. \u042d\u0442\u043e \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0442\u0430\u043a, \u0442\u043e \u0435\u0441\u0442\u044c \u0432 common-\u0447\u0430\u0441\u0442\u0438 \u043c\u044b \u0441\u043e\u0437\u0434\u0430\u0435\u043c Scope, \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u0442\u0430\u043c \u0440\u0435\u043d\u0434\u0435\u0440\u0438\u043d\u0433 \u0441\u043e\u0431\u044b\u0442\u0438\u0439, \u0430 \u0432 Disposer \u0437\u0430\u0432\u043e\u0440\u0430\u0447\u0438\u0432\u0430\u0435\u043c \u043e\u0442\u043c\u0435\u043d\u0443 \u043e\u0442\u0440\u0438\u0441\u043e\u0432\u043a\u0438 \u0438 \u044d\u0442\u043e\u0442 Disposer \u043e\u0442\u0434\u0430\u0435\u043c \u043d\u0430 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0443.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/am\/jh\/yq\/amjhyqz3mxg97u2lj8fl9g173lg.jpeg\"><\/p>\n<p>  \u0423\u0436\u0435 \u043d\u0430 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435 \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0437\u0430\u0432\u0435\u0440\u043d\u0443\u0442\u044c \u044d\u0442\u043e\u0442 Disposer \u0432 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 Disposable \u0438\u0437 RxJava. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u044d\u0442\u0438 \u0434\u0432\u0430 \u043c\u0438\u0440\u0430 \u2014 \u043c\u0438\u0440 \u043a\u043e\u0440\u0443\u0442\u0438\u043d \u0438 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u044b\u0439 Rx \u2014 \u0443 \u043d\u0430\u0441 \u0441\u0432\u044f\u0437\u0430\u043d\u044b.<\/p>\n<h2>\u041c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043d\u043e\u0441\u0442\u044c<\/h2>\n<p>  \u0418\u0442\u0430\u043a, \u043c\u044b \u043f\u043e\u0433\u043e\u0432\u043e\u0440\u0438\u043b\u0438 \u043e \u0442\u043e\u043c, \u043a\u0430\u043a \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0444\u0438\u0447\u0430 \u0438 API \u0434\u043b\u044f \u044d\u0442\u043e\u0439 \u0444\u0438\u0447\u0438. \u041d\u043e \u0434\u0430\u043b\u044c\u0448\u0435 \u0432\u0441\u0442\u0430\u0435\u0442 \u0432\u043e\u043f\u0440\u043e\u0441: \u043a\u0430\u043a \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0447\u0442\u043e-\u0442\u043e \u0432 \u0444\u043e\u043d\u0435, \u0430\u0441\u0438\u043d\u0445\u0440\u043e\u043d\u043d\u043e \u0438 \u043c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043d\u043e?<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/qu\/c7\/dl\/quc7dlfz889gyskbh-jm_cxloq8.jpeg\"><\/p>\n<p>  \u041a\u0430\u043a \u0432\u044b\u043d\u0435\u0441\u0442\u0438 \u0442\u044f\u0436\u0435\u043b\u044b\u0435 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0438 \u0432 \u0444\u043e\u043d, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043f\u043e\u0434\u0441\u0447\u0435\u0442 \u0434\u0438\u0444\u0444\u0430? \u041f\u0435\u0440\u0432\u043e\u0435 \u043d\u0430\u0448\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u0435: \u043d\u0430\u043f\u0438\u0441\u0430\u0442\u044c \u043b\u043e\u0433\u0438\u043a\u0443 \u043d\u0430 \u043a\u043e\u043b\u043b\u0431\u044d\u043a\u0430\u0445, \u043f\u043e\u0445\u043e\u0436\u0435 \u043d\u0430 AsyncTask. Android-\u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 \u043d\u0430\u0432\u0435\u0440\u043d\u044f\u043a\u0430 \u043f\u043e\u043c\u043d\u044f\u0442, \u0447\u0442\u043e \u0431\u044b\u043b \u0442\u0430\u043a\u043e\u0439.<\/p>\n<p>  \u041f\u0435\u0440\u0432\u0430\u044f \u043b\u044f\u043c\u0431\u0434\u0430 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442\u0441\u044f \u043d\u0430 \u0431\u044d\u043a\u0433\u0440\u0430\u0443\u043d\u0434\u0435, \u0447\u0442\u043e-\u0442\u043e \u0441\u0447\u0438\u0442\u0430\u0435\u0442, \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u0442 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442 \u0432 \u043a\u043e\u043b\u043b\u0431\u044d\u043a \u043d\u0430 \u0433\u043b\u0430\u0432\u043d\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435. \u0412 Kotlin \u044d\u0442\u043e \u043b\u0435\u0433\u0447\u0435 \u0432\u0441\u0435\u0433\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043d\u0430 \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u0430\u0445, \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0447\u0442\u043e-\u0442\u043e \u043d\u0430 Dispatchers.Default \u0438 \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0442\u044c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u043d\u0430 Dispatchers.Main.<\/p>\n<p>  \u041d\u043e \u043a\u043e\u0433\u0434\u0430 \u043c\u044b \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u043b\u0438 \u044d\u0442\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c, \u0442\u043e \u043d\u0430 Android \u044d\u0442\u043e \u0437\u0430\u0440\u0430\u0431\u043e\u0442\u0430\u043b\u043e, \u0430 \u043d\u0430 iOS \u2014 \u043d\u0435\u0442. \u0414\u0435\u043b\u043e \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u043f\u043e\u0434 \u043a\u0430\u043f\u043e\u0442\u043e\u043c \u043d\u0430 iOS \u0438 \u043d\u0430 Android \u0440\u0430\u0437\u043d\u044b\u0435 \u0440\u0430\u043d\u0442\u0430\u0439\u043c\u044b \u0434\u043b\u044f \u043c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043d\u043e\u0441\u0442\u0438, \u043d\u0430 iOS \u2014 \u044d\u0442\u043e Kotlin\/Native, \u043d\u0430 Android \u2014 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u0430\u044f JVM-\u043c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043d\u043e\u0441\u0442\u044c, \u043a\u043e\u0442\u043e\u0440\u044b\u0435, \u043a\u043e\u043d\u0435\u0447\u043d\u043e, \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0442 \u043f\u043e-\u0440\u0430\u0437\u043d\u043e\u043c\u0443.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/qu\/c7\/dl\/quc7dlfz889gyskbh-jm_cxloq8.jpeg\"><\/p>\n<p>  \u0412 Kotlin\/Native \u0435\u0441\u0442\u044c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u0438, \u043e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0438\u0437 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0437\u0430\u043a\u043b\u044e\u0447\u0430\u0435\u0442\u0441\u044f \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u0438\u043c\u043c\u0443\u0442\u0430\u0431\u0435\u043b\u044c\u043d\u044b\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u044b \u043c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u043c\u0435\u0436\u0434\u0443 \u043f\u043e\u0442\u043e\u043a\u0430\u043c\u0438. \u0422\u043e \u0435\u0441\u0442\u044c \u043f\u0440\u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u043c\u0435\u0436\u0434\u0443 \u043f\u043e\u0442\u043e\u043a\u0430\u043c\u0438 \u043e\u043d \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u043c\u043e\u0440\u043e\u0436\u0435\u043d, \u0441\u0434\u0435\u043b\u0430\u043d \u0438\u043c\u043c\u0443\u0442\u0430\u0431\u0435\u043b\u044c\u043d\u044b\u043c, \u0438 \u043e\u0431\u0440\u0430\u0442\u043d\u043e\u0439 \u0434\u043e\u0440\u043e\u0433\u0438 \u0443\u0436\u0435 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442, \u0440\u0430\u0437\u043c\u043e\u0440\u043e\u0437\u0438\u0442\u044c \u043c\u044b \u0435\u0433\u043e \u043d\u0435 \u0441\u043c\u043e\u0436\u0435\u043c. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0432\u0441\u0451, \u043d\u0430 \u0447\u0442\u043e \u0441\u0441\u044b\u043b\u0430\u0435\u0442\u0441\u044f \u044d\u0442\u043e\u0442 \u043e\u0431\u044a\u0435\u043a\u0442, \u0442\u0430\u043a\u0436\u0435 \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u043c\u043e\u0440\u043e\u0436\u0435\u043d\u043e. \u0415\u0441\u043b\u0438 \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0442\u044c \u043c\u0443\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u044d\u0442\u043e\u0442 \u043e\u0431\u044a\u0435\u043a\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u0435\u0440\u0435\u0448\u0435\u043b \u043c\u0435\u0436\u0434\u0443 \u0440\u0430\u0437\u043d\u044b\u043c\u0438 \u043f\u043e\u0442\u043e\u043a\u0430\u043c\u0438 \u0432 Kotlin\/Native, \u0442\u043e \u0432\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u0435 InvalidImmutabilityException \u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0443\u043f\u0430\u0434\u0435\u0442.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/gq\/-_\/ph\/gq-_phvnv-bermicgceazulp69m.jpeg\"><\/p>\n<p>  \u041a\u043e\u043d\u0435\u0447\u043d\u043e, \u0432 Kotlin\/Native \u0435\u0441\u0442\u044c \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c\u044b \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u0442\u0430\u043a\u0438\u043c\u0438 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f\u043c\u0438. \u041d\u043e \u0432\u0441\u0435 \u043e\u043d\u0438 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0441\u043b\u043e\u0436\u043d\u044b\u0435, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u0430\u044f \u0432\u0435\u0440\u0441\u0438\u044f \u043a\u043e\u0440\u0443\u0442\u0438\u043d \u0432 Kotlin\/Native \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430 \u0433\u043b\u0430\u0432\u043d\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435, \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430 Dispatchers.Main. \u0414\u0430, \u0443 \u0432\u0430\u0441 \u0431\u0443\u0434\u0435\u0442 \u0430\u0441\u0438\u043d\u0445\u0440\u043e\u043d\u043d\u043e\u0441\u0442\u044c, \u043d\u043e \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043c\u0435\u0436\u0434\u0443 \u043f\u043e\u0442\u043e\u043a\u0430\u043c\u0438 \u0432\u044b \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0438\u0442\u044c\u0441\u044f \u043d\u0435 \u0441\u043c\u043e\u0436\u0435\u0442\u0435.<\/p>\n<p>  \u041a\u043e\u043d\u0435\u0447\u043d\u043e, \u044d\u0442\u043e \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u0430\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430, \u043f\u043e \u043f\u043e\u0432\u043e\u0434\u0443 \u043d\u0435\u0435 \u0431\u044b\u043b \u0441\u043e\u0437\u0434\u0430\u043d issue: \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u043f\u043e\u0442\u043e\u043a\u043e\u0432 \u0432 \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u0430\u0445 \u043d\u0430 Kotlin\/Native.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/nv\/6_\/4h\/nv6_4h2mftc8bikeojpuoiumbqo.jpeg\"><\/p>\n<p>  \u0412 \u044d\u0442\u043e\u0442 \u043c\u043e\u043c\u0435\u043d\u0442, \u043d\u0430\u0447\u0438\u043d\u0430\u044f \u0441 1.3.8, 1.3.9, \u0443 \u043a\u043e\u0440\u0443\u0442\u0438\u043d \u043f\u043e\u044f\u0432\u0438\u043b\u0441\u044f \u0444\u043e\u0440\u043a, \u0442\u043e \u0435\u0441\u0442\u044c \u043d\u0430\u0440\u044f\u0434\u0443 \u0441\u043e \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0435\u0439 \u043d\u0430\u0447\u0430\u043b\u0430 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0442\u044c\u0441\u044f \u0432\u0435\u0440\u0441\u0438\u044f \u043a\u043e\u0440\u0443\u0442\u0438\u043d, \u0433\u0434\u0435 \u044d\u0442\u0430 \u043c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043d\u043e\u0441\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043d\u0430 iOS.<\/p>\n<p>  \u042d\u0442\u043e\u0442 \u0444\u043e\u0440\u043a \u0431\u0443\u0434\u0435\u0442 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0442\u044c\u0441\u044f, \u043f\u043e\u043a\u0430 \u043a\u043e\u043b\u043b\u0435\u0433\u0438 \u0438\u0437 JetBrains \u043d\u0435 \u043f\u0435\u0440\u0435\u043f\u0438\u0448\u0443\u0442 \u0441\u0431\u043e\u0440\u0449\u0438\u043a \u043c\u0443\u0441\u043e\u0440\u0430 (Garbage Collector). \u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u0444\u043e\u0440\u043a \u0441 native-mt-\u043a\u043e\u0440\u0443\u0442\u0438\u043d\u0430\u043c\u0438, \u0441\u043a\u043e\u0440\u0435\u0435 \u0432\u0441\u0435\u0433\u043e, \u0432\u043e\u043b\u044c\u0435\u0442\u0441\u044f \u0432 \u043c\u0430\u0441\u0442\u0435\u0440-\u0432\u0435\u0442\u043a\u0443. \u0414\u043e \u0442\u0435\u0445 \u043f\u043e\u0440 \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043b\u0438\u0431\u043e \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u0431\u0435\u0437 \u043c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043d\u043e\u0441\u0442\u0438, \u043b\u0438\u0431\u043e native-mt.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/c6\/an\/86\/c6an86fe48yu2sl5kxsx84mokni.jpeg\"><\/p>\n<p>  \u041d\u043e \u043a\u043e\u0433\u0434\u0430 \u043c\u044b \u0434\u0435\u043b\u0430\u043b\u0438 \u0441\u0432\u043e\u044e \u0444\u0438\u0447\u0443, \u0442\u043e native-mt-\u043a\u043e\u0440\u0443\u0442\u0438\u043d \u0435\u0449\u0435 \u043d\u0435 \u0431\u044b\u043b\u043e, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043d\u0430\u043c \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u0434\u0435\u043b\u0430\u0442\u044c \u043a\u043e\u0441\u0442\u044b\u043b\u0438, \u0447\u0442\u043e\u0431\u044b \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043a\u043e\u0434 \u043d\u0430 iOS \u0432 \u0434\u0440\u0443\u0433\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435. \u041d\u0430 Android \u043c\u044b \u043e\u0441\u0442\u0430\u0432\u0438\u043b\u0438 \u0442\u0443 \u0436\u0435 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u0441 \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u0430\u043c\u0438, \u043e\u043d\u0430 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/-t\/oo\/wy\/-toowydrzyea8tli3e_boxbecos.jpeg\"><\/p>\n<p>  \u041d\u0430 iOS actual-\u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u0434\u0440\u0443\u0433\u043e\u0439.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/pr\/hp\/-r\/prhp-ranjztv9cvcixitgl9sbrg.jpeg\"><\/p>\n<p>  \u041c\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 stately, \u0447\u0442\u043e\u0431\u044b \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0442\u044c \u043a\u043e\u043b\u043b\u0431\u044d\u043a, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d \u043d\u0430 \u0433\u043b\u0430\u0432\u043d\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e ThreadLocalRef.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/3n\/_m\/rn\/3n_mrnf0k4xntma3blgcyl-3as4.jpeg\"><\/p>\n<p>  \u0414\u0430\u043b\u0435\u0435 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u0432 \u0444\u043e\u043d\u043e\u0432\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435 \u043b\u044f\u043c\u0431\u0434\u0443, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0434\u043e\u043b\u0436\u043d\u0430 \u0431\u044b\u0442\u044c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0430 \u0432 \u0444\u043e\u043d\u0435.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/9m\/t_\/c-\/9mt_c-6wmd5xauwutrvqordocbe.jpeg\"><\/p>\n<p>  \u041f\u043e\u0441\u043b\u0435 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430 \u0432\u044b\u0442\u0430\u0441\u043a\u0438\u0432\u0430\u0435\u043c \u0438\u0437 ThreadLocalRef \u043d\u0430\u0448 \u043a\u043e\u043b\u043b\u0431\u044d\u043a \u0438 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u0435\u0433\u043e. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u0437\u0434\u0435\u0441\u044c \u043d\u0435 \u043f\u0440\u043e\u0438\u0437\u043e\u0439\u0434\u0435\u0442 \u0437\u0430\u043c\u043e\u0440\u0430\u0436\u0438\u0432\u0430\u043d\u0438\u0435 \u043a\u043e\u043b\u043b\u0431\u044d\u043a\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b\u0437\u0432\u0430\u043d \u043d\u0430 \u0433\u043b\u0430\u0432\u043d\u043e\u0439.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/fh\/5d\/-r\/fh5d-rc8026gjdr_6rjfsy5_qhw.jpeg\"><\/p>\n<p>  \u041d\u043e \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u0431\u043b\u043e\u043a, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u043d\u0430 \u0444\u043e\u043d\u043e\u0432\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435, \u0432\u0441\u0435 \u0440\u0430\u0432\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u043c\u043e\u0440\u043e\u0436\u0435\u043d, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043d\u0435\u043b\u044c\u0437\u044f, \u0447\u0442\u043e\u0431\u044b \u0442\u0443\u0434\u0430 \u043f\u043e\u043f\u0430\u0434\u0430\u043b \u043c\u0443\u0442\u0430\u0431\u0435\u043b\u044c\u043d\u044b\u0439 \u043e\u0431\u044a\u0435\u043a\u0442 \u0438\u043b\u0438 \u0442\u043e, \u0447\u0442\u043e \u043d\u0435 \u0434\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c \u0437\u0430\u043c\u043e\u0440\u043e\u0436\u0435\u043d\u043e.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/ij\/uh\/h_\/ijuhh_4spibviyx3qub_u21st0u.jpeg\"><\/p>\n<p>  \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043c\u044b \u0441\u0434\u0435\u043b\u0430\u043b\u0438 \u0444\u0443\u043d\u043a\u0446\u0438\u044e, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0443\u043c\u0435\u0435\u0442 \u0447\u0435\u0441\u0442\u043d\u043e \u0445\u043e\u0434\u0438\u0442\u044c \u0432 \u0444\u043e\u043d \u043d\u0430 iOS. \u041d\u043e \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0435\u0435 \u0432 \u0441\u0432\u044f\u0437\u043a\u0435 \u0441 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u0430\u043c\u0438. \u0415\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c \u043e\u0431\u0435\u0440\u043d\u0443\u0442\u044c \u0438 \u0442\u043e\u0436\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0438\u0437 \u043d\u0435\u0435 \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u0443.<\/p>\n<p>  \u041d\u043e \u043c\u044b \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u043b\u0438\u0441\u044c \u0441 \u0442\u0435\u043c, \u0447\u0442\u043e \u0435\u0441\u043b\u0438 \u043e\u0431\u0435\u0440\u043d\u0443\u0442\u044c \u044d\u0442\u0443 \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u0443 \u0432 try-catch, \u0442\u043e \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u043f\u043e\u0439\u043c\u0430\u043d\u043e, \u0443 \u0432\u0430\u0441 \u0441\u043b\u0443\u0447\u0438\u0442\u0441\u044f \u043f\u0430\u0434\u0435\u043d\u0438\u0435 \u0432 \u0440\u0430\u043d\u0442\u0430\u0439\u043c\u0435.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/9g\/th\/gf\/9gthgfkus5-mzkqjphjhzutjp70.jpeg\"><\/p>\n<p>  \u0420\u0435\u0448\u0435\u043d\u0438\u0435 \u0437\u0434\u0435\u0441\u044c \u0442\u0430\u043a\u043e\u0435:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/mz\/xc\/5e\/mzxc5empl0hqu_ep2kl9pgtqvqa.jpeg\"><\/p>\n<p>  \u041d\u0443\u0436\u043d\u043e \u043e\u0442\u043b\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u0432 \u0444\u043e\u043d\u043e\u0432\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435, \u0442\u043e \u0435\u0441\u0442\u044c \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c try-catch \u0432 \u043b\u044f\u043c\u0431\u0434\u0435 \u0434\u043b\u044f \u0444\u043e\u043d\u043e\u0432\u043e\u0433\u043e \u043f\u043e\u0442\u043e\u043a\u0430 \u0438 \u043f\u0440\u043e\u043a\u0438\u0434\u044b\u0432\u0430\u0442\u044c \u043c\u0435\u0436\u0434\u0443 \u043f\u043e\u0442\u043e\u043a\u0430\u043c\u0438 \u0443\u0436\u0435 \u043a\u0430\u043a\u043e\u0439-\u0442\u043e \u0441\u0432\u043e\u0439 \u043e\u0431\u044a\u0435\u043a\u0442, BackgroundActionResult. \u0415\u0441\u043b\u0438 \u0435\u0441\u0442\u044c \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435, \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c \u043d\u0430 \u0433\u043b\u0430\u0432\u043d\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435 \u043c\u0435\u0442\u043e\u0434 Continuation.resumeWithException(). \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043e\u0431\u0435\u0440\u043d\u0443\u0442\u044c \u043d\u0430\u0448 \u043c\u0435\u0442\u043e\u0434 coroutineOnBackground() \u0432 try-catch \u0438 \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e \u043e\u0442\u043b\u043e\u0432\u0438\u0442\u044c \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435, \u043d\u0435 \u043f\u043e\u043b\u0443\u0447\u0430\u044f \u043f\u0430\u0434\u0435\u043d\u0438\u044f \u0432 \u0440\u0430\u043d\u0442\u0430\u0439\u043c\u0435. <\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/zo\/ck\/4w\/zock4w5xvrcs9nwks65cd8aigwk.jpeg\"><\/p>\n<p>  \u0415\u0449\u0435 \u043e\u0434\u043d\u0430 \u0442\u043e\u043d\u043a\u043e\u0441\u0442\u044c, \u0441 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043c\u044b \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u043b\u0438\u0441\u044c, \u043a\u043e\u0433\u0434\u0430 \u043f\u043e\u043f\u044b\u0442\u0430\u043b\u0438\u0441\u044c \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043a\u043e\u0434 \u043d\u0430 iOS: \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 Dispatcher \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u043b.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/z4\/jx\/w8\/z4jxw8frxwrt1lhaxtiv8avvzto.jpeg\"><\/p>\n<p>  \u041e\u043d \u0432\u044b\u0434\u0430\u0432\u0430\u043b \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u043f\u0440\u0438 \u043f\u043e\u043f\u044b\u0442\u043a\u0435 \u0435\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c. \u041f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u043d\u0430\u043f\u0438\u0441\u0430\u0442\u044c \u0441\u0432\u043e\u0439 Dispatcher, \u0447\u0442\u043e\u0431\u044b \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0431\u043b\u043e\u043a\u0438 \u043a\u043e\u0434\u0430 \u043d\u0430 \u0433\u043b\u0430\u0432\u043d\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043c\u044b \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043b\u0438 \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u044b \u043d\u0430 iOS.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/ym\/ay\/sj\/ymaysjr6dhhsbhtimqvgbmwmm6e.jpeg\"><\/p>\n<p>  \u041d\u043e \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u0435\u0441\u043b\u0438 \u0441 \u0442\u0430\u043a\u0438\u043c \u0441\u0430\u043c\u043e\u043f\u0438\u0441\u043d\u044b\u043c \u0434\u0438\u0441\u043f\u0430\u0442\u0447\u0435\u0440\u043e\u043c \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043d\u0435\u0447\u0442\u043e \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0435\u0435 \u0437\u0430\u0434\u0435\u0440\u0436\u043a\u0443 \u2014 \u043b\u0438\u0431\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 delay(), \u043b\u0438\u0431\u043e \u0432\u043e flow \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043a\u0430\u043a\u043e\u0439-\u043d\u0438\u0431\u0443\u0434\u044c debounce, \u2014 \u0442\u043e \u0432\u0441\u0435 \u0441\u043b\u043e\u043c\u0430\u0435\u0442\u0441\u044f.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/3q\/cp\/do\/3qcpdo5xjjjkjohr5reewh5xims.jpeg\"><\/p>\n<p>  \u0422\u0430\u043a \u0447\u0442\u043e \u044d\u0442\u043e \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0442\u043e\u0440 \u0438\u043b\u0438 \u0441\u0438\u0441\u0442\u0435\u043c\u0430 \u0432\u0430\u043c \u043d\u0438\u0447\u0435\u0433\u043e \u043d\u0435 \u0441\u043a\u0430\u0436\u0435\u0442 \u043e \u0442\u043e\u043c, \u0447\u0442\u043e \u0443 \u0432\u0430\u0441 \u0447\u0442\u043e-\u0442\u043e \u043d\u0435 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043e. \u0417\u0434\u0435\u0441\u044c \u043d\u0443\u0436\u043d\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u0435\u0449\u0435 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 Delay, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0435\u0441\u0442\u044c \u0434\u0432\u0430 \u043c\u0435\u0442\u043e\u0434\u0430. \u0420\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u0432 \u0438\u0445, \u0432\u044b \u0441\u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0437\u0430\u0434\u0435\u0440\u0436\u043a\u0443 \u043d\u0430 iOS.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/ny\/cp\/8h\/nycp8hhbcusnc_cvo1_mp9deyd4.jpeg\"><\/p>\n<p>  \u041d\u043e, \u043a \u0441\u0447\u0430\u0441\u0442\u044c\u044e, \u0432 \u0432\u0435\u0442\u043a\u0435 native-mt \u0443\u0436\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u044b\u0435 \u0434\u0438\u0441\u043f\u0430\u0442\u0447\u0435\u0440\u044b, \u043e\u043d\u0438 \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0442 \u0442\u0430\u043a, \u043a\u0430\u043a \u043e\u0436\u0438\u0434\u0430\u0435\u0442\u0441\u044f. \u0414\u0430, \u0442\u0430\u043c \u0435\u0441\u0442\u044c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u043e\u0433\u0440\u0430\u043d\u0438\u0447\u043d\u044b\u0435 \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u0438, \u0432 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043c\u043e\u0433\u0443\u0442 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442\u044c \u0443\u0442\u0435\u0447\u043a\u0438 \u043f\u0430\u043c\u044f\u0442\u0438, \u043d\u043e \u0435\u0441\u043b\u0438 \u0432\u0430\u043c \u043d\u0435 \u0441\u0442\u0440\u0430\u0448\u043d\u043e, \u0442\u043e\u0433\u0434\u0430 \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c native-mt \u0432\u0435\u0440\u0441\u0438\u044e.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/zn\/nd\/je\/znndjehrlgeqw1slkebp_ihu-jg.jpeg\"><\/p>\n<p>  \u0412\u0435\u0440\u0434\u0438\u043a\u0442: \u0432 \u0446\u0435\u043b\u043e\u043c \u0441 \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u0430\u043c\u0438 \u043c\u043e\u0436\u043d\u043e \u0436\u0438\u0442\u044c, \u043d\u043e \u0441\u0442\u0430\u043d\u0435\u0442 \u0433\u043e\u0440\u0430\u0437\u0434\u043e \u043b\u0443\u0447\u0448\u0435, \u043a\u043e\u0433\u0434\u0430 \u0444\u043e\u0440\u043a native-mt \u043f\u043e\u044f\u0432\u0438\u0442\u0441\u044f \u0432 \u043c\u0430\u0441\u0442\u0435\u0440\u0435. \u041f\u043e \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u0430\u043c \u0432 \u0441\u0435\u0442\u0438 \u0435\u0441\u0442\u044c \u043a\u0443\u0447\u0430 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438, \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u043e\u0442 Android-\u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0432 Android \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u044b \u0443\u0436\u0435 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0448\u0438\u0440\u043e\u043a\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f. \u041f\u043e common-\u0447\u0430\u0441\u0442\u0438 \u043c\u0443\u043b\u044c\u0442\u0438\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u044b \u043d\u0435 \u0442\u0430\u043a \u043c\u043d\u043e\u0433\u043e \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438, \u043d\u043e \u043e\u043d\u0430 \u0435\u0441\u0442\u044c.<\/p>\n<p>  \u041a\u043e\u0440\u0443\u0442\u0438\u043d\u044b \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u043c \u044f\u0437\u044b\u043a\u0430. \u042d\u0442\u043e \u0437\u043d\u0430\u0447\u0438\u0442, \u0447\u0442\u043e \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u043e \u0431\u0443\u0434\u0443\u0442 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f, \u0431\u0443\u0434\u0443\u0442 \u0447\u0438\u043d\u0438\u0442\u044c\u0441\u044f \u0431\u0430\u0433\u0438 \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435, \u044d\u0442\u043e \u043e\u0434\u043d\u043e\u0437\u043d\u0430\u0447\u043d\u043e \u043f\u043b\u044e\u0441. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u043d\u0430 iOS \u0438 Android \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f \u043b\u043e\u0433\u0438\u043a\u0430, \u0442\u043e \u0435\u0441\u0442\u044c \u0432\u0441\u0435\u0433\u0434\u0430 \u043d\u0443\u0436\u043d\u043e \u0434\u0443\u043c\u0430\u0442\u044c \u043e \u0434\u0440\u0443\u0433\u043e\u0439 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435.<\/p>\n<p>  \u0415\u0449\u0435 \u043e\u0434\u043d\u0430 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e \u043d\u0430\u0448\u0430 \u0431\u043e\u043b\u044c: \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u043b\u043e\u0441\u044c \u0432\u0440\u0435\u043c\u044f \u043d\u0430 \u043e\u0441\u0432\u043e\u0435\u043d\u0438\u0435, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0434\u043e \u044d\u0442\u043e\u0433\u043e \u0432 Android-\u0447\u0430\u0441\u0442\u0438 \u0443 \u043d\u0430\u0441 \u043d\u0435 \u0431\u044b\u043b\u043e \u043a\u043e\u0440\u0443\u0442\u0438\u043d, \u043e\u043d\u0438 \u043f\u043e\u044f\u0432\u0438\u043b\u0438\u0441\u044c \u0432 common-\u0447\u0430\u0441\u0442\u0438 \u0438 \u043d\u0443\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u043f\u0440\u044f\u043c\u043e \u0441 \u043d\u0443\u043b\u044f \u043e\u0441\u0432\u0430\u0438\u0432\u0430\u0442\u044c, \u0442\u0430\u043a \u043a\u0430\u043a \u044d\u0442\u043e \u0441\u043e\u0432\u0435\u0440\u0448\u0435\u043d\u043d\u043e \u0434\u0440\u0443\u0433\u043e\u0439 \u043f\u043e\u0434\u0445\u043e\u0434, \u043e\u0442\u043b\u0438\u0447\u043d\u044b\u0439 \u043e\u0442 RxJava.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/7-\/r8\/ej\/7-r8ejwae__8yojzlh-fogmgmd8.jpeg\"><\/p>\n<p>  \u041a\u043e\u0433\u0434\u0430 \u043c\u044b \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u0438\u043b\u0438 \u043b\u043e\u0433\u0438\u043a\u0443 \u0438\u0437 Android-\u0447\u0430\u0441\u0442\u0438 \u0432 common, \u043d\u0430\u043c \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u043f\u0435\u0440\u0435\u043d\u0435\u0441\u0442\u0438 \u0442\u0430\u043a\u0436\u0435 \u0438 \u0440\u0438\u0441\u043e\u0432\u0430\u043b\u043a\u0443 \u043d\u0430 \u043a\u0430\u0440\u0442\u0435, \u0442\u043e \u0435\u0441\u0442\u044c \u0441\u0443\u0449\u043d\u043e\u0441\u0442\u044c, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0443\u043c\u0435\u0435\u0442 \u0440\u0435\u043d\u0434\u0435\u0440\u0438\u0442\u044c \u043e\u0431\u044a\u0435\u043a\u0442\u044b \u043d\u0430 \u043a\u0430\u0440\u0442\u0435. \u0412 Android \u043e\u043d\u0430 \u0442\u043e\u0436\u0435 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0430 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c RxJava, \u044d\u0442\u043e \u043e\u0447\u0435\u043d\u044c \u043e\u0431\u0448\u0438\u0440\u043d\u044b\u0439 \u043a\u043b\u0430\u0441\u0441, \u043e\u0447\u0435\u043d\u044c \u043c\u043d\u043e\u0433\u043e \u043b\u043e\u0433\u0438\u043a\u0438. \u0425\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u0440\u0435\u0430\u043a\u0442\u0438\u0432\u043d\u043e\u0441\u0442\u0438 \u0432 common-\u0447\u0430\u0441\u0442\u0438. \u041f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0442\u0430\u043a, \u043a\u0430\u043a \u043c\u044b \u043f\u0438\u0448\u0435\u043c \u043d\u0430 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/yi\/8q\/fo\/yi8qfow_o7edo5qxtvicmngghlg.jpeg\"><\/p>\n<p>  \u041c\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0438 flow. \u0427\u0442\u043e \u043c\u044b \u0437\u0430\u043c\u0435\u0442\u0438\u043b\u0438? \u0427\u0442\u043e \u0431\u0430\u0437\u043e\u0432\u044b\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0430\u043d\u044b, \u043e\u043d\u0438 \u0435\u0441\u0442\u044c, \u0445\u043e\u0442\u044f \u043d\u0430\u0437\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u043e-\u0434\u0440\u0443\u0433\u043e\u043c\u0443, \u043d\u043e \u0442\u0435\u043c \u043d\u0435 \u043c\u0435\u043d\u0435\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0442.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/en\/td\/ao\/entdaoabmyg7lf2vtdtgrq6es28.jpeg\"><\/p>\n<p>  \u0415\u0441\u0442\u044c \u043e\u0442\u043b\u0438\u0447\u0438\u044f \u0438 \u0432 \u043b\u043e\u0433\u0438\u043a\u0435 \u0440\u0430\u0431\u043e\u0442\u044b. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, flowOn() \u0432\u043b\u0438\u044f\u0435\u0442 \u043d\u0435 \u043d\u0430 downstream, \u043a\u0430\u043a observeOn(), \u0430 \u043d\u0430 upstream. \u0418\u043b\u0438, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, collect(), \u0432 \u043e\u0442\u043b\u0438\u0447\u0438\u0435 \u043e\u0442 subscribe(), \u2014 \u044d\u0442\u043e suspend-\u0444\u0443\u043d\u043a\u0446\u0438\u044f \u0438 \u0438\u043d\u043e\u0433\u0434\u0430 \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u043f\u043e\u0440\u043e\u0442\u044c\u0441\u044f \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e \u043f\u0440\u0438 \u0432\u044b\u0437\u043e\u0432\u0435 \u0434\u0432\u0443\u0445 \u043f\u043e\u0434\u0440\u044f\u0434 collect() \u0432\u0442\u043e\u0440\u043e\u0439 \u043c\u0435\u0442\u043e\u0434 \u043d\u0435 \u0432\u044b\u0437\u043e\u0432\u0435\u0442\u0441\u044f, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u043f\u0440\u043e\u0438\u0437\u043e\u0439\u0434\u0435\u0442 \u043f\u0440\u0438\u043e\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 (suspend) \u0432 \u043f\u0435\u0440\u0432\u043e\u043c. \u0412 \u044d\u0442\u043e\u043c \u0438 \u0431\u044b\u043b\u0438 \u043e\u0442\u043b\u0438\u0447\u0438\u044f \u043e\u0442 RxJava \u0438 RxSwift.<\/p>\n<p>  \u0422\u0430\u043a\u0436\u0435 \u043d\u0430 iOS \u0432 \u043d\u0430\u0448\u0435\u043c \u0440\u0430\u0441\u043f\u043e\u0440\u044f\u0436\u0435\u043d\u0438\u0438 \u0442\u043e\u043b\u044c\u043a\u043e Dispatchers.Main, \u0442\u043e \u0435\u0441\u0442\u044c \u043c\u044b \u043d\u0435 \u043c\u043e\u0436\u0435\u043c \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u0434\u0438\u0441\u043f\u0430\u0442\u0447\u0435\u0440\u044b \u0432\u043e flow \u0441\u043e \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0435\u0439 \u043a\u043e\u0440\u0443\u0442\u0438\u043d.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/rm\/p4\/jq\/rmp4jqfpb-hjzhc5pf2fqq3miro.jpeg\"><\/p>\n<p>  \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u0441\u043b\u043e\u0436\u043d\u044b\u0435 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0438 \u043c\u044b \u0441\u0434\u0435\u043b\u0430\u043b\u0438 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043d\u0430\u0448\u0435\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 coroutineOnBackground(). \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c \u0441\u0447\u0438\u0442\u0430\u0442\u044c \u0434\u0438\u0444\u0444\u044b \u043d\u0430 \u0434\u0440\u0443\u0433\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435 \u0438 \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0442\u044c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u043e\u0431\u0440\u0430\u0442\u043d\u043e \u043d\u0430 \u0433\u043b\u0430\u0432\u043d\u044b\u0439.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/kb\/3h\/xa\/kb3hxasqur_gknaquwmmloyuv18.jpeg\"><\/p>\n<p>  \u0422\u0430\u043a\u0436\u0435 \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u043b\u0438\u0441\u044c \u0441 \u0442\u0435\u043c, \u0447\u0442\u043e \u0432\u043e flow \u043d\u0435 \u0431\u044b\u043b\u043e \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u044b\u043b\u0438 \u0443 \u043d\u0430\u0441 \u0432 Android-\u0447\u0430\u0441\u0442\u0438. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043d\u0435\u043b\u044c\u0437\u044f \u0431\u044b\u043b\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c replay(), share() \u0438 publish(). \u041f\u0440\u0438\u0445\u043e\u0434\u0438\u043b\u043e\u0441\u044c \u0438\u0434\u0442\u0438 \u043e\u0431\u0445\u043e\u0434\u043d\u044b\u043c\u0438 \u043f\u0443\u0442\u044f\u043c\u0438 \u0438 \u043f\u0438\u0441\u0430\u0442\u044c \u0441\u0432\u043e\u044e \u043b\u043e\u0433\u0438\u043a\u0443 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c Channel \u0438 flow, \u0441\u0432\u043e\u0438 \u0432\u0435\u043b\u043e\u0441\u0438\u043f\u0435\u0434\u044b.<\/p>\n<p>  \u041d\u043e, \u043a \u0441\u0447\u0430\u0441\u0442\u044c\u044e, \u0432\u0441\u0435 \u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f, \u0443\u0436\u0435 \u0432 \u0432\u0435\u0440\u0441\u0438\u0438 1.4 \u043f\u043e\u044f\u0432\u0438\u043b\u0441\u044f Shared flow, \u0430\u043d\u0430\u043b\u043e\u0433 \u0433\u043e\u0440\u044f\u0447\u0435\u0433\u043e Observable \u0432 RxJava. \u041e\u043d \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b replay(), share() \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/fc\/ap\/wj\/fcapwjuvute8_jcrvv2sdfuutdk.jpeg\"><\/p>\n<p>  \u041a\u0430\u043a\u043e\u0439 \u0438\u0442\u043e\u0433 \u043f\u043e flow? \u041e \u043d\u0435\u043c \u0442\u043e\u0436\u0435 \u0435\u0441\u0442\u044c \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044f \u0432 \u0441\u0435\u0442\u0438, \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u043e\u0442 Android-\u0441\u043e\u043e\u0431\u0449\u0435\u0441\u0442\u0432\u0430, \u0438 \u0442\u043e\u0436\u0435 \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u0435 \u043d\u0430 iOS \u0438 Android. \u0422\u043e \u0435\u0441\u0442\u044c \u0437\u0434\u0435\u0441\u044c \u0442\u0435 \u0436\u0435 \u0441\u0430\u043c\u044b\u0435 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f, \u0447\u0442\u043e \u0438 \u0443 \u043a\u043e\u0440\u0443\u0442\u0438\u043d \u043d\u0430 Kotlin\/Native. \u041d\u043e \u0432\u0441\u0435 \u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u0432 \u0432\u0435\u0442\u043a\u0435 native-mt. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u043d\u0430\u043c \u0442\u0430\u043a\u0436\u0435 \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u0437\u0430\u043a\u043b\u0430\u0434\u044b\u0432\u0430\u0442\u044c \u0432\u0440\u0435\u043c\u044f \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e\u0431\u044b \u0440\u0430\u0437\u0431\u0438\u0440\u0430\u0442\u044c\u0441\u044f. \u041f\u043e\u0434\u0445\u043e\u0434 \u0432\u0441\u0435-\u0442\u0430\u043a\u0438 \u0434\u0440\u0443\u0433\u043e\u0439, \u044d\u0442\u043e \u043d\u0435 Rx, \u0438 \u043a\u043e\u0434 \u0438\u0437 Android-\u0447\u0430\u0441\u0442\u0438 \u043d\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c \u043f\u0435\u0440\u0435\u043d\u0435\u0441\u0442\u0438 \u0431\u0435\u0437 \u0441\u0435\u0440\u044c\u0435\u0437\u043d\u043e\u0433\u043e \u0440\u0435\u0444\u0430\u043a\u0442\u043e\u0440\u0438\u043d\u0433\u0430. \u0422\u0430\u043c, \u0433\u0434\u0435 \u0443 \u043d\u0430\u0441 \u0431\u044b\u043b\u0438 \u0441\u043b\u043e\u0436\u043d\u044b\u0435 \u0446\u0435\u043f\u043e\u0447\u043a\u0438, \u043d\u0443\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u0430\u043a\u043a\u0443\u0440\u0430\u0442\u043d\u043e \u0432\u0441\u0451 \u043f\u0435\u0440\u0435\u043f\u0438\u0441\u044b\u0432\u0430\u0442\u044c \u043d\u0430 flow, \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043f\u043e\u043c\u043d\u0438\u0442\u044c \u043f\u0440\u043e \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u0438 iOS, \u0442\u043e \u0435\u0441\u0442\u044c \u043f\u0440\u043e \u0437\u0430\u043c\u043e\u0440\u043e\u0437\u043a\u0443 \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/tb\/mn\/wp\/tbmnwpdh7rybv6a5vuht7uy912q.jpeg\"><\/p>\n<p>  \u0420\u0435\u0431\u044f\u0442\u0430 \u0438\u0437 \u0434\u0440\u0443\u0433\u0438\u0445 \u043a\u043e\u043c\u0430\u043d\u0434 \u0441\u043f\u0440\u0430\u0448\u0438\u0432\u0430\u043b\u0438: \u00ab\u041f\u043e\u0447\u0435\u043c\u0443 \u0432\u044b \u043d\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0435 Reaktive?\u00bb \u042d\u0442\u043e \u0442\u0430\u043a\u0430\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 \u0434\u043b\u044f \u043c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043d\u043e\u0441\u0442\u0438 \u0432 \u043c\u0443\u043b\u044c\u0442\u0438\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435. \u041c\u044b \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0437\u0430\u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043e\u0432\u0430\u043b\u0438\u0441\u044c \u0438 \u0440\u0435\u0448\u0438\u043b\u0438 \u0438\u0441\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u044c. \u0411\u044b\u043b\u043e \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0432\u043e\u043f\u0440\u043e\u0441\u043e\u0432, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043d\u0443\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u043e\u0442\u0432\u0435\u0442\u0438\u0442\u044c \u043f\u0435\u0440\u0435\u0434 \u0442\u0435\u043c, \u043a\u0430\u043a \u0432\u043d\u0435\u0434\u0440\u044f\u0442\u044c \u0435\u0435 \u0441\u0435\u0431\u0435 \u0432 \u043f\u0440\u043e\u0434\u0430\u043a\u0448\u0435\u043d-\u043a\u043e\u0434.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/8p\/vv\/6t\/8pvv6tp3vxpjddih_shbu7irhmu.jpeg\"><\/p>\n<p>  \u041f\u0435\u0440\u0432\u044b\u0439 \u0432\u043e\u043f\u0440\u043e\u0441: \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f API Reaktive \u043e\u0442 RxJava? \u041d\u0430 \u043f\u0435\u0440\u0432\u044b\u0439 \u0432\u0437\u0433\u043b\u044f\u0434, \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439 \u043d\u0435 \u0442\u0430\u043a \u043c\u043d\u043e\u0433\u043e, \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u0432\u0441\u0435 \u0438\u0437 \u043d\u0438\u0445 \u0432\u044b \u0432\u0438\u0434\u0438\u0442\u0435 \u043d\u0430 \u0441\u043b\u0430\u0439\u0434\u0435. \u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u044b \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0430\u043d\u044b, \u0435\u0441\u0442\u044c \u0443\u043b\u0443\u0447\u0448\u0435\u043d\u0438\u044f, \u043c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c null, \u0432 \u043e\u0442\u043b\u0438\u0447\u0438\u0435 \u043e\u0442 RxJava. \u041d\u043e \u043f\u0440\u0438 \u044d\u0442\u043e\u043c, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043d\u0435\u0442 \u0432\u044b\u0431\u043e\u0440\u0430 \u0441\u0442\u0440\u0430\u0442\u0435\u0433\u0438\u0438 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u044f backpressure, \u0442\u043e \u0435\u0441\u0442\u044c \u043d\u0435\u0442 flowable. \u0417\u0430\u0442\u043e \u0435\u0441\u0442\u044c publish() \u0438 connectable(), \u043a\u0430\u043a \u0440\u0430\u0437 \u0442\u043e, \u0447\u0435\u0433\u043e \u043d\u0430\u043c \u043d\u0435 \u0445\u0432\u0430\u0442\u0430\u043b\u043e, \u043a\u043e\u0433\u0434\u0430 \u043c\u044b \u043f\u0435\u0440\u0435\u043f\u0438\u0441\u044b\u0432\u0430\u043b\u0438 \u043b\u043e\u0433\u0438\u043a\u0443 \u043d\u0430 flow.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/qp\/-2\/f8\/qp-2f8j31m_wi3cpywgeiqjel1k.jpeg\"><\/p>\n<p>  \u041f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043b\u0435\u0433\u043a\u043e, \u043a\u043e\u0434 \u0441 RxJava \u043f\u0435\u0440\u0435\u0435\u0445\u0430\u043b \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u0431\u0435\u0437 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439. \u041f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u043b\u043e\u0441\u044c \u043f\u043e\u043c\u0435\u043d\u044f\u0442\u044c \u0438\u043c\u043f\u043e\u0440\u0442\u044b \u0438 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0438 \u0432\u0441\u0435 \u043b\u0435\u0433\u043a\u043e \u0437\u0430\u0432\u0435\u043b\u043e\u0441\u044c \u043d\u0430 Android, \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043a\u0430\u043a \u0435\u0441\u0442\u044c. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u043d\u0430 iOS \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u043f\u0440\u043e\u0441\u043b\u0435\u0434\u0438\u0442\u044c \u0437\u0430 \u0437\u0430\u043c\u043e\u0440\u043e\u0437\u043a\u043e\u0439 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432, \u0442\u043e \u0435\u0441\u0442\u044c \u043b\u044e\u0431\u044b\u0435 \u043a\u043e\u043b\u043b\u0431\u044d\u043a\u0438 \u0438 \u043c\u0435\u0442\u043e\u0434\u044b doOnSomething() \u0432 Reaktive \u0431\u0443\u0434\u0443\u0442 \u0437\u0430\u043c\u043e\u0440\u043e\u0436\u0435\u043d\u044b \u043f\u0440\u0438 \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0438 \u043f\u043e\u0442\u043e\u043a\u043e\u0432, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0442\u0443\u0434\u0430 \u0442\u0430\u043a\u0436\u0435 \u043d\u0435 \u0434\u043e\u043b\u0436\u043d\u044b \u043f\u043e\u043f\u0430\u0434\u0430\u0442\u044c \u043d\u0438\u043a\u0430\u043a\u0438\u0435 \u0438\u0437\u043c\u0435\u043d\u044f\u0435\u043c\u044b\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u044b, \u043d\u0438\u043a\u0430\u043a\u0438\u0435 \u0441\u0441\u044b\u043b\u043a\u0438 \u043d\u0430 \u0442\u0430\u043a\u0438\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u044b, \u0438\u043d\u0430\u0447\u0435 \u043e\u043d\u0438 \u0431\u0443\u0434\u0443\u0442 \u0437\u0430\u043c\u043e\u0440\u043e\u0436\u0435\u043d\u044b.<\/p>\n<p>  \u0415\u0441\u0442\u044c \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 threadLocal() \u0432 Reaktive, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043e\u0431\u043e\u0439\u0442\u0438 \u0437\u0430\u043c\u043e\u0440\u043e\u0437\u043a\u0443. \u042d\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432 \u0441\u0432\u044f\u0437\u043a\u0435 \u0441 ktor. \u0421\u0435\u0439\u0447\u0430\u0441 \u0441 native-mt-\u043a\u043e\u0440\u0443\u0442\u0438\u043d\u0430\u043c\u0438 \u0441\u0442\u0430\u043b\u043e \u043f\u043e\u043b\u0443\u0447\u0448\u0435, \u043d\u043e \u0432\u0441\u0435 \u0440\u0430\u0432\u043d\u043e \u0435\u0441\u0442\u044c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f.<\/p>\n<p>  \u0421\u0430\u043c\u043e\u0435 \u0433\u043b\u0430\u0432\u043d\u043e\u0435, \u0447\u0442\u043e \u043d\u0430\u043c \u043d\u0443\u0436\u043d\u043e \u0437\u043d\u0430\u0442\u044c: \u043f\u043e\u0434 \u043a\u0430\u043f\u043e\u0442\u043e\u043c \u043d\u0435\u0442 \u043a\u043e\u0440\u0443\u0442\u0438\u043d. \u0420\u0435\u0431\u044f\u0442\u0430 \u0441\u0434\u0435\u043b\u0430\u043b\u0438 \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u043e \u0441\u0432\u043e\u0439, \u0441 \u043d\u0443\u043b\u044f \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u0439 \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c, \u043f\u0440\u043e \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u044e \u043f\u043e\u0441\u043b\u0443\u0448\u0430\u0442\u044c \u0434\u043e\u043a\u043b\u0430\u0434 \u0410\u0440\u043a\u0430\u0434\u0438\u044f \u0418\u0432\u0430\u043d\u043e\u0432\u0430 \u2014 \u0441\u043e\u0437\u0434\u0430\u0442\u0435\u043b\u044f \u044d\u0442\u043e\u0439 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438. \u041e\u043d \u043e\u0447\u0435\u043d\u044c \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u043e \u0442\u043e\u043c, \u043a\u0430\u043a \u043e\u043d\u0438 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043b\u0438 \u044d\u0442\u043e\u0442 \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c:<\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u0421\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0432\u0438\u0434\u0435\u043e<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<div class=\"oembed\"><iframe allowfullscreen id=\"602a40a5b4c396d242e09732\" src=\"https:\/\/embedd.srv.habr.com\/iframe\/602a40a5b4c396d242e09732\"><\/iframe><\/div>\n<\/div><\/div>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/tq\/g5\/5q\/tqg55qu1zgt5t-foqfnz7n39keu.jpeg\"><\/p>\n<p>  \u041e \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438. \u041c\u044b \u0437\u0430\u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043e\u0432\u0430\u043b\u0438\u0441\u044c \u0438 \u0443\u0432\u0438\u0434\u0435\u043b\u0438, \u0447\u0442\u043e \u0431\u0435\u043d\u0447\u043c\u0430\u0440\u043a\u0438 \u043d\u0435\u043b\u044c\u0437\u044f \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043d\u0430 iOS. \u0422\u0430\u043c \u0431\u044b\u043b\u0438 \u0431\u0435\u043d\u0447\u043c\u0430\u0440\u043a\u0438 \u0434\u043b\u044f JVM, \u043d\u043e \u043d\u0430 iOS \u043d\u0430\u043c \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u0441\u0430\u043c\u0438\u043c \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0441\u044d\u043c\u043f\u043b \u0438 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043d\u0430 iOS \u043b\u043e\u0433\u0438\u043a\u0443, \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u0443\u044e \u0442\u043e\u0439, \u0447\u0442\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0432 JVM-\u0431\u0435\u043d\u0447\u043c\u0430\u0440\u043a\u0430\u0445. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u043f\u043e\u043d\u0430\u0447\u0430\u043b\u0443 \u043d\u0435 \u0432\u0441\u0435 \u0431\u044b\u043b\u043e \u0433\u043b\u0430\u0434\u043a\u043e.<\/p>\n<p>  \u041c\u044b \u043d\u0430\u0448\u043b\u0438 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0443, \u043d\u0430\u043f\u0438\u0441\u0430\u043b\u0438 \u043e \u043d\u0435\u0439 \u0440\u0435\u0431\u044f\u0442\u0430\u043c, \u0442\u043e \u0435\u0441\u0442\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0438\u043b\u0438 \u0438 \u0441\u043a\u0430\u0437\u0430\u043b\u0438: \u00ab\u0423 \u0432\u0430\u0441 \u0435\u0441\u0442\u044c \u0430\u043d\u043e\u043c\u0430\u043b\u0438\u0438 \u0441 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c\u044e\u00bb. \u0420\u0435\u0431\u044f\u0442\u0430 \u0431\u0443\u043a\u0432\u0430\u043b\u044c\u043d\u043e \u0437\u0430 \u043f\u0430\u0440\u0443 \u0434\u043d\u0435\u0439 \u0432\u044b\u043a\u0430\u0442\u0438\u043b\u0438 \u0444\u0438\u043a\u0441, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0443\u0436\u0435 \u044d\u0442\u0430 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u0431\u044b\u043b\u0430 \u0440\u0435\u0448\u0435\u043d\u0430. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043c\u044b \u0442\u043e\u0436\u0435 \u043a\u043e\u0441\u0432\u0435\u043d\u043d\u043e \u043f\u043e\u0443\u0447\u0430\u0441\u0442\u0432\u043e\u0432\u0430\u043b\u0438 \u0432 \u0443\u043b\u0443\u0447\u0448\u0435\u043d\u0438\u0438 Reaktive.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/is\/bq\/b_\/isbqb_ptihvpkjbmm3tqx7m3r4a.jpeg\"><\/p>\n<p>  \u041a\u0430\u043a\u043e\u0432 \u0438\u0442\u043e\u0433? \u041d\u0430\u043c \u043f\u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u044d\u0442\u043e \u043e\u0447\u0435\u043d\u044c \u043f\u0440\u043e\u0441\u0442\u0430\u044f \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044f, \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u0438\u043c\u043f\u043e\u0440\u0442\u044b, \u0438 \u043d\u0430 Android \u044d\u0442\u043e \u0432\u0441\u0435 \u0437\u0430\u0432\u043e\u0434\u0438\u0442\u0441\u044f. \u041d\u043e \u0434\u043b\u044f iOS \u043d\u0430\u0434\u043e \u0430\u043a\u043a\u0443\u0440\u0430\u0442\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c, \u043d\u0435 \u0437\u0430\u0445\u0432\u0430\u0442\u044b\u0432\u0430\u0435\u0442\u0435 \u043b\u0438 \u0433\u0434\u0435-\u0442\u043e \u043c\u0443\u0442\u0430\u0431\u0435\u043b\u044c\u043d\u044b\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u044b. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0441\u0435\u0439\u0447\u0430\u0441 \u043c\u044b \u0448\u0438\u0440\u043e\u043a\u043e \u043d\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c Reaktive, \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u043b\u0438 \u0435\u0433\u043e \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e \u043d\u0430 \u043f\u0430\u0443\u0437\u0443 \u0438 \u0441\u0434\u0435\u043b\u0430\u043b\u0438 \u0441\u0442\u0430\u0432\u043a\u0443 \u043d\u0430 flow, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0432\u0441\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u043e\u0442 JetBrains \u0438\u0437\u043d\u0430\u0447\u0430\u043b\u044c\u043d\u043e \u0438\u0434\u0443\u0442 \u0441 suspend-\u0444\u0443\u043d\u043a\u0446\u0438\u044f\u043c\u0438 \u043b\u0438\u0431\u043e \u0441 flow \u0432 API \u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0441\u044f, \u0447\u0442\u043e \u043d\u0443\u0436\u043d\u0430 \u0435\u0449\u0435 \u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0430\u0446\u0438\u044f \u0432 Reaktive Observable, \u0430 \u043f\u043e\u0442\u043e\u043c \u0435\u0449\u0435 \u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0430\u0446\u0438\u044f \u0432 \u043d\u0435\u0447\u0442\u043e \u043f\u043e\u0434\u0445\u043e\u0434\u044f\u0449\u0435\u0435 \u0434\u043b\u044f \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u044b (iOS\/Android). \u041f\u043e\u043a\u0430 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c flow, \u043d\u043e \u0436\u0434\u0435\u043c, \u043a\u043e\u0433\u0434\u0430 \u043f\u043e\u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u043c\u043e\u0434\u0435\u043b\u044c \u043f\u0430\u043c\u044f\u0442\u0438 \u0432 Kotlin\/Native \u0438 \u0447\u0430\u0441\u0442\u044c \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u0439, \u0441 \u043a\u043e\u0442\u043e\u0440\u044b\u043c\u0438 \u043c\u044b \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u043b\u0438\u0441\u044c \u0432 Reaktive, \u0443\u0439\u0434\u0435\u0442.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/3s\/dz\/-n\/3sdz-nq7pqixp-wt86mt1qpmp0u.jpeg\"><\/p>\n<p>  \u041a\u0430\u043a\u0438\u0435 \u0438\u0442\u043e\u0433\u0438 \u043f\u043e \u043c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043a\u0435? \u0410\u0441\u0438\u043d\u0445\u0440\u043e\u043d\u043d\u043e\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u0443\u0436\u0435 \u0441\u0435\u0439\u0447\u0430\u0441 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e, \u043e\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u0430 \u043c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043d\u043e\u0441\u0442\u044c \u043d\u0430 iOS \u2014 \u0432 native-mt-\u0432\u0435\u0442\u043a\u0435. \u0415\u0441\u043b\u0438 \u043d\u0435 \u0431\u043e\u0438\u0442\u0435\u0441\u044c \u0433\u0440\u0430\u043d\u0438\u0447\u043d\u044b\u0445 \u0441\u043b\u0443\u0447\u0430\u0435\u0432 \u0438\u043b\u0438 \u0443\u0442\u0435\u0447\u0435\u043a, \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c. \u0414\u043b\u044f \u043f\u0440\u043e\u0441\u0442\u044b\u0445 \u0437\u0430\u0434\u0430\u0447 \u043f\u043e\u0434\u0445\u043e\u0434\u044f\u0442 \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u044b. \u0415\u0441\u043b\u0438 \u0445\u043e\u0447\u0435\u0442\u0441\u044f \u0431\u043e\u043b\u0435\u0435 \u0441\u043b\u043e\u0436\u043d\u043e\u0439 \u043b\u043e\u0433\u0438\u043a\u0438 \u0438\u043b\u0438 \u0432\u044b \u043f\u0438\u0448\u0435\u0442\u0435 \u0441 \u043d\u0443\u043b\u044f, \u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c flow. \u0414\u043b\u044f \u043c\u0438\u0433\u0440\u0430\u0446\u0438\u0438 \u0431\u043e\u043b\u044c\u0448\u0438\u0445 \u043e\u0431\u044a\u0435\u043c\u043e\u0432 \u043a\u043e\u0434\u0430 \u0441 Android \u043e\u0447\u0435\u043d\u044c \u0445\u043e\u0440\u043e\u0448\u043e \u0437\u0430\u0445\u043e\u0434\u0438\u0442 Reaktive. \u0415\u0441\u043b\u0438 \u0432\u0430\u043c \u043d\u0443\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u043f\u0438\u0441\u0430\u0442\u044c \u043a\u0443\u0447\u0443 \u043b\u043e\u0433\u0438\u043a\u0438 \u0441 RxJava, \u043c\u043e\u0436\u043d\u043e \u043b\u0435\u0433\u043a\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0435\u0435 \u0432 common-\u0447\u0430\u0441\u0442\u0438.<\/p>\n<h2>\u0421\u0435\u0442\u044c<\/h2>\n<p>  \u0412 \u0441\u0435\u0442\u0438 \u043d\u0430\u043c \u043d\u0443\u0436\u043d\u043e \u0437\u0430\u043f\u0440\u0430\u0448\u0438\u0432\u0430\u0442\u044c \u043e\u0431\u044a\u0435\u043a\u0442\u044b, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u0438\u0445 \u043d\u0430 \u043a\u0430\u0440\u0442\u0435. \u041a\u043e\u0433\u0434\u0430 \u043c\u044b \u043f\u0440\u043e\u0435\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043b\u0438 \u0444\u0438\u0447\u0443, \u0442\u043e \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u043b\u0438 \u0434\u0432\u0430 \u043f\u043e\u0434\u0445\u043e\u0434\u0430.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/v-\/_o\/bt\/v-_obt4mzlkm4cis6vkpt1-jj8u.jpeg\"><\/p>\n<p>  \u041f\u0435\u0440\u0432\u044b\u0439 \u043f\u043e\u0434\u0445\u043e\u0434 \u2014 \u0441\u0434\u0435\u043b\u0430\u0442\u044c expect-\u043a\u043b\u0430\u0441\u0441, \u0443 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e actual-\u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0431\u0443\u0434\u0443\u0442 \u0440\u0430\u0437\u043d\u044b\u0435 \u043d\u0430 \u043a\u0430\u0436\u0434\u043e\u0439 \u0438\u0437 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c: \u043f\u043e\u0434 \u043a\u0430\u043f\u043e\u0442\u043e\u043c \u043d\u0430 Android \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043a\u0430\u043a\u043e\u0439-\u043d\u0438\u0431\u0443\u0434\u044c OkHttp, \u0430 \u043d\u0430 iOS \u2014 \u0447\u0442\u043e-\u043d\u0438\u0431\u0443\u0434\u044c \u0438\u0437 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0445 \u0441\u0440\u0435\u0434\u0441\u0442\u0432. \u041e\u0434\u043d\u0430\u043a\u043e \u0441\u0442\u0430\u043b\u043e \u043f\u043e\u043d\u044f\u0442\u043d\u043e, \u0447\u0442\u043e \u043b\u043e\u0433\u0438\u043a\u0430 \u043d\u0430 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430\u0445 \u0443 \u043d\u0430\u0441 \u043c\u043e\u0436\u0435\u0442 \u0440\u0430\u0437\u044a\u0435\u0445\u0430\u0442\u044c\u0441\u044f \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043c\u0430\u043a\u0441\u0438\u043c\u0443\u043c \u043a\u043e\u0434\u0430 \u044f\u0432\u043d\u043e \u043d\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u0441\u044f.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/b_\/yy\/bh\/b_yybhmsmwo-n-n9mqsctx56fxe.jpeg\"><\/p>\n<p>  \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043c\u044b \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u043b\u0438 \u043d\u0430 ktor. \u042d\u0442\u043e \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u0435\u0434\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439 HTTP-\u043a\u043b\u0438\u0435\u043d\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u0432 Kotlin Multiplatform.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/xa\/nk\/ty\/xanktypurvmgbr_wti1wpdt1cl8.jpeg\"><\/p>\n<p>  \u0417\u0430\u0432\u0435\u043b\u0441\u044f \u043e\u043d \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0431\u044b\u0441\u0442\u0440\u043e, \u043b\u0435\u0433\u043a\u043e, \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043c\u044b \u043f\u0440\u043e\u043a\u0438\u043d\u0443\u043b\u0438 OkHttp-\u043a\u043b\u0438\u0435\u043d\u0442 \u0441 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u044b. \u041f\u043e\u043b\u0443\u0447\u0438\u043b\u0441\u044f \u043a\u043b\u0438\u0435\u043d\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0443\u0436\u0435 \u043f\u0440\u0435\u0434\u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043d \u0432 Android-\u0447\u0430\u0441\u0442\u0438, \u0443 \u043d\u0435\u0433\u043e \u0435\u0441\u0442\u044c \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0438\u043d\u0433\u0438, \u0438\u043d\u0442\u0435\u0440\u0446\u0435\u043f\u0442\u043e\u0440\u044b, \u043d\u0430 \u043d\u0435\u0433\u043e \u043d\u0430\u0432\u0435\u0448\u0430\u043d\u0430 \u043a\u0443\u0447\u0430 \u043b\u043e\u0433\u0438\u043a\u0438, \u0435\u0433\u043e \u0431\u0435\u0437 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439 \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u0432 \u043c\u0443\u043b\u044c\u0442\u0438\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0443. \u041d\u043e \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043c\u044b \u0437\u0430\u043c\u0435\u0442\u0438\u043b\u0438 \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u044c: \u043f\u0440\u0438 \u0440\u0435\u0434\u0438\u0440\u0435\u043a\u0442\u0430\u0445 \u0438\u043d\u0442\u0435\u0440\u0446\u0435\u043f\u0442\u043e\u0440\u044b \u0441\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u043b\u0438 \u0434\u0432\u0430\u0436\u0434\u044b. \u041f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u0432\u044b\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0440\u0435\u0434\u0438\u0440\u0435\u043a\u0442\u044b \u0432 HTTP-\u043a\u043b\u0438\u0435\u043d\u0442\u0435 ktor \u0438 \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0438\u0445 \u0432 OkHttp. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u0438\u043d\u0442\u0435\u0440\u0446\u0435\u043f\u0442\u043e\u0440\u044b \u0441\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u043b\u0438 \u043f\u043e \u043e\u0434\u043d\u043e\u043c\u0443 \u0440\u0430\u0437\u0443.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/sp\/hq\/im\/sphqimj_d-vgoalazedkpiofeog.jpeg\"><\/p>\n<p>  \u0427\u0442\u043e \u0435\u0449\u0435 \u043c\u044b \u0437\u0430\u043c\u0435\u0442\u0438\u043b\u0438, \u043a\u043e\u0433\u0434\u0430 \u043f\u043e\u043f\u044b\u0442\u0430\u043b\u0438\u0441\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c ktor? \u041f\u0435\u0440\u0432\u043e\u0435: \u0432 \u0442\u043e\u0442 \u043c\u043e\u043c\u0435\u043d\u0442 \u043d\u0435\u043b\u044c\u0437\u044f \u0431\u044b\u043b\u043e \u0435\u0433\u043e \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043d\u0430 \u0434\u0440\u0443\u0433\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435, \u043a\u0440\u043e\u043c\u0435 \u0433\u043b\u0430\u0432\u043d\u043e\u0433\u043e. \u0421\u0430\u043c \u0437\u0430\u043f\u0440\u043e\u0441, \u043a\u043e\u043d\u0435\u0447\u043d\u043e, \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u043b \u0432 \u0434\u0440\u0443\u0433\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435 \u2014 \u0432 \u0444\u043e\u043d\u0435, \u043d\u043e \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u0432\u0441\u0435 \u043a\u043e\u043b\u043b\u0431\u044d\u043a\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u043b\u0438\u0441\u044c \u043d\u0430 \u0433\u043b\u0430\u0432\u043d\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435. \u0422\u043e \u0435\u0441\u0442\u044c \u0434\u0435\u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f JSON \u0442\u0430\u043a\u0436\u0435 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u043b\u0430 \u0432 \u0433\u043b\u0430\u0432\u043d\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/ne\/4v\/b9\/ne4vb9siv6ekgb3weqevwjwfytw.jpeg\"><\/p>\n<p>  \u041d\u0430\u043c \u043e\u0447\u0435\u043d\u044c \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u044d\u0442\u043e \u043f\u043e\u043c\u0435\u043d\u044f\u0442\u044c, \u0438 \u043c\u044b \u0441\u0434\u0435\u043b\u0430\u043b\u0438 \u044d\u0442\u043e \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043f\u043e\u0434\u043c\u0435\u043d\u044b \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0439 \u0441\u0442\u0440\u0430\u0442\u0435\u0433\u0438\u0438 \u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 JsonFeature \u043d\u0430 \u0441\u0432\u043e\u044e \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u2014 BackgroundJsonFeature.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/zf\/7w\/yu\/zf7wyuq3m_n5gds7tgkwjozmk9g.jpeg\"><\/p>\n<p>  \u041c\u044b \u043f\u0440\u043e\u0441\u0442\u043e \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043b\u0438 \u043a\u043e\u0434 \u0438\u0437 JsonFeature \u0438 \u043f\u043e\u0434\u043c\u0435\u043d\u0438\u043b\u0438 \u0432 \u043d\u0435\u043c \u043e\u0434\u043d\u0443 \u0441\u0442\u0440\u043e\u0447\u043a\u0443: \u0441\u0434\u0435\u043b\u0430\u043b\u0438 \u0434\u0435\u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u0432 \u0444\u043e\u043d\u0435, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u044e coroutineOnBackground().<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/05\/l1\/rd\/05l1rdksp-i5mf_q4g0x8pismz4.jpeg\"><\/p>\n<p>  \u0421 \u043a\u0430\u043a\u0438\u043c\u0438 \u0435\u0449\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430\u043c\u0438 \u043c\u044b \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u043b\u0438\u0441\u044c? \u0412\u0441\u0435-\u0442\u0430\u043a\u0438 \u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043d\u0430 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430\u0445 \u043f\u043e-\u0440\u0430\u0437\u043d\u043e\u043c\u0443. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043d\u0430 Android \u0432\u0441\u0451 \u043e\u043a\u0435\u0439, \u043d\u0430 iOS \u0432\u043e\u0437\u043d\u0438\u043a\u0430\u0435\u0442 \u043e\u0448\u0438\u0431\u043a\u0430. \u042d\u0442\u0438 \u043e\u0448\u0438\u0431\u043a\u0438 \u0447\u0438\u043d\u044f\u0442\u0441\u044f \u0438, \u043d\u0430\u0434\u043e \u043f\u0440\u0438\u0437\u043d\u0430\u0442\u044c, \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0431\u044b\u0441\u0442\u0440\u043e, \u043d\u043e \u043d\u0443\u0436\u043d\u043e \u0432\u0441\u0435\u0433\u0434\u0430 \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0442\u044c \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u0435 \u043d\u0430 \u043e\u0431\u0435\u0438\u0445 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430\u0445. \u0417\u0430\u043c\u0435\u0442\u0438\u043b\u0438, \u0447\u0442\u043e \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f inline-\u043a\u043b\u0430\u0441\u0441\u043e\u0432. Inline-\u043a\u043b\u0430\u0441\u0441\u044b \u2014 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u0430\u044f \u0448\u0442\u0443\u043a\u0430, \u043d\u043e \u0442\u0435\u043c \u043d\u0435 \u043c\u0435\u043d\u0435\u0435. \u0421\u0442\u043e\u043b\u043a\u043d\u0443\u043b\u0438\u0441\u044c \u0441 \u0442\u0435\u043c, \u0447\u0442\u043e \u043d\u0435\u043b\u044c\u0437\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432\u044b\u0447\u0438\u0441\u043b\u044f\u0435\u043c\u0443\u044e \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0443\u044e \u043d\u0430 iOS: \u0435\u0441\u043b\u0438 \u0432\u044b \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u0435 val, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b\u0447\u0438\u0441\u043b\u044f\u0435\u0442\u0441\u044f, \u0442\u043e \u043d\u0430 Android \u0443 \u0432\u0430\u0441 \u0432\u0441\u0435 \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u0443\u0435\u0442\u0441\u044f, \u0430 \u043d\u0430 iOS \u0432\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u0435 \u043e\u0448\u0438\u0431\u043a\u0443 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0446\u0438\u0438.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/qw\/l8\/vm\/qwl8vm7rjtmiyfctmc15yyfzhbs.jpeg\"><\/p>\n<p>  \u0420\u0435\u0437\u044e\u043c\u0435 \u2014 \u0440\u0435\u0448\u0435\u043d\u0438\u0435 ktor \u0438 kotlinx \u043f\u043e\u0434\u043e\u0439\u0434\u0435\u0442, \u043d\u0430\u0432\u0435\u0440\u043d\u043e\u0435, \u0434\u043b\u044f 99% \u043a\u0435\u0439\u0441\u043e\u0432, \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043e\u0441\u0442\u0430\u0432\u0448\u0438\u0439\u0441\u044f 1% \u2014 \u044d\u0442\u043e \u0442\u0435 \u0441\u043b\u0443\u0447\u0430\u0438, \u043a\u043e\u0433\u0434\u0430 \u0443 \u0432\u0430\u0441 \u043e\u0447\u0435\u043d\u044c \u043a\u0430\u0441\u0442\u043e\u043c\u043d\u044b\u0439, \u0441\u0432\u043e\u0439 \u0441\u0435\u0442\u0435\u0432\u043e\u0439 \u0441\u0442\u0435\u043a. \u0422\u043e\u0433\u0434\u0430 \u0432\u0430\u043c \u043f\u043e\u0434\u043e\u0439\u0434\u0435\u0442 \u043f\u043e\u0434\u0445\u043e\u0434 \u0441 expect-\u043a\u043b\u0430\u0441\u0441\u043e\u043c \u0438 actual-\u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0435\u0439 \u043d\u0430 \u043e\u0431\u0435\u0438\u0445 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430\u0445. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0443 ktor- \u0438 kotlinx-\u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0445\u043e\u0440\u043e\u0448\u0430\u044f \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430, \u0438 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u0447\u0438\u043d\u044f\u0442\u0441\u044f \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0431\u044b\u0441\u0442\u0440\u043e. \u041d\u0435 \u0441\u0442\u043e\u0438\u0442 \u0437\u0430\u0431\u044b\u0432\u0430\u0442\u044c, \u0447\u0442\u043e \u043d\u0443\u0436\u043d\u043e \u043f\u043e\u0442\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u0440\u0435\u043c\u044f, \u0435\u0441\u043b\u0438 \u0432\u044b \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u0442\u0435 \u0441 \u0434\u0440\u0443\u0433\u043e\u0433\u043e \u0441\u0442\u0435\u043a\u0430. \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u043d\u0430 Android \u0431\u044b\u043b \u043e\u0434\u0438\u043d \u0441\u0435\u0442\u0435\u0432\u043e\u0439 \u0441\u0442\u0435\u043a, \u0434\u043b\u044f \u043d\u0435\u0433\u043e \u0431\u044b\u043b\u0430 \u043a\u0443\u0447\u0430 \u043e\u0431\u0432\u044f\u0437\u043e\u043a, \u0438\u043d\u0442\u0435\u0440\u0446\u0435\u043f\u0442\u043e\u0440\u043e\u0432 \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435, \u0442\u043e \u0441\u0435\u0439\u0447\u0430\u0441 \u0434\u043b\u044f common-\u0447\u0430\u0441\u0442\u0438 \u043d\u0443\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0432\u0441\u0435 \u0442\u043e \u0436\u0435 \u0441\u0430\u043c\u043e\u0435, \u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043b\u044f ktor.<\/p>\n<h2>\u041a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435<\/h2>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/n8\/eq\/wm\/n8eqwmx2nuzpo_ufjjn9wu0ndfo.jpeg\"><\/p>\n<p>  \u0414\u043b\u044f \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0435\u0441\u0442\u044c \u043c\u043d\u043e\u0433\u043e \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a, \u043e\u043d\u0438 \u043f\u0440\u0435\u0434\u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u044b \u0434\u043b\u044f \u0440\u0430\u0437\u043d\u044b\u0445 \u043a\u0435\u0439\u0441\u043e\u0432. \u0415\u0441\u043b\u0438 SQL-\u0431\u0430\u0437\u0430, SQL Delight. \u041c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0434\u0430\u0436\u0435 HTTP-\u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0432 ktor, \u0435\u0441\u043b\u0438 \u0432\u0430\u043c \u043d\u0435 \u043d\u0443\u0436\u043d\u043e, \u0447\u0442\u043e\u0431\u044b \u043a\u044d\u0448 \u043f\u0435\u0440\u0435\u0436\u0438\u0432\u0430\u043b \u043f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u043a.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/eo\/my\/fc\/eomyfc32xkumfxwp1yqfqwcmnog.jpeg\"><\/p>\n<p>  \u041c\u044b \u043d\u0430\u043f\u0438\u0441\u0430\u043b\u0438 \u0441\u0432\u043e\u0439 \u043a\u044d\u0448, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0438 \u0437\u0430\u043f\u0438\u0441\u044c \u0438 \u0447\u0442\u0435\u043d\u0438\u0435 \u0438\u0437 \u0444\u0430\u0439\u043b\u043e\u0432. \u041a\u0430\u043a \u043c\u044b \u044d\u0442\u043e \u0441\u0434\u0435\u043b\u0430\u043b\u0438? \u0412\u0441\u044e \u043b\u043e\u0433\u0438\u043a\u0443, \u043e\u0442\u0432\u0435\u0447\u0430\u044e\u0449\u0443\u044e \u0437\u0430 \u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u0438 \u0434\u0435\u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432, \u043c\u044b \u043e\u0441\u0442\u0430\u0432\u0438\u043b\u0438 \u0432 common-\u0447\u0430\u0441\u0442\u0438 \u0432 \u043a\u043b\u0430\u0441\u0441\u0435 EventsCacheService. \u0422\u0430\u043c \u0436\u0435 \u043e\u043a\u0430\u0437\u0430\u043b\u0430\u0441\u044c \u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u043d\u0430 \u0442\u043e, \u043f\u0440\u043e\u0442\u0443\u0445 \u043a\u044d\u0448 \u0438\u043b\u0438 \u043d\u0435\u0442. EventsCacheService \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u0432 \u0441\u0435\u0431\u044f \u043a\u043b\u0430\u0441\u0441 PersistentCache \u2014 \u044d\u0442\u043e \u043a\u0430\u043a \u0440\u0430\u0437 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442 \u0441 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u044b. \u0418\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432\u0441\u0435\u0433\u043e \u043b\u0438\u0448\u044c \u0442\u0440\u0438 \u043c\u0435\u0442\u043e\u0434\u0430 \u2014 \u0437\u0430\u043f\u0438\u0448\u0438, \u043f\u0440\u043e\u0447\u0438\u0442\u0430\u0439 \u0438 \u0443\u0434\u0430\u043b\u0438 \u0444\u0430\u0439\u043b\u0438\u043a. EventsCacheService \u0438\u0437 common-\u0447\u0430\u0441\u0442\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u044d\u0442\u0438 \u043c\u0435\u0442\u043e\u0434\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u044b \u043d\u0430 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430\u0445 \u043f\u043e-\u0440\u0430\u0437\u043d\u043e\u043c\u0443. \u0422\u043e \u0435\u0441\u0442\u044c \u043d\u0430 iOS \u044d\u0442\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0435 \u0437\u0430\u043f\u0438\u0441\u044c-\u0447\u0442\u0435\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u043e\u0432, \u0430 \u043d\u0430 Android \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 OkIO \u043f\u043e\u0434 \u043a\u0430\u043f\u043e\u0442\u043e\u043c.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/py\/rf\/jk\/pyrfjklzr6-rb1sh4hqhrdhjmsk.jpeg\"><\/p>\n<p>  \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u0443 \u043d\u0430\u0441 \u0437\u0430\u0432\u0435\u043b\u0441\u044f \u0444\u0430\u0439\u043b\u043e\u0432\u044b\u0439 \u043a\u044d\u0448, \u043d\u043e \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u043d\u0435 \u0445\u043e\u0434\u0438\u0442\u044c \u0437\u0430 \u0444\u0430\u0439\u043b\u0430\u043c\u0438 \u043a\u0430\u0436\u0434\u044b\u0439 \u0440\u0430\u0437, \u0430 \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0435 \u0437\u0430\u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0443\u0436\u0435 \u0431\u044b\u043b\u043e \u0432 \u043f\u0430\u043c\u044f\u0442\u0438. \u0417\u0434\u0435\u0441\u044c \u043d\u0435 \u043e\u0431\u043e\u0448\u043b\u043e\u0441\u044c \u0431\u0435\u0437 \u0442\u043e\u043d\u043a\u043e\u0441\u0442\u0435\u0439, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0441\u0432\u044f\u0437\u0430\u043d\u044b \u0441 Kotlin\/Native, \u0442\u043e \u0435\u0441\u0442\u044c \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0435 \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u2014 \u044d\u0442\u043e AtomicReference, \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u0437\u0430 \u0444\u0430\u0439\u043b\u0438\u043a\u043e\u043c \u043c\u044b \u0442\u043e\u0436\u0435 \u0445\u043e\u0434\u0438\u043c \u0432 \u0444\u043e\u043d\u0435 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e coroutineOnBackground(). \u0418 \u043f\u0435\u0440\u0435\u0434 \u0442\u0435\u043c, \u043a\u0430\u043a \u043e\u0431\u043d\u043e\u0432\u0438\u0442\u044c \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0435 \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435, \u0435\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u0437\u0430\u043c\u043e\u0440\u043e\u0437\u0438\u0442\u044c, \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u0432\u043e\u0437\u043d\u0438\u043a\u043b\u043e \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043d\u0430 iOS.<\/p>\n<h2>\u041f\u043e\u0434\u044b\u0442\u043e\u0436\u0438\u043c<\/h2>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/6x\/kg\/my\/6xkgmybab6qpoq2szdw4t0dweny.jpeg\"><\/p>\n<p>  \u041f\u043e\u0434\u0432\u0435\u0434\u0435\u043c \u0438\u0442\u043e\u0433\u0438. \u041c\u044b \u0441\u0435\u0433\u043e\u0434\u043d\u044f \u043f\u043e\u0433\u043e\u0432\u043e\u0440\u0438\u043b\u0438 \u043e \u0442\u043e\u043c, \u043a\u0430\u043a \u0441\u0432\u044f\u0437\u0430\u0442\u044c \u0441\u0435\u0440\u0432\u0438\u0441, \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u0439 \u043d\u0430 Kotlin Multiplatform, \u0441 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435\u043c, \u043f\u0440\u0438\u0447\u0435\u043c \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u044d\u0442\u043e \u0432 \u0440\u0435\u0430\u043a\u0442\u0438\u0432\u043d\u043e\u043c \u0441\u0442\u0438\u043b\u0435, \u043f\u043e\u0433\u043e\u0432\u043e\u0440\u0438\u043b\u0438 \u043f\u0440\u043e \u0444\u043e\u043d\u043e\u0432\u043e\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435, \u043f\u0440\u043e \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u0438 Kotlin\/Native, \u043f\u0440\u043e \u0441\u0435\u0442\u044c \u0438 \u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u0432 common-\u043a\u043e\u0434\u0435, \u043e\u0431\u0441\u0443\u0434\u0438\u043b\u0438 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u044b \u0432\u0441\u0442\u0440\u0435\u0442\u0438\u043b\u0438, \u0438 \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/8k\/ao\/9b\/8kao9b6s_tvw-btvejyavz0db78.jpeg\"><\/p>\n<p>  \u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u0432\u0435\u0440\u043d\u0435\u043c\u0441\u044f \u043a \u0446\u0435\u043b\u044f\u043c, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u044b \u0441\u0435\u0431\u0435 \u0441\u0442\u0430\u0432\u0438\u043b\u0438. \u0421\u0430\u043c\u0430\u044f \u0431\u043e\u043b\u044c\u0448\u0430\u044f \u0438 \u0430\u043c\u0431\u0438\u0446\u0438\u043e\u0437\u043d\u0430\u044f \u0446\u0435\u043b\u044c \u2014 \u043f\u0435\u0440\u0435\u043d\u0435\u0441\u0442\u0438 \u043a\u043e\u0434 \u0438\u0437 Android \u0432 common-\u0447\u0430\u0441\u0442\u044c. \u0417\u0434\u0435\u0441\u044c \u043c\u044b \u043f\u043e\u043d\u044f\u043b\u0438, \u0447\u0442\u043e \u0437\u0434\u0435\u0441\u044c \u043d\u0435 \u043e\u0431\u043e\u0439\u0434\u0435\u0442\u0441\u044f \u0431\u0435\u0437 \u0440\u0435\u0444\u0430\u043a\u0442\u043e\u0440\u0438\u043d\u0433\u0430: \u043b\u0438\u0431\u043e \u0441\u0435\u0440\u044c\u0435\u0437\u043d\u043e\u0433\u043e, \u043a\u0430\u043a \u0432 \u0441\u043b\u0443\u0447\u0430\u0435 \u0441 flow, \u043b\u0438\u0431\u043e \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0433\u043e, \u043a\u0430\u043a \u0432 \u0441\u043b\u0443\u0447\u0430\u0435 \u0441 Reaktive.<\/p>\n<p>  \u0424\u0438\u0447\u0438 \u0441\u0442\u0430\u043b\u0438 \u043f\u0438\u043b\u0438\u0442\u044c\u0441\u044f \u0431\u044b\u0441\u0442\u0440\u0435\u0435, \u0437\u0430 \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435\u043c \u0441\u0430\u043c\u043e\u0439 \u043f\u0435\u0440\u0432\u043e\u0439. \u041a\u043e\u0433\u0434\u0430 \u043c\u044b \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430\u0447\u0438\u043d\u0430\u043b\u0438 \u043f\u0438\u043b\u0438\u0442\u044c \u044d\u0442\u0443 \u0444\u0438\u0447\u0443, \u043e\u043d\u0430 \u0431\u044b\u043b\u0430 \u043f\u0435\u0440\u0432\u043e\u0439, \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u043c\u043d\u043e\u0433\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u043f\u043e\u0442\u0440\u0430\u0442\u0438\u0442\u044c \u0438\u043c\u0435\u043d\u043d\u043e \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e\u0431\u044b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0438\u043d\u0444\u0440\u0430\u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0443, \u0432\u0441\u043f\u043e\u043c\u043e\u0433\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u043a\u043b\u0430\u0441\u0441\u044b \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435, \u043f\u043e\u043f\u0443\u0442\u043d\u043e \u0440\u0430\u0437\u043e\u0431\u0440\u0430\u0432\u0448\u0438\u0441\u044c \u0432 \u043d\u043e\u0432\u043e\u043c \u0441\u0442\u0435\u043a\u0435. \u0421\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0444\u0438\u0447\u0438 \u0443\u0436\u0435 \u0448\u043b\u0438 \u0431\u044b\u0441\u0442\u0440\u0435\u0435. <\/p>\n<p>  \u0422\u0430\u043a\u0436\u0435 \u0432\u0441\u0442\u0440\u0435\u0442\u0438\u043b\u0438 \u0431\u043e\u043b\u044c\u0448\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u043d\u0435\u043e\u0436\u0438\u0434\u0430\u043d\u043d\u044b\u0445 \u043f\u0440\u043e\u0431\u043b\u0435\u043c. \u041a\u0430\u043a \u044f \u0441\u043a\u0430\u0437\u0430\u043b, \u0441\u0442\u0435\u043a \u043d\u043e\u0432\u044b\u0439, \u0434\u0430\u0436\u0435 \u043d\u0430 \u0443\u0441\u0442\u043e\u044f\u0432\u0448\u0438\u0435\u0441\u044f \u0448\u0442\u0443\u043a\u0438 \u043d\u0443\u0436\u043d\u043e \u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u043f\u043e-\u043d\u043e\u0432\u043e\u043c\u0443. \u041a\u043e\u043d\u0435\u0447\u043d\u043e, \u044d\u0442\u043e \u0431\u044b\u043b\u043e \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e: \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c \u0440\u0430\u0437\u043e\u0431\u0440\u0430\u0442\u044c\u0441\u044f \u0432 \u043d\u043e\u0432\u043e\u0439 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u0438 \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0435\u0435 \u0432 \u043f\u0440\u043e\u0434\u0435.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/k5\/ke\/l0\/k5kel088t2fkid0rg0tvf3yjfew.jpeg\"><br \/>  <b><sup><sub><a href=\"http:\/\/tiny.cc\/twlzsz\">\u0421\u0441\u044b\u043b\u043a\u0430 \u0441\u043e \u0441\u043b\u0430\u0439\u0434\u0430<\/a><\/sub><\/sup><\/b><\/p>\n<p>  \u041d\u0430\u043f\u043e\u0441\u043b\u0435\u0434\u043e\u043a \u0445\u043e\u0447\u0443 \u0441\u043a\u0430\u0437\u0430\u0442\u044c, \u0447\u0442\u043e Kotlin Multiplatform \u043e\u0447\u0435\u043d\u044c \u0431\u044b\u0441\u0442\u0440\u043e \u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f. \u0411\u0443\u043a\u0432\u0430\u043b\u044c\u043d\u043e \u043f\u0430\u0440\u0443 \u043c\u0435\u0441\u044f\u0446\u0435\u0432 \u043d\u0430\u0437\u0430\u0434 \u0441\u0431\u043e\u0440\u043a\u0430 \u0438 \u043e\u0442\u043b\u0430\u0434\u043a\u0430 iOS-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0432\u043d\u0443\u0442\u0440\u0438 Android Studio \u0431\u044b\u043b\u0430 \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u0430, \u0430 \u0441\u0435\u0439\u0447\u0430\u0441 \u0443\u0436\u0435 \u043c\u043e\u0436\u043d\u043e \u0435\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c. \u0422\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0442\u044c \u043c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043d\u044b\u0435 \u043a\u043e\u0440\u0443\u0442\u0438\u043d\u044b \u0432 iOS, \u0435\u0441\u043b\u0438 \u0432\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0435 native-mt-\u0432\u0435\u0442\u043a\u0443 \u0432\u043c\u0435\u0441\u0442\u043e \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u043e\u0439. \u0420\u0435\u0431\u044f\u0442\u0430 \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0442 \u043d\u0430\u0434 \u043d\u043e\u0432\u043e\u0439 \u043c\u043e\u0434\u0435\u043b\u044c\u044e \u043f\u0430\u043c\u044f\u0442\u0438, \u043e\u043d\u0430 \u0442\u043e\u0436\u0435 \u0441\u043d\u0438\u043c\u0435\u0442 \u0447\u0430\u0441\u0442\u044c \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u0439 Kotlin\/Native. \u041f\u043e <a href=\"http:\/\/tiny.cc\/twlzsz\">\u0441\u0441\u044b\u043b\u043a\u0435<\/a> \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u043f\u043b\u0430\u043d\u044b JetBrains \u043f\u043e \u0440\u0430\u0437\u0432\u0438\u0442\u0438\u044e Kotlin Multiplatform.<\/p>\n<p>  \u041d\u0430 \u044d\u0442\u043e\u043c \u0432\u0441\u0451, \u0441\u043f\u0430\u0441\u0438\u0431\u043e \u0432\u0430\u043c \u0437\u0430 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 Kotlin Multiplatform \u2014 \u044d\u0442\u043e \u043e\u0442\u043b\u0438\u0447\u043d\u0430\u044f \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u044f.<\/p><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/company\/yandex\/blog\/542454\/\"> https:\/\/habr.com\/ru\/company\/yandex\/blog\/542454\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\">\u041f\u0440\u0435\u0434\u043f\u043e\u043b\u043e\u0436\u0438\u043c, \u0432\u044b \u0440\u0435\u0448\u0438\u043b\u0438 \u0432\u043d\u0435\u0434\u0440\u0438\u0442\u044c Kotlin Multiplatform \u0432 \u0441\u0432\u043e\u0439 \u043f\u0440\u043e\u0435\u043a\u0442, \u0447\u0442\u043e\u0431\u044b \u043f\u0435\u0440\u0435\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043b\u043e\u0433\u0438\u043a\u0443 \u043d\u0430 iOS \u0438 Android. \u0420\u0430\u043d\u043e \u0438\u043b\u0438 \u043f\u043e\u0437\u0434\u043d\u043e \u0432\u044b \u0437\u0430\u0445\u043e\u0442\u0438\u0442\u0435 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0411\u043e\u043b\u044c\u0448\u0443\u044e \u0424\u0438\u0447\u0443, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0431\u0443\u0434\u0435\u0442 \u0432\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u0432 \u0441\u0435\u0431\u044f \u0438 \u0441\u043b\u043e\u0436\u043d\u0443\u044e \u043c\u043d\u043e\u0433\u043e\u043f\u043e\u0442\u043e\u0447\u043d\u0443\u044e \u043b\u043e\u0433\u0438\u043a\u0443, \u043f\u043e\u0445\u043e\u0434\u044b \u0432 \u0441\u0435\u0442\u044c, \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435. \u041a\u0430\u0436\u0434\u044b\u0439 \u0438\u0437 \u044d\u0442\u0438\u0445 \u044d\u0442\u0430\u043f\u043e\u0432 \u0432\u044b \u043f\u0440\u0438\u0432\u044b\u043a\u043b\u0438 \u0434\u0435\u043b\u0430\u0442\u044c \u043d\u0430 \u0441\u0432\u043e\u0435\u0439 \u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435 (\u0432\u0435\u0434\u044c \u0434\u0435\u043b\u0430\u043b\u0438 \u044d\u0442\u043e \u0442\u044b\u0441\u044f\u0447\u0443 \u0440\u0430\u0437). \u041d\u043e \u0432 \u043c\u0443\u043b\u044c\u0442\u0438\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435 \u043d\u0435\u0442 \u043f\u0440\u0438\u0432\u044b\u0447\u043d\u044b\u0445 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a \u0438 \u043f\u043e\u0434\u0445\u043e\u0434\u043e\u0432, \u0437\u0430\u0442\u043e \u0435\u0441\u0442\u044c \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u043e \u043d\u043e\u0432\u044b\u0439 \u0441\u0442\u0435\u043a \u0438 \u0442\u044b\u0441\u044f\u0447\u0430 \u043d\u043e\u0432\u044b\u0445 \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u0432 \u044d\u043b\u0435\u0433\u0430\u043d\u0442\u043d\u043e \u0432\u044b\u0441\u0442\u0440\u0435\u043b\u0438\u0442\u044c \u0441\u0435\u0431\u0435 \u0432 \u043d\u043e\u0433\u0443. \u042f\u043d\u0434\u0435\u043a\u0441.\u041a\u0430\u0440\u0442\u044b \u0438 \u0414\u043c\u0438\u0442\u0440\u0438\u0439 \u042f\u043a\u043e\u0432\u043b\u0435\u0432 <a href=\"https:\/\/habr.com\/ru\/users\/yakdmt\/\" class=\"user_link\">yakdmt<\/a> \u043f\u0440\u043e\u0448\u043b\u0438 \u0442\u0435\u0440\u043d\u0438\u0441\u0442\u044b\u0439 \u043f\u0443\u0442\u044c \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0444\u0438\u0447\u0438 \u0432 \u043c\u0443\u043b\u044c\u0442\u0438\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435. <\/p>\n<div class=\"oembed\"><iframe allowfullscreen id=\"602a432030f707d266c0ec49\" src=\"https:\/\/embedd.srv.habr.com\/iframe\/602a432030f707d266c0ec49\"><\/iframe><\/div>\n<p>\u2014 \u0414\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u0430 \u043f\u0430\u0440\u0443 \u0441\u043b\u043e\u0432 \u043e \u0441\u0435\u0431\u0435. \u041c\u0435\u043d\u044f \u0437\u043e\u0432\u0443\u0442 \u0414\u043c\u0438\u0442\u0440\u0438\u0439 \u042f\u043a\u043e\u0432\u043b\u0435\u0432. \u042f \u043f\u043e\u0440\u0430\u0431\u043e\u0442\u0430\u043b \u0432 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u0441\u0442\u0430\u0440\u0442\u0430\u043f\u0430\u0445, \u0432 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u0431\u0430\u043d\u043a\u0430\u0445, \u0430 \u0441\u0435\u0439\u0447\u0430\u0441 \u0440\u0430\u0431\u043e\u0442\u0430\u044e \u0432 \u042f\u043d\u0434\u0435\u043a\u0441\u0435 \u043d\u0430\u0434 Android-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435\u043c \u042f\u043d\u0434\u0435\u043a\u0441.\u041a\u0430\u0440\u0442. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0435\u0449\u0435 \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u0438\u0448\u0443 \u043d\u0430 Kotlin Multiplatform \u043a\u0440\u043e\u0441\u0441\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u0443\u044e \u043b\u043e\u0433\u0438\u043a\u0443.  <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-318323","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/318323","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=318323"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/318323\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=318323"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=318323"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=318323"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}