1 | (function (root, factory) {
|
2 | if (typeof define === 'function' && define.amd)
|
3 | define(['exports', 'kotlin', 'ktor-ktor-client-json-jsLegacy', 'ktor-ktor-client-serialization-jsLegacy', 'ktor-ktor-client-core-jsLegacy', 'kotlinx-serialization-kotlinx-serialization-json-jsLegacy', 'ktor-ktor-http-jsLegacy', 'kotlinx-serialization-kotlinx-serialization-core-jsLegacy', 'kotlinx-coroutines-core'], factory);
|
4 | else if (typeof exports === 'object')
|
5 | factory(module.exports, require('kotlin'), require('ktor-ktor-client-json-jsLegacy'), require('ktor-ktor-client-serialization-jsLegacy'), require('ktor-ktor-client-core-jsLegacy'), require('kotlinx-serialization-kotlinx-serialization-json-jsLegacy'), require('ktor-ktor-http-jsLegacy'), require('kotlinx-serialization-kotlinx-serialization-core-jsLegacy'), require('kotlinx-coroutines-core'));
|
6 | else {
|
7 | if (typeof kotlin === 'undefined') {
|
8 | throw new Error("Error loading module 'git-rest-wrapper-gitrest'. Its dependency 'kotlin' was not found. Please, check whether 'kotlin' is loaded prior to 'git-rest-wrapper-gitrest'.");
|
9 | }if (typeof this['ktor-ktor-client-json-jsLegacy'] === 'undefined') {
|
10 | throw new Error("Error loading module 'git-rest-wrapper-gitrest'. Its dependency 'ktor-ktor-client-json-jsLegacy' was not found. Please, check whether 'ktor-ktor-client-json-jsLegacy' is loaded prior to 'git-rest-wrapper-gitrest'.");
|
11 | }if (typeof this['ktor-ktor-client-serialization-jsLegacy'] === 'undefined') {
|
12 | throw new Error("Error loading module 'git-rest-wrapper-gitrest'. Its dependency 'ktor-ktor-client-serialization-jsLegacy' was not found. Please, check whether 'ktor-ktor-client-serialization-jsLegacy' is loaded prior to 'git-rest-wrapper-gitrest'.");
|
13 | }if (typeof this['ktor-ktor-client-core-jsLegacy'] === 'undefined') {
|
14 | throw new Error("Error loading module 'git-rest-wrapper-gitrest'. Its dependency 'ktor-ktor-client-core-jsLegacy' was not found. Please, check whether 'ktor-ktor-client-core-jsLegacy' is loaded prior to 'git-rest-wrapper-gitrest'.");
|
15 | }if (typeof this['kotlinx-serialization-kotlinx-serialization-json-jsLegacy'] === 'undefined') {
|
16 | throw new Error("Error loading module 'git-rest-wrapper-gitrest'. Its dependency 'kotlinx-serialization-kotlinx-serialization-json-jsLegacy' was not found. Please, check whether 'kotlinx-serialization-kotlinx-serialization-json-jsLegacy' is loaded prior to 'git-rest-wrapper-gitrest'.");
|
17 | }if (typeof this['ktor-ktor-http-jsLegacy'] === 'undefined') {
|
18 | throw new Error("Error loading module 'git-rest-wrapper-gitrest'. Its dependency 'ktor-ktor-http-jsLegacy' was not found. Please, check whether 'ktor-ktor-http-jsLegacy' is loaded prior to 'git-rest-wrapper-gitrest'.");
|
19 | }if (typeof this['kotlinx-serialization-kotlinx-serialization-core-jsLegacy'] === 'undefined') {
|
20 | throw new Error("Error loading module 'git-rest-wrapper-gitrest'. Its dependency 'kotlinx-serialization-kotlinx-serialization-core-jsLegacy' was not found. Please, check whether 'kotlinx-serialization-kotlinx-serialization-core-jsLegacy' is loaded prior to 'git-rest-wrapper-gitrest'.");
|
21 | }if (typeof this['kotlinx-coroutines-core'] === 'undefined') {
|
22 | throw new Error("Error loading module 'git-rest-wrapper-gitrest'. Its dependency 'kotlinx-coroutines-core' was not found. Please, check whether 'kotlinx-coroutines-core' is loaded prior to 'git-rest-wrapper-gitrest'.");
|
23 | }root['git-rest-wrapper-gitrest'] = factory(typeof this['git-rest-wrapper-gitrest'] === 'undefined' ? {} : this['git-rest-wrapper-gitrest'], kotlin, this['ktor-ktor-client-json-jsLegacy'], this['ktor-ktor-client-serialization-jsLegacy'], this['ktor-ktor-client-core-jsLegacy'], this['kotlinx-serialization-kotlinx-serialization-json-jsLegacy'], this['ktor-ktor-http-jsLegacy'], this['kotlinx-serialization-kotlinx-serialization-core-jsLegacy'], this['kotlinx-coroutines-core']);
|
24 | }
|
25 | }(this, function (_, Kotlin, $module$ktor_ktor_client_json_jsLegacy, $module$ktor_ktor_client_serialization_jsLegacy, $module$ktor_ktor_client_core_jsLegacy, $module$kotlinx_serialization_kotlinx_serialization_json_jsLegacy, $module$ktor_ktor_http_jsLegacy, $module$kotlinx_serialization_kotlinx_serialization_core_jsLegacy, $module$kotlinx_coroutines_core) {
|
26 | 'use strict';
|
27 | var $$importsForInline$$ = _.$$importsForInline$$ || (_.$$importsForInline$$ = {});
|
28 | var Unit = Kotlin.kotlin.Unit;
|
29 | var COROUTINE_SUSPENDED = Kotlin.kotlin.coroutines.intrinsics.COROUTINE_SUSPENDED;
|
30 | var CoroutineImpl = Kotlin.kotlin.coroutines.CoroutineImpl;
|
31 | var equals = Kotlin.equals;
|
32 | var RuntimeException_init = Kotlin.kotlin.RuntimeException_init_pdl1vj$;
|
33 | var List = Kotlin.kotlin.collections.List;
|
34 | var Any = Object;
|
35 | var throwCCE = Kotlin.throwCCE;
|
36 | var toString = Kotlin.toString;
|
37 | var Exception = Kotlin.kotlin.Exception;
|
38 | var HashMap_init = Kotlin.kotlin.collections.HashMap_init_q3lmfv$;
|
39 | var Kind_CLASS = Kotlin.Kind.CLASS;
|
40 | var Kind_INTERFACE = Kotlin.Kind.INTERFACE;
|
41 | var JsonFeature = $module$ktor_ktor_client_json_jsLegacy.io.ktor.client.features.json.JsonFeature;
|
42 | var KotlinxSerializer = $module$ktor_ktor_client_serialization_jsLegacy.io.ktor.client.features.json.serializer.KotlinxSerializer;
|
43 | var HttpClient = $module$ktor_ktor_client_core_jsLegacy.io.ktor.client.HttpClient_f0veat$;
|
44 | var isBlank = Kotlin.kotlin.text.isBlank_gw00vp$;
|
45 | var println = Kotlin.kotlin.io.println_s8jyv4$;
|
46 | var Json = $module$kotlinx_serialization_kotlinx_serialization_json_jsLegacy.kotlinx.serialization.json.Json_x26noe$;
|
47 | var removePrefix = Kotlin.kotlin.text.removePrefix_gsj5wt$;
|
48 | var hashCode = Kotlin.hashCode;
|
49 | var first = Kotlin.kotlin.collections.first_us0mfu$;
|
50 | var Regex_init = Kotlin.kotlin.text.Regex_init_61zpoe$;
|
51 | var ensureNotNull = Kotlin.ensureNotNull;
|
52 | var Kind_OBJECT = Kotlin.Kind.OBJECT;
|
53 | var getKClass = Kotlin.getKClass;
|
54 | var createKType = Kotlin.createKType;
|
55 | var createInvariantKTypeProjection = Kotlin.createInvariantKTypeProjection;
|
56 | var URLProtocol = $module$ktor_ktor_http_jsLegacy.io.ktor.http.URLProtocol;
|
57 | var header = $module$ktor_ktor_client_core_jsLegacy.io.ktor.client.request.header_xadl6p$;
|
58 | var defaultRequest = $module$ktor_ktor_client_core_jsLegacy.io.ktor.client.features.defaultRequest_fxc3ki$;
|
59 | var takeFrom = $module$ktor_ktor_client_core_jsLegacy.$$importsForInline$$['ktor-ktor-http-jsLegacy'].io.ktor.http.takeFrom_jl1sg7$;
|
60 | var utils = $module$ktor_ktor_client_core_jsLegacy.io.ktor.client.utils;
|
61 | var url = $module$ktor_ktor_client_core_jsLegacy.io.ktor.client.request.url_3rzbk2$;
|
62 | var HttpMethod = $module$ktor_ktor_client_core_jsLegacy.$$importsForInline$$['ktor-ktor-http-jsLegacy'].io.ktor.http.HttpMethod;
|
63 | var HttpRequestBuilder_init = $module$ktor_ktor_client_core_jsLegacy.io.ktor.client.request.HttpRequestBuilder;
|
64 | var HttpStatement_init = $module$ktor_ktor_client_core_jsLegacy.io.ktor.client.statement.HttpStatement;
|
65 | var HttpResponse = $module$ktor_ktor_client_core_jsLegacy.io.ktor.client.statement.HttpResponse;
|
66 | var complete = $module$ktor_ktor_client_core_jsLegacy.io.ktor.client.statement.complete_abn2de$;
|
67 | var call = $module$ktor_ktor_client_core_jsLegacy.io.ktor.client.call;
|
68 | var TypeInfo_init = $module$ktor_ktor_client_core_jsLegacy.io.ktor.client.call.TypeInfo;
|
69 | var NullableSerializer = $module$kotlinx_serialization_kotlinx_serialization_core_jsLegacy.kotlinx.serialization.internal.NullableSerializer;
|
70 | var PluginGeneratedSerialDescriptor = $module$kotlinx_serialization_kotlinx_serialization_core_jsLegacy.kotlinx.serialization.internal.PluginGeneratedSerialDescriptor;
|
71 | var internal = $module$kotlinx_serialization_kotlinx_serialization_core_jsLegacy.kotlinx.serialization.internal;
|
72 | var UnknownFieldException = $module$kotlinx_serialization_kotlinx_serialization_core_jsLegacy.kotlinx.serialization.UnknownFieldException;
|
73 | var GeneratedSerializer = $module$kotlinx_serialization_kotlinx_serialization_core_jsLegacy.kotlinx.serialization.internal.GeneratedSerializer;
|
74 | var PrimitiveClasses$stringClass = Kotlin.kotlin.reflect.js.internal.PrimitiveClasses.stringClass;
|
75 | var ReferenceArraySerializer = $module$kotlinx_serialization_kotlinx_serialization_core_jsLegacy.kotlinx.serialization.internal.ReferenceArraySerializer;
|
76 | var firstOrNull = Kotlin.kotlin.collections.firstOrNull_2p1efm$;
|
77 | var replace = Kotlin.kotlin.text.replace_680rmw$;
|
78 | var PrimitiveKind = $module$kotlinx_serialization_kotlinx_serialization_core_jsLegacy.kotlinx.serialization.descriptors.PrimitiveKind;
|
79 | var PrimitiveSerialDescriptor = $module$kotlinx_serialization_kotlinx_serialization_core_jsLegacy.kotlinx.serialization.descriptors.PrimitiveSerialDescriptor_xytc2a$;
|
80 | var kotlin_js_internal_StringCompanionObject = Kotlin.kotlin.js.internal.StringCompanionObject;
|
81 | var serializer = $module$kotlinx_serialization_kotlinx_serialization_core_jsLegacy.kotlinx.serialization.builtins.serializer_6eet4j$;
|
82 | var KSerializer = $module$kotlinx_serialization_kotlinx_serialization_core_jsLegacy.kotlinx.serialization.KSerializer;
|
83 | var split = Kotlin.kotlin.text.split_ip8yn$;
|
84 | var coroutines = $module$kotlinx_coroutines_core.kotlinx.coroutines;
|
85 | var promise = $module$kotlinx_coroutines_core.kotlinx.coroutines.promise_pda6u4$;
|
86 | var to = Kotlin.kotlin.to_ujzrz7$;
|
87 | var toMap = Kotlin.kotlin.collections.toMap_6hr0sd$;
|
88 | var collectionSizeOrDefault = Kotlin.kotlin.collections.collectionSizeOrDefault_ba2ldo$;
|
89 | var ArrayList_init = Kotlin.kotlin.collections.ArrayList_init_ww73n8$;
|
90 | var copyToArray = Kotlin.kotlin.collections.copyToArray;
|
91 | var await_0 = $module$kotlinx_coroutines_core.kotlinx.coroutines.await_t11jrl$;
|
92 | var toLong = Kotlin.kotlin.text.toLong_pdl1vz$;
|
93 | var startsWith = Kotlin.kotlin.text.startsWith_7epoxm$;
|
94 | var L864000000 = Kotlin.Long.fromInt(864000000);
|
95 | License.prototype = Object.create(DelegateResource.prototype);
|
96 | License.prototype.constructor = License;
|
97 | Repo.prototype = Object.create(DelegateResource.prototype);
|
98 | Repo.prototype.constructor = Repo;
|
99 | UrlType$HTTP.prototype = Object.create(UrlType.prototype);
|
100 | UrlType$HTTP.prototype.constructor = UrlType$HTTP;
|
101 | UrlType$HTTPS.prototype = Object.create(UrlType.prototype);
|
102 | UrlType$HTTPS.prototype.constructor = UrlType$HTTPS;
|
103 | UrlType$SSH.prototype = Object.create(UrlType.prototype);
|
104 | UrlType$SSH.prototype.constructor = UrlType$SSH;
|
105 | User.prototype = Object.create(DelegateResource.prototype);
|
106 | User.prototype.constructor = User;
|
107 | GiteaRepo.prototype = Object.create(Repo.prototype);
|
108 | GiteaRepo.prototype.constructor = GiteaRepo;
|
109 | GiteaUser.prototype = Object.create(User.prototype);
|
110 | GiteaUser.prototype.constructor = GiteaUser;
|
111 | GithubLicense.prototype = Object.create(License.prototype);
|
112 | GithubLicense.prototype.constructor = GithubLicense;
|
113 | GithubRepo.prototype = Object.create(Repo.prototype);
|
114 | GithubRepo.prototype.constructor = GithubRepo;
|
115 | GithubUser.prototype = Object.create(User.prototype);
|
116 | GithubUser.prototype.constructor = GithubUser;
|
117 | GitlabLicense.prototype = Object.create(License.prototype);
|
118 | GitlabLicense.prototype.constructor = GitlabLicense;
|
119 | GitlabRepo.prototype = Object.create(Repo.prototype);
|
120 | GitlabRepo.prototype.constructor = GitlabRepo;
|
121 | GitlabUser.prototype = Object.create(User.prototype);
|
122 | GitlabUser.prototype.constructor = GitlabUser;
|
123 | function gitrest(block) {
|
124 | var $receiver = new GitrestConfig();
|
125 | block($receiver);
|
126 | var config = $receiver;
|
127 | return new GitrestClient(config);
|
128 | }
|
129 | function GitrestClient(config) {
|
130 | this.config_0 = config;
|
131 | this.providers_0 = HashMap_init();
|
132 | }
|
133 | function Coroutine$get_0($this, str_0, endpointKey_0, block_0, continuation_0) {
|
134 | CoroutineImpl.call(this, continuation_0);
|
135 | this.exceptionState_0 = 8;
|
136 | this.$this = $this;
|
137 | this.local$tmp$_2 = void 0;
|
138 | this.local$tmp$_3 = void 0;
|
139 | this.local$providerStr = void 0;
|
140 | this.local$requestKey = void 0;
|
141 | this.local$tmp$_4 = void 0;
|
142 | this.local$str = str_0;
|
143 | this.local$endpointKey = endpointKey_0;
|
144 | this.local$block = block_0;
|
145 | }
|
146 | Coroutine$get_0.$metadata$ = {
|
147 | kind: Kotlin.Kind.CLASS,
|
148 | simpleName: null,
|
149 | interfaces: [CoroutineImpl]
|
150 | };
|
151 | Coroutine$get_0.prototype = Object.create(CoroutineImpl.prototype);
|
152 | Coroutine$get_0.prototype.constructor = Coroutine$get_0;
|
153 | Coroutine$get_0.prototype.doResume = function () {
|
154 | do
|
155 | try {
|
156 | switch (this.state_0) {
|
157 | case 0:
|
158 | var tmp$, tmp$_0, tmp$_1;
|
159 | this.local$providerStr = ProviderString_init_1(this.local$str);
|
160 | this.local$requestKey = this.local$providerStr.toString() + ':' + this.local$endpointKey;
|
161 | this.state_0 = 1;
|
162 | this.result_0 = this.$this.config_0.cache.get_ytbaoo$(this.local$requestKey, this);
|
163 | if (this.result_0 === COROUTINE_SUSPENDED)
|
164 | return COROUTINE_SUSPENDED;
|
165 | continue;
|
166 | case 1:
|
167 | if ((tmp$ = this.result_0) != null) {
|
168 | this.$this.config_0.logDebug('GIT-REST: Returning cached entry for ' + this.local$providerStr);
|
169 | return tmp$;
|
170 | } else {
|
171 | this.state_0 = 2;
|
172 | continue;
|
173 | }
|
174 |
|
175 | case 2:
|
176 | var providerId = this.local$providerStr.provider + '@' + this.local$providerStr.hostname;
|
177 | var tmp$_2;
|
178 | if ((tmp$_0 = this.$this.providers_0.get_11rb$(providerId)) != null)
|
179 | tmp$_2 = tmp$_0;
|
180 | else {
|
181 | var tmp$_3, tmp$_4, tmp$_5;
|
182 | var tmp$_6;
|
183 | var $receiver = this.$this.config_0.providers;
|
184 | var firstOrNull$result;
|
185 | firstOrNull$break: do {
|
186 | var tmp$_7;
|
187 | for (tmp$_7 = 0; tmp$_7 !== $receiver.length; ++tmp$_7) {
|
188 | var element = $receiver[tmp$_7];
|
189 | if (equals(element.key, this.local$providerStr.provider)) {
|
190 | firstOrNull$result = element;
|
191 | break firstOrNull$break;
|
192 | }}
|
193 | firstOrNull$result = null;
|
194 | }
|
195 | while (false);
|
196 | if ((tmp$_4 = (tmp$_3 = firstOrNull$result) != null ? tmp$_3.create_wf0mc2$(this.$this.config_0, this.local$providerStr.hostname) : null) != null) {
|
197 | this.$this.providers_0.put_xwzc9p$(providerId, tmp$_4);
|
198 | tmp$_6 = tmp$_4;
|
199 | } else
|
200 | tmp$_6 = null;
|
201 | tmp$_5 = tmp$_6;
|
202 | if (tmp$_5 == null) {
|
203 | throw RuntimeException_init('Provider not found: ' + providerId);
|
204 | }tmp$_2 = tmp$_5;
|
205 | }
|
206 |
|
207 | var provider = tmp$_2;
|
208 | this.exceptionState_0 = 6;
|
209 | this.state_0 = 3;
|
210 | this.result_0 = this.local$block(provider, this.local$providerStr.id, this);
|
211 | if (this.result_0 === COROUTINE_SUSPENDED)
|
212 | return COROUTINE_SUSPENDED;
|
213 | continue;
|
214 | case 3:
|
215 | var tmp$_8;
|
216 | if ((tmp$_1 = this.result_0) != null) {
|
217 | var tmp$_9, tmp$_10, tmp$_11, tmp$_12;
|
218 | if (((tmp$_10 = Kotlin.isType(tmp$_9 = tmp$_1, DelegateResource) ? tmp$_9 : null) != null ? (tmp$_10.setId_qtmmzu$(this.local$providerStr), Unit) : null) == null) {
|
219 | if ((tmp$_12 = Kotlin.isType(tmp$_11 = tmp$_1, List) ? tmp$_11 : null) != null) {
|
220 | var tmp$_13;
|
221 | tmp$_13 = tmp$_12.iterator();
|
222 | while (tmp$_13.hasNext()) {
|
223 | var element_0 = tmp$_13.next();
|
224 | element_0.setId_qtmmzu$(this.local$providerStr);
|
225 | }
|
226 | }}tmp$_8 = tmp$_1;
|
227 | } else
|
228 | tmp$_8 = null;
|
229 | if ((this.local$tmp$_2 = tmp$_8) != null) {
|
230 | var tmp$_14;
|
231 | this.state_0 = 4;
|
232 | this.result_0 = this.$this.config_0.cache.set_bm4g0d$(this.local$requestKey, Kotlin.isType(tmp$_14 = this.local$tmp$_2, Any) ? tmp$_14 : throwCCE(), this);
|
233 | if (this.result_0 === COROUTINE_SUSPENDED)
|
234 | return COROUTINE_SUSPENDED;
|
235 | continue;
|
236 | } else {
|
237 | this.local$tmp$_4 = null;
|
238 | this.state_0 = 5;
|
239 | continue;
|
240 | }
|
241 |
|
242 | case 4:
|
243 | this.local$tmp$_4 = this.local$tmp$_2;
|
244 | this.state_0 = 5;
|
245 | continue;
|
246 | case 5:
|
247 | this.local$tmp$_3 = this.local$tmp$_4;
|
248 | this.exceptionState_0 = 8;
|
249 | this.state_0 = 7;
|
250 | continue;
|
251 | case 6:
|
252 | this.exceptionState_0 = 8;
|
253 | var e = this.exception_0;
|
254 | if (Kotlin.isType(e, Exception)) {
|
255 | if (this.$this.config_0.strictMode)
|
256 | throw e;
|
257 | else
|
258 | this.$this.config_0.logError('GIT-REST: Error fetching ' + this.local$str + ': ' + toString(Kotlin.getKClassFromExpression(e).simpleName) + ' - ' + toString(e.message));
|
259 | this.local$tmp$_3 = null;
|
260 | } else
|
261 | throw e;
|
262 | this.state_0 = 7;
|
263 | continue;
|
264 | case 7:
|
265 | return this.local$tmp$_3;
|
266 | case 8:
|
267 | throw this.exception_0;
|
268 | default:this.state_0 = 8;
|
269 | throw new Error('State Machine Unreachable execution');
|
270 | }
|
271 | } catch (e) {
|
272 | if (this.state_0 === 8) {
|
273 | this.exceptionState_0 = this.state_0;
|
274 | throw e;
|
275 | } else {
|
276 | this.state_0 = this.exceptionState_0;
|
277 | this.exception_0 = e;
|
278 | }
|
279 | }
|
280 | while (true);
|
281 | };
|
282 | GitrestClient.prototype.get_0 = function (str_0, endpointKey_0, block_0, continuation_0, suspended) {
|
283 | var instance = new Coroutine$get_0(this, str_0, endpointKey_0, block_0, continuation_0);
|
284 | if (suspended)
|
285 | return instance;
|
286 | else
|
287 | return instance.doResume(null);
|
288 | };
|
289 | function Coroutine$GitrestClient$getUser$lambda(it_0, id_0, continuation_0) {
|
290 | CoroutineImpl.call(this, continuation_0);
|
291 | this.exceptionState_0 = 1;
|
292 | this.local$it = it_0;
|
293 | this.local$id = id_0;
|
294 | }
|
295 | Coroutine$GitrestClient$getUser$lambda.$metadata$ = {
|
296 | kind: Kotlin.Kind.CLASS,
|
297 | simpleName: null,
|
298 | interfaces: [CoroutineImpl]
|
299 | };
|
300 | Coroutine$GitrestClient$getUser$lambda.prototype = Object.create(CoroutineImpl.prototype);
|
301 | Coroutine$GitrestClient$getUser$lambda.prototype.constructor = Coroutine$GitrestClient$getUser$lambda;
|
302 | Coroutine$GitrestClient$getUser$lambda.prototype.doResume = function () {
|
303 | do
|
304 | try {
|
305 | switch (this.state_0) {
|
306 | case 0:
|
307 | this.state_0 = 2;
|
308 | this.result_0 = this.local$it.getUser_61zpoe$(this.local$id, this);
|
309 | if (this.result_0 === COROUTINE_SUSPENDED)
|
310 | return COROUTINE_SUSPENDED;
|
311 | continue;
|
312 | case 1:
|
313 | throw this.exception_0;
|
314 | case 2:
|
315 | return this.result_0;
|
316 | default:this.state_0 = 1;
|
317 | throw new Error('State Machine Unreachable execution');
|
318 | }
|
319 | } catch (e) {
|
320 | if (this.state_0 === 1) {
|
321 | this.exceptionState_0 = this.state_0;
|
322 | throw e;
|
323 | } else {
|
324 | this.state_0 = this.exceptionState_0;
|
325 | this.exception_0 = e;
|
326 | }
|
327 | }
|
328 | while (true);
|
329 | };
|
330 | function GitrestClient$getUser$lambda(it_0, id_0, continuation_0, suspended) {
|
331 | var instance = new Coroutine$GitrestClient$getUser$lambda(it_0, id_0, continuation_0);
|
332 | if (suspended)
|
333 | return instance;
|
334 | else
|
335 | return instance.doResume(null);
|
336 | }
|
337 | GitrestClient.prototype.getUser_61zpoe$ = function (str, continuation) {
|
338 | return this.get_0(str, 'getUser', GitrestClient$getUser$lambda, continuation);
|
339 | };
|
340 | function Coroutine$GitrestClient$getRepo$lambda(it_0, id_0, continuation_0) {
|
341 | CoroutineImpl.call(this, continuation_0);
|
342 | this.exceptionState_0 = 1;
|
343 | this.local$it = it_0;
|
344 | this.local$id = id_0;
|
345 | }
|
346 | Coroutine$GitrestClient$getRepo$lambda.$metadata$ = {
|
347 | kind: Kotlin.Kind.CLASS,
|
348 | simpleName: null,
|
349 | interfaces: [CoroutineImpl]
|
350 | };
|
351 | Coroutine$GitrestClient$getRepo$lambda.prototype = Object.create(CoroutineImpl.prototype);
|
352 | Coroutine$GitrestClient$getRepo$lambda.prototype.constructor = Coroutine$GitrestClient$getRepo$lambda;
|
353 | Coroutine$GitrestClient$getRepo$lambda.prototype.doResume = function () {
|
354 | do
|
355 | try {
|
356 | switch (this.state_0) {
|
357 | case 0:
|
358 | this.state_0 = 2;
|
359 | this.result_0 = this.local$it.getRepo_61zpoe$(this.local$id, this);
|
360 | if (this.result_0 === COROUTINE_SUSPENDED)
|
361 | return COROUTINE_SUSPENDED;
|
362 | continue;
|
363 | case 1:
|
364 | throw this.exception_0;
|
365 | case 2:
|
366 | return this.result_0;
|
367 | default:this.state_0 = 1;
|
368 | throw new Error('State Machine Unreachable execution');
|
369 | }
|
370 | } catch (e) {
|
371 | if (this.state_0 === 1) {
|
372 | this.exceptionState_0 = this.state_0;
|
373 | throw e;
|
374 | } else {
|
375 | this.state_0 = this.exceptionState_0;
|
376 | this.exception_0 = e;
|
377 | }
|
378 | }
|
379 | while (true);
|
380 | };
|
381 | function GitrestClient$getRepo$lambda(it_0, id_0, continuation_0, suspended) {
|
382 | var instance = new Coroutine$GitrestClient$getRepo$lambda(it_0, id_0, continuation_0);
|
383 | if (suspended)
|
384 | return instance;
|
385 | else
|
386 | return instance.doResume(null);
|
387 | }
|
388 | GitrestClient.prototype.getRepo_61zpoe$ = function (str, continuation) {
|
389 | return this.get_0(str, 'getRepo', GitrestClient$getRepo$lambda, continuation);
|
390 | };
|
391 | function Coroutine$GitrestClient$getRepoContributors$lambda(it_0, id_0, continuation_0) {
|
392 | CoroutineImpl.call(this, continuation_0);
|
393 | this.exceptionState_0 = 1;
|
394 | this.local$it = it_0;
|
395 | this.local$id = id_0;
|
396 | }
|
397 | Coroutine$GitrestClient$getRepoContributors$lambda.$metadata$ = {
|
398 | kind: Kotlin.Kind.CLASS,
|
399 | simpleName: null,
|
400 | interfaces: [CoroutineImpl]
|
401 | };
|
402 | Coroutine$GitrestClient$getRepoContributors$lambda.prototype = Object.create(CoroutineImpl.prototype);
|
403 | Coroutine$GitrestClient$getRepoContributors$lambda.prototype.constructor = Coroutine$GitrestClient$getRepoContributors$lambda;
|
404 | Coroutine$GitrestClient$getRepoContributors$lambda.prototype.doResume = function () {
|
405 | do
|
406 | try {
|
407 | switch (this.state_0) {
|
408 | case 0:
|
409 | this.state_0 = 2;
|
410 | this.result_0 = this.local$it.getRepoContributors_61zpoe$(this.local$id, this);
|
411 | if (this.result_0 === COROUTINE_SUSPENDED)
|
412 | return COROUTINE_SUSPENDED;
|
413 | continue;
|
414 | case 1:
|
415 | throw this.exception_0;
|
416 | case 2:
|
417 | return this.result_0;
|
418 | default:this.state_0 = 1;
|
419 | throw new Error('State Machine Unreachable execution');
|
420 | }
|
421 | } catch (e) {
|
422 | if (this.state_0 === 1) {
|
423 | this.exceptionState_0 = this.state_0;
|
424 | throw e;
|
425 | } else {
|
426 | this.state_0 = this.exceptionState_0;
|
427 | this.exception_0 = e;
|
428 | }
|
429 | }
|
430 | while (true);
|
431 | };
|
432 | function GitrestClient$getRepoContributors$lambda(it_0, id_0, continuation_0, suspended) {
|
433 | var instance = new Coroutine$GitrestClient$getRepoContributors$lambda(it_0, id_0, continuation_0);
|
434 | if (suspended)
|
435 | return instance;
|
436 | else
|
437 | return instance.doResume(null);
|
438 | }
|
439 | GitrestClient.prototype.getRepoContributors_61zpoe$ = function (str, continuation) {
|
440 | return this.get_0(str, 'getRepoContributors', GitrestClient$getRepoContributors$lambda, continuation);
|
441 | };
|
442 | function Coroutine$GitrestClient$getLicense$lambda(it_0, id_0, continuation_0) {
|
443 | CoroutineImpl.call(this, continuation_0);
|
444 | this.exceptionState_0 = 1;
|
445 | this.local$it = it_0;
|
446 | this.local$id = id_0;
|
447 | }
|
448 | Coroutine$GitrestClient$getLicense$lambda.$metadata$ = {
|
449 | kind: Kotlin.Kind.CLASS,
|
450 | simpleName: null,
|
451 | interfaces: [CoroutineImpl]
|
452 | };
|
453 | Coroutine$GitrestClient$getLicense$lambda.prototype = Object.create(CoroutineImpl.prototype);
|
454 | Coroutine$GitrestClient$getLicense$lambda.prototype.constructor = Coroutine$GitrestClient$getLicense$lambda;
|
455 | Coroutine$GitrestClient$getLicense$lambda.prototype.doResume = function () {
|
456 | do
|
457 | try {
|
458 | switch (this.state_0) {
|
459 | case 0:
|
460 | this.state_0 = 2;
|
461 | this.result_0 = this.local$it.getLicense_61zpoe$(this.local$id, this);
|
462 | if (this.result_0 === COROUTINE_SUSPENDED)
|
463 | return COROUTINE_SUSPENDED;
|
464 | continue;
|
465 | case 1:
|
466 | throw this.exception_0;
|
467 | case 2:
|
468 | return this.result_0;
|
469 | default:this.state_0 = 1;
|
470 | throw new Error('State Machine Unreachable execution');
|
471 | }
|
472 | } catch (e) {
|
473 | if (this.state_0 === 1) {
|
474 | this.exceptionState_0 = this.state_0;
|
475 | throw e;
|
476 | } else {
|
477 | this.state_0 = this.exceptionState_0;
|
478 | this.exception_0 = e;
|
479 | }
|
480 | }
|
481 | while (true);
|
482 | };
|
483 | function GitrestClient$getLicense$lambda(it_0, id_0, continuation_0, suspended) {
|
484 | var instance = new Coroutine$GitrestClient$getLicense$lambda(it_0, id_0, continuation_0);
|
485 | if (suspended)
|
486 | return instance;
|
487 | else
|
488 | return instance.doResume(null);
|
489 | }
|
490 | GitrestClient.prototype.getLicense_61zpoe$ = function (str, continuation) {
|
491 | return this.get_0(str, 'getLicense', GitrestClient$getLicense$lambda, continuation);
|
492 | };
|
493 | GitrestClient.$metadata$ = {
|
494 | kind: Kind_CLASS,
|
495 | simpleName: 'GitrestClient',
|
496 | interfaces: [RequestProvider]
|
497 | };
|
498 | function RequestProvider() {
|
499 | }
|
500 | RequestProvider.$metadata$ = {
|
501 | kind: Kind_INTERFACE,
|
502 | simpleName: 'RequestProvider',
|
503 | interfaces: []
|
504 | };
|
505 | function ServiceBuilder() {
|
506 | }
|
507 | function ServiceBuilder$ktor$lambda$lambda(this$ktor) {
|
508 | return function ($receiver) {
|
509 | $receiver.serializer = new KotlinxSerializer(this$ktor.jsonSerializer);
|
510 | return Unit;
|
511 | };
|
512 | }
|
513 | function ServiceBuilder$ktor$lambda(this$ktor, closure$block) {
|
514 | return function ($receiver) {
|
515 | $receiver.install_xlxg29$(JsonFeature.Feature, ServiceBuilder$ktor$lambda$lambda(this$ktor));
|
516 | closure$block($receiver);
|
517 | return Unit;
|
518 | };
|
519 | }
|
520 | ServiceBuilder.prototype.ktor_1v6kay$ = function ($receiver, block) {
|
521 | return HttpClient(ServiceBuilder$ktor$lambda($receiver, block));
|
522 | };
|
523 | ServiceBuilder.$metadata$ = {
|
524 | kind: Kind_INTERFACE,
|
525 | simpleName: 'ServiceBuilder',
|
526 | interfaces: []
|
527 | };
|
528 | function DelegateResource() {
|
529 | this.id_axp2ks$_0 = '';
|
530 | this.hostname_sgm644$_0 = '';
|
531 | this.provider_v1qh6e$_0 = '';
|
532 | }
|
533 | Object.defineProperty(DelegateResource.prototype, 'id', {
|
534 | configurable: true,
|
535 | get: function () {
|
536 | return this.id_axp2ks$_0;
|
537 | },
|
538 | set: function (id) {
|
539 | this.id_axp2ks$_0 = id;
|
540 | }
|
541 | });
|
542 | Object.defineProperty(DelegateResource.prototype, 'hostname', {
|
543 | configurable: true,
|
544 | get: function () {
|
545 | return this.hostname_sgm644$_0;
|
546 | },
|
547 | set: function (hostname) {
|
548 | this.hostname_sgm644$_0 = hostname;
|
549 | }
|
550 | });
|
551 | Object.defineProperty(DelegateResource.prototype, 'provider', {
|
552 | configurable: true,
|
553 | get: function () {
|
554 | return this.provider_v1qh6e$_0;
|
555 | },
|
556 | set: function (provider) {
|
557 | this.provider_v1qh6e$_0 = provider;
|
558 | }
|
559 | });
|
560 | Object.defineProperty(DelegateResource.prototype, 'providerString', {
|
561 | configurable: true,
|
562 | get: function () {
|
563 | return ProviderString_init_0(this.provider, this.hostname, this.id);
|
564 | }
|
565 | });
|
566 | DelegateResource.prototype.setId_qtmmzu$ = function (providerString) {
|
567 | this.hostname = providerString.hostname;
|
568 | this.provider = providerString.provider;
|
569 | if (isBlank(this.id))
|
570 | throw RuntimeException_init('GIT-REST: Malformed response, .id not provided in ' + toString(Kotlin.getKClassFromExpression(this).simpleName) + ', requested ' + providerString);
|
571 | };
|
572 | DelegateResource.$metadata$ = {
|
573 | kind: Kind_CLASS,
|
574 | simpleName: 'DelegateResource',
|
575 | interfaces: []
|
576 | };
|
577 | function GitrestConfig() {
|
578 | this.providers = [GithubProvider$Companion_getInstance(), GitlabProvider$Companion_getInstance(), GiteaProvider$Companion_getInstance()];
|
579 | this.strictMode = false;
|
580 | this.logDebug = GitrestConfig$logDebug$lambda;
|
581 | this.logError = GitrestConfig$logError$lambda;
|
582 | this.jsonSerializer = Json(void 0, GitrestConfig$jsonSerializer$lambda);
|
583 | this.cache = new MemoryCache();
|
584 | this.platformConfig = new PlatformConfig();
|
585 | }
|
586 | GitrestConfig.prototype.platform_9or9kc$ = function (block) {
|
587 | block(this.platformConfig);
|
588 | };
|
589 | function GitrestConfig$logDebug$lambda(it) {
|
590 | return Unit;
|
591 | }
|
592 | function GitrestConfig$logError$lambda(it) {
|
593 | println(it);
|
594 | return Unit;
|
595 | }
|
596 | function GitrestConfig$jsonSerializer$lambda($receiver) {
|
597 | $receiver.ignoreUnknownKeys = true;
|
598 | return Unit;
|
599 | }
|
600 | GitrestConfig.$metadata$ = {
|
601 | kind: Kind_CLASS,
|
602 | simpleName: 'GitrestConfig',
|
603 | interfaces: []
|
604 | };
|
605 | function License() {
|
606 | DelegateResource.call(this);
|
607 | this.name_hv9rx6$_0 = null;
|
608 | this.description_lwiggj$_0 = null;
|
609 | this.body_hox0f7$_0 = null;
|
610 | this.infoUrl_80v10y$_0 = null;
|
611 | this.permissions_4d9prp$_0 = null;
|
612 | this.conditions_x62ax9$_0 = null;
|
613 | this.limitations_do0i7e$_0 = null;
|
614 | }
|
615 | Object.defineProperty(License.prototype, 'name', {
|
616 | configurable: true,
|
617 | get: function () {
|
618 | return this.name_hv9rx6$_0;
|
619 | }
|
620 | });
|
621 | Object.defineProperty(License.prototype, 'description', {
|
622 | configurable: true,
|
623 | get: function () {
|
624 | return this.description_lwiggj$_0;
|
625 | }
|
626 | });
|
627 | Object.defineProperty(License.prototype, 'body', {
|
628 | configurable: true,
|
629 | get: function () {
|
630 | return this.body_hox0f7$_0;
|
631 | }
|
632 | });
|
633 | Object.defineProperty(License.prototype, 'infoUrl', {
|
634 | configurable: true,
|
635 | get: function () {
|
636 | return this.infoUrl_80v10y$_0;
|
637 | }
|
638 | });
|
639 | Object.defineProperty(License.prototype, 'permissions', {
|
640 | configurable: true,
|
641 | get: function () {
|
642 | return this.permissions_4d9prp$_0;
|
643 | }
|
644 | });
|
645 | Object.defineProperty(License.prototype, 'conditions', {
|
646 | configurable: true,
|
647 | get: function () {
|
648 | return this.conditions_x62ax9$_0;
|
649 | }
|
650 | });
|
651 | Object.defineProperty(License.prototype, 'limitations', {
|
652 | configurable: true,
|
653 | get: function () {
|
654 | return this.limitations_do0i7e$_0;
|
655 | }
|
656 | });
|
657 | License.$metadata$ = {
|
658 | kind: Kind_CLASS,
|
659 | simpleName: 'License',
|
660 | interfaces: [DelegateResource]
|
661 | };
|
662 | function ProviderString() {
|
663 | this.provider = null;
|
664 | this.hostname = null;
|
665 | this.id = null;
|
666 | }
|
667 | ProviderString.prototype.inferUrl_4sgkox$ = function (type) {
|
668 | if (type === void 0)
|
669 | type = UrlType$HTTPS_getInstance();
|
670 | return type.getUrl_puj7f4$(removePrefix(this.hostname, 'api.'), this.id);
|
671 | };
|
672 | ProviderString.prototype.toString = function () {
|
673 | return this.provider + '@' + this.hostname + ':' + this.id;
|
674 | };
|
675 | ProviderString.prototype.equals = function (other) {
|
676 | var tmp$, tmp$_0, tmp$_1;
|
677 | return (tmp$_1 = (tmp$_0 = Kotlin.isType(tmp$ = other, ProviderString) ? tmp$ : null) != null ? equals(this.provider, tmp$_0.provider) && equals(this.hostname, other.hostname) && equals(this.id, tmp$_0.id) : null) != null ? tmp$_1 : this === other;
|
678 | };
|
679 | ProviderString.prototype.hashCode = function () {
|
680 | var result = hashCode(this.provider);
|
681 | result = (31 * result | 0) + hashCode(this.hostname) | 0;
|
682 | result = (31 * result | 0) + hashCode(this.id) | 0;
|
683 | return result;
|
684 | };
|
685 | ProviderString.$metadata$ = {
|
686 | kind: Kind_CLASS,
|
687 | simpleName: 'ProviderString',
|
688 | interfaces: []
|
689 | };
|
690 | function ProviderString_init(provider, hostname, $this) {
|
691 | $this = $this || Object.create(ProviderString.prototype);
|
692 | ProviderString.call($this);
|
693 | $this.provider = provider;
|
694 | $this.hostname = hostname;
|
695 | $this.id = '';
|
696 | return $this;
|
697 | }
|
698 | function ProviderString_init_0(provider, hostname, id, $this) {
|
699 | $this = $this || Object.create(ProviderString.prototype);
|
700 | ProviderString_init_1(provider + '@' + hostname + ':' + id, $this);
|
701 | return $this;
|
702 | }
|
703 | function ProviderString_init_1(str, $this) {
|
704 | $this = $this || Object.create(ProviderString.prototype);
|
705 | ProviderString.call($this);
|
706 | var tmp$, tmp$_0, tmp$_1, tmp$_2, tmp$_3;
|
707 | if (str.length === 0)
|
708 | throw RuntimeException_init('GIT-REST: Empty ProviderString');
|
709 | var providerRegex = Regex_init('(?:(\\w*)(?:@([\\w.]*))?:)?([\\w-_./]*)');
|
710 | var hostnameRegex = Regex_init('(\\w+\\.\\w+)$');
|
711 | tmp$_0 = (tmp$ = providerRegex.matchEntire_6bul2c$(str)) != null ? tmp$.destructured : null;
|
712 | if (tmp$_0 == null) {
|
713 | throw RuntimeException_init("GIT-REST: Unable to parse ProviderString '" + str + "'");
|
714 | }var provider = tmp$_0.match.groupValues.get_za3lpa$(1);
|
715 | var hostname = tmp$_0.match.groupValues.get_za3lpa$(2);
|
716 | var id = tmp$_0.match.groupValues.get_za3lpa$(3);
|
717 | var tmp$_4 = provider.length === 0;
|
718 | if (tmp$_4) {
|
719 | tmp$_4 = hostname.length === 0;
|
720 | }if (tmp$_4) {
|
721 | var default_0 = first(DEFAULT_PROVIDERS);
|
722 | $this.provider = default_0.provider;
|
723 | $this.hostname = default_0.hostname;
|
724 | } else {
|
725 | if (provider.length === 0 || equals(provider, 'git')) {
|
726 | var $receiver = DEFAULT_PROVIDERS;
|
727 | var firstOrNull$result;
|
728 | firstOrNull$break: do {
|
729 | var tmp$_5;
|
730 | for (tmp$_5 = 0; tmp$_5 !== $receiver.length; ++tmp$_5) {
|
731 | var element = $receiver[tmp$_5];
|
732 | var tmp$_6, tmp$_7;
|
733 | if (equals((tmp$_6 = hostnameRegex.find_905azu$(element.hostname)) != null ? tmp$_6.value : null, (tmp$_7 = hostnameRegex.find_905azu$(hostname)) != null ? tmp$_7.value : null)) {
|
734 | firstOrNull$result = element;
|
735 | break firstOrNull$break;
|
736 | }}
|
737 | firstOrNull$result = null;
|
738 | }
|
739 | while (false);
|
740 | tmp$_1 = firstOrNull$result;
|
741 | if (tmp$_1 == null) {
|
742 | throw RuntimeException_init("GIT-REST: Unable to find a default provider for '" + str + "'");
|
743 | }var default_1 = tmp$_1;
|
744 | $this.provider = default_1.provider;
|
745 | $this.hostname = default_1.hostname;
|
746 | } else {
|
747 | if (hostname.length === 0) {
|
748 | var $receiver_0 = DEFAULT_PROVIDERS;
|
749 | var firstOrNull$result_0;
|
750 | firstOrNull$break: do {
|
751 | var tmp$_8;
|
752 | for (tmp$_8 = 0; tmp$_8 !== $receiver_0.length; ++tmp$_8) {
|
753 | var element_0 = $receiver_0[tmp$_8];
|
754 | if (equals(element_0.provider, provider)) {
|
755 | firstOrNull$result_0 = element_0;
|
756 | break firstOrNull$break;
|
757 | }}
|
758 | firstOrNull$result_0 = null;
|
759 | }
|
760 | while (false);
|
761 | tmp$_2 = firstOrNull$result_0;
|
762 | if (tmp$_2 == null) {
|
763 | throw RuntimeException_init("GIT-REST: Unable to find a default context for '" + str + "'");
|
764 | }var default_2 = tmp$_2;
|
765 | $this.provider = provider;
|
766 | $this.hostname = default_2.hostname;
|
767 | } else {
|
768 | var $receiver_1 = DEFAULT_PROVIDERS;
|
769 | var firstOrNull$result_1;
|
770 | firstOrNull$break: do {
|
771 | var tmp$_9;
|
772 | for (tmp$_9 = 0; tmp$_9 !== $receiver_1.length; ++tmp$_9) {
|
773 | var element_1 = $receiver_1[tmp$_9];
|
774 | var tmp$_10, tmp$_11;
|
775 | if (equals(element_1.provider, provider) && equals((tmp$_10 = hostnameRegex.find_905azu$(element_1.hostname)) != null ? tmp$_10.value : null, (tmp$_11 = hostnameRegex.find_905azu$(hostname)) != null ? tmp$_11.value : null)) {
|
776 | firstOrNull$result_1 = element_1;
|
777 | break firstOrNull$break;
|
778 | }}
|
779 | firstOrNull$result_1 = null;
|
780 | }
|
781 | while (false);
|
782 | var default_3 = firstOrNull$result_1;
|
783 | $this.provider = provider;
|
784 | $this.hostname = (tmp$_3 = default_3 != null ? default_3.hostname : null) != null ? tmp$_3 : hostname;
|
785 | }
|
786 | }
|
787 | }
|
788 | $this.id = id;
|
789 | return $this;
|
790 | }
|
791 | function Repo() {
|
792 | DelegateResource.call(this);
|
793 | this.description_eirp3i$_0 = null;
|
794 | this.url_eun8ip$_0 = null;
|
795 | this.websiteUrl_dmzd2q$_0 = null;
|
796 | this.gitUrlHttp_hdynwf$_0 = null;
|
797 | this.gitUrlSsh_ivwby5$_0 = null;
|
798 | this.license_6si5jh$_0 = null;
|
799 | this.defaultBranch_4ygp4l$_0 = null;
|
800 | }
|
801 | Object.defineProperty(Repo.prototype, 'description', {
|
802 | configurable: true,
|
803 | get: function () {
|
804 | return this.description_eirp3i$_0;
|
805 | }
|
806 | });
|
807 | Object.defineProperty(Repo.prototype, 'url', {
|
808 | configurable: true,
|
809 | get: function () {
|
810 | return this.url_eun8ip$_0;
|
811 | }
|
812 | });
|
813 | Object.defineProperty(Repo.prototype, 'websiteUrl', {
|
814 | configurable: true,
|
815 | get: function () {
|
816 | return this.websiteUrl_dmzd2q$_0;
|
817 | }
|
818 | });
|
819 | Object.defineProperty(Repo.prototype, 'gitUrlHttp', {
|
820 | configurable: true,
|
821 | get: function () {
|
822 | return this.gitUrlHttp_hdynwf$_0;
|
823 | }
|
824 | });
|
825 | Object.defineProperty(Repo.prototype, 'gitUrlSsh', {
|
826 | configurable: true,
|
827 | get: function () {
|
828 | return this.gitUrlSsh_ivwby5$_0;
|
829 | }
|
830 | });
|
831 | Object.defineProperty(Repo.prototype, 'license', {
|
832 | configurable: true,
|
833 | get: function () {
|
834 | return this.license_6si5jh$_0;
|
835 | }
|
836 | });
|
837 | Object.defineProperty(Repo.prototype, 'defaultBranch', {
|
838 | configurable: true,
|
839 | get: function () {
|
840 | return this.defaultBranch_4ygp4l$_0;
|
841 | }
|
842 | });
|
843 | Repo.prototype.setId_qtmmzu$ = function (providerString) {
|
844 | var tmp$;
|
845 | DelegateResource.prototype.setId_qtmmzu$.call(this, providerString);
|
846 | (tmp$ = this.license) != null ? (tmp$.setId_qtmmzu$(providerString), Unit) : null;
|
847 | };
|
848 | Repo.prototype.getRawFileUrl_puj7f4$$default = function (branchName, filePath) {
|
849 | return null;
|
850 | };
|
851 | Repo.prototype.getRawFileUrl_puj7f4$ = function (branchName, filePath, callback$default) {
|
852 | if (branchName === void 0)
|
853 | branchName = ensureNotNull(this.defaultBranch);
|
854 | return callback$default ? callback$default(branchName, filePath) : this.getRawFileUrl_puj7f4$$default(branchName, filePath);
|
855 | };
|
856 | Repo.$metadata$ = {
|
857 | kind: Kind_CLASS,
|
858 | simpleName: 'Repo',
|
859 | interfaces: [DelegateResource]
|
860 | };
|
861 | function UrlType(prefix, separator) {
|
862 | this.prefix = prefix;
|
863 | this.separator = separator;
|
864 | }
|
865 | UrlType.prototype.getUrl_puj7f4$ = function (hostname, path) {
|
866 | return this.prefix + hostname + this.separator + path;
|
867 | };
|
868 | function UrlType$HTTP() {
|
869 | UrlType$HTTP_instance = this;
|
870 | UrlType.call(this, 'http://', '/');
|
871 | }
|
872 | UrlType$HTTP.$metadata$ = {
|
873 | kind: Kind_OBJECT,
|
874 | simpleName: 'HTTP',
|
875 | interfaces: [UrlType]
|
876 | };
|
877 | var UrlType$HTTP_instance = null;
|
878 | function UrlType$HTTP_getInstance() {
|
879 | if (UrlType$HTTP_instance === null) {
|
880 | new UrlType$HTTP();
|
881 | }return UrlType$HTTP_instance;
|
882 | }
|
883 | function UrlType$HTTPS() {
|
884 | UrlType$HTTPS_instance = this;
|
885 | UrlType.call(this, 'https://', '/');
|
886 | }
|
887 | UrlType$HTTPS.$metadata$ = {
|
888 | kind: Kind_OBJECT,
|
889 | simpleName: 'HTTPS',
|
890 | interfaces: [UrlType]
|
891 | };
|
892 | var UrlType$HTTPS_instance = null;
|
893 | function UrlType$HTTPS_getInstance() {
|
894 | if (UrlType$HTTPS_instance === null) {
|
895 | new UrlType$HTTPS();
|
896 | }return UrlType$HTTPS_instance;
|
897 | }
|
898 | function UrlType$SSH() {
|
899 | UrlType$SSH_instance = this;
|
900 | UrlType.call(this, 'git@', ':');
|
901 | }
|
902 | UrlType$SSH.$metadata$ = {
|
903 | kind: Kind_OBJECT,
|
904 | simpleName: 'SSH',
|
905 | interfaces: [UrlType]
|
906 | };
|
907 | var UrlType$SSH_instance = null;
|
908 | function UrlType$SSH_getInstance() {
|
909 | if (UrlType$SSH_instance === null) {
|
910 | new UrlType$SSH();
|
911 | }return UrlType$SSH_instance;
|
912 | }
|
913 | UrlType.$metadata$ = {
|
914 | kind: Kind_CLASS,
|
915 | simpleName: 'UrlType',
|
916 | interfaces: []
|
917 | };
|
918 | function User() {
|
919 | DelegateResource.call(this);
|
920 | this.name_p9le18$_0 = null;
|
921 | this.url_33p196$_0 = null;
|
922 | this.avatarUrl_q68x0f$_0 = null;
|
923 | this.websiteUrl_beuvqt$_0 = null;
|
924 | this.email_6073dz$_0 = null;
|
925 | this.bio_341clv$_0 = null;
|
926 | }
|
927 | Object.defineProperty(User.prototype, 'name', {
|
928 | configurable: true,
|
929 | get: function () {
|
930 | return this.name_p9le18$_0;
|
931 | }
|
932 | });
|
933 | Object.defineProperty(User.prototype, 'url', {
|
934 | configurable: true,
|
935 | get: function () {
|
936 | return this.url_33p196$_0;
|
937 | }
|
938 | });
|
939 | Object.defineProperty(User.prototype, 'avatarUrl', {
|
940 | configurable: true,
|
941 | get: function () {
|
942 | return this.avatarUrl_q68x0f$_0;
|
943 | }
|
944 | });
|
945 | Object.defineProperty(User.prototype, 'websiteUrl', {
|
946 | configurable: true,
|
947 | get: function () {
|
948 | return this.websiteUrl_beuvqt$_0;
|
949 | }
|
950 | });
|
951 | Object.defineProperty(User.prototype, 'email', {
|
952 | configurable: true,
|
953 | get: function () {
|
954 | return this.email_6073dz$_0;
|
955 | }
|
956 | });
|
957 | Object.defineProperty(User.prototype, 'bio', {
|
958 | configurable: true,
|
959 | get: function () {
|
960 | return this.bio_341clv$_0;
|
961 | }
|
962 | });
|
963 | User.$metadata$ = {
|
964 | kind: Kind_CLASS,
|
965 | simpleName: 'User',
|
966 | interfaces: [DelegateResource]
|
967 | };
|
968 | function get$lambda($receiver) {
|
969 | return Unit;
|
970 | }
|
971 | function GiteaProvider(client) {
|
972 | GiteaProvider$Companion_getInstance();
|
973 | if (client === void 0)
|
974 | client = HttpClient();
|
975 | this.client = client;
|
976 | }
|
977 | function Coroutine$getUser_61zpoe$($this, str_0, continuation_0) {
|
978 | CoroutineImpl.call(this, continuation_0);
|
979 | this.exceptionState_0 = 6;
|
980 | this.$this = $this;
|
981 | this.local$response = void 0;
|
982 | this.local$str = str_0;
|
983 | }
|
984 | Coroutine$getUser_61zpoe$.$metadata$ = {
|
985 | kind: Kotlin.Kind.CLASS,
|
986 | simpleName: null,
|
987 | interfaces: [CoroutineImpl]
|
988 | };
|
989 | Coroutine$getUser_61zpoe$.prototype = Object.create(CoroutineImpl.prototype);
|
990 | Coroutine$getUser_61zpoe$.prototype.constructor = Coroutine$getUser_61zpoe$;
|
991 | Coroutine$getUser_61zpoe$.prototype.doResume = function () {
|
992 | do
|
993 | try {
|
994 | switch (this.state_0) {
|
995 | case 0:
|
996 | var $receiver_0 = this.$this.client;
|
997 | var urlString = 'api/v1/users/' + this.local$str;
|
998 | var host_0;
|
999 | var body_0;
|
1000 | host_0 = 'localhost';
|
1001 | body_0 = utils.EmptyContent;
|
1002 | var $receiver_1 = new HttpRequestBuilder_init();
|
1003 | url($receiver_1, 'http', host_0, 0, '/');
|
1004 | $receiver_1.method = HttpMethod.Companion.Get;
|
1005 | $receiver_1.body = body_0;
|
1006 | takeFrom($receiver_1.url, urlString);
|
1007 | get$lambda($receiver_1);
|
1008 | var $this_0 = new HttpStatement_init($receiver_1, $receiver_0);
|
1009 | var tmp$_4, tmp$_5, tmp$_6;
|
1010 | tmp$_4 = getKClass(GiteaUser);
|
1011 | if (equals(tmp$_4, getKClass(HttpStatement_init))) {
|
1012 | this.result_0 = (tmp$_5 = $this_0) == null || Kotlin.isType(tmp$_5, GiteaUser) ? tmp$_5 : throwCCE();
|
1013 | this.state_0 = 9;
|
1014 | continue;
|
1015 | } else {
|
1016 | if (equals(tmp$_4, getKClass(HttpResponse))) {
|
1017 | this.state_0 = 7;
|
1018 | this.result_0 = $this_0.execute(this);
|
1019 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1020 | return COROUTINE_SUSPENDED;
|
1021 | continue;
|
1022 | } else {
|
1023 | this.state_0 = 1;
|
1024 | this.result_0 = $this_0.executeUnsafe(this);
|
1025 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1026 | return COROUTINE_SUSPENDED;
|
1027 | continue;
|
1028 | }
|
1029 | }
|
1030 |
|
1031 | case 1:
|
1032 | this.local$response = this.result_0;
|
1033 | this.exceptionState_0 = 4;
|
1034 | var tmp$_7;
|
1035 | var tmp$_8 = this.local$response.call;
|
1036 | var typeInfo$result_0;
|
1037 | typeInfo$break: do {
|
1038 | try {
|
1039 | typeInfo$result_0 = new TypeInfo_init(getKClass(GiteaUser), call.JsType, createKType(getKClass(GiteaUser), [], true));
|
1040 | } catch (_) {
|
1041 | typeInfo$result_0 = new TypeInfo_init(getKClass(GiteaUser), call.JsType);
|
1042 | break typeInfo$break;
|
1043 | }
|
1044 | }
|
1045 | while (false);
|
1046 | this.state_0 = 2;
|
1047 | this.result_0 = tmp$_8.receive_jo9acv$(typeInfo$result_0, this);
|
1048 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1049 | return COROUTINE_SUSPENDED;
|
1050 | continue;
|
1051 | case 2:
|
1052 | this.result_0 = (tmp$_7 = this.result_0) == null || Kotlin.isType(tmp$_7, GiteaUser) ? tmp$_7 : throwCCE();
|
1053 | this.exceptionState_0 = 6;
|
1054 | this.finallyPath_0 = [3];
|
1055 | this.state_0 = 5;
|
1056 | continue;
|
1057 | case 3:
|
1058 | this.state_0 = 8;
|
1059 | continue;
|
1060 | case 4:
|
1061 | this.finallyPath_0 = [6];
|
1062 | this.state_0 = 5;
|
1063 | continue;
|
1064 | case 5:
|
1065 | this.exceptionState_0 = 6;
|
1066 | complete(this.local$response);
|
1067 | this.state_0 = this.finallyPath_0.shift();
|
1068 | continue;
|
1069 | case 6:
|
1070 | throw this.exception_0;
|
1071 | case 7:
|
1072 | this.result_0 = (tmp$_6 = this.result_0) == null || Kotlin.isType(tmp$_6, GiteaUser) ? tmp$_6 : throwCCE();
|
1073 | this.state_0 = 8;
|
1074 | continue;
|
1075 | case 8:
|
1076 | this.state_0 = 9;
|
1077 | continue;
|
1078 | case 9:
|
1079 | this.result_0;
|
1080 | return this.result_0;
|
1081 | default:this.state_0 = 6;
|
1082 | throw new Error('State Machine Unreachable execution');
|
1083 | }
|
1084 | } catch (e) {
|
1085 | if (this.state_0 === 6) {
|
1086 | this.exceptionState_0 = this.state_0;
|
1087 | throw e;
|
1088 | } else {
|
1089 | this.state_0 = this.exceptionState_0;
|
1090 | this.exception_0 = e;
|
1091 | }
|
1092 | }
|
1093 | while (true);
|
1094 | };
|
1095 | GiteaProvider.prototype.getUser_61zpoe$ = function (str_0, continuation_0, suspended) {
|
1096 | var instance = new Coroutine$getUser_61zpoe$(this, str_0, continuation_0);
|
1097 | if (suspended)
|
1098 | return instance;
|
1099 | else
|
1100 | return instance.doResume(null);
|
1101 | };
|
1102 | function Coroutine$getRepo_61zpoe$($this, str_0, continuation_0) {
|
1103 | CoroutineImpl.call(this, continuation_0);
|
1104 | this.exceptionState_0 = 6;
|
1105 | this.$this = $this;
|
1106 | this.local$response = void 0;
|
1107 | this.local$str = str_0;
|
1108 | }
|
1109 | Coroutine$getRepo_61zpoe$.$metadata$ = {
|
1110 | kind: Kotlin.Kind.CLASS,
|
1111 | simpleName: null,
|
1112 | interfaces: [CoroutineImpl]
|
1113 | };
|
1114 | Coroutine$getRepo_61zpoe$.prototype = Object.create(CoroutineImpl.prototype);
|
1115 | Coroutine$getRepo_61zpoe$.prototype.constructor = Coroutine$getRepo_61zpoe$;
|
1116 | Coroutine$getRepo_61zpoe$.prototype.doResume = function () {
|
1117 | do
|
1118 | try {
|
1119 | switch (this.state_0) {
|
1120 | case 0:
|
1121 | var $receiver_0 = this.$this.client;
|
1122 | var urlString = 'api/v1/repos/' + this.local$str;
|
1123 | var host_0;
|
1124 | var body_0;
|
1125 | host_0 = 'localhost';
|
1126 | body_0 = utils.EmptyContent;
|
1127 | var $receiver_1 = new HttpRequestBuilder_init();
|
1128 | url($receiver_1, 'http', host_0, 0, '/');
|
1129 | $receiver_1.method = HttpMethod.Companion.Get;
|
1130 | $receiver_1.body = body_0;
|
1131 | takeFrom($receiver_1.url, urlString);
|
1132 | get$lambda($receiver_1);
|
1133 | var $this_0 = new HttpStatement_init($receiver_1, $receiver_0);
|
1134 | var tmp$_4, tmp$_5, tmp$_6;
|
1135 | tmp$_4 = getKClass(GiteaRepo);
|
1136 | if (equals(tmp$_4, getKClass(HttpStatement_init))) {
|
1137 | this.result_0 = (tmp$_5 = $this_0) == null || Kotlin.isType(tmp$_5, GiteaRepo) ? tmp$_5 : throwCCE();
|
1138 | this.state_0 = 9;
|
1139 | continue;
|
1140 | } else {
|
1141 | if (equals(tmp$_4, getKClass(HttpResponse))) {
|
1142 | this.state_0 = 7;
|
1143 | this.result_0 = $this_0.execute(this);
|
1144 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1145 | return COROUTINE_SUSPENDED;
|
1146 | continue;
|
1147 | } else {
|
1148 | this.state_0 = 1;
|
1149 | this.result_0 = $this_0.executeUnsafe(this);
|
1150 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1151 | return COROUTINE_SUSPENDED;
|
1152 | continue;
|
1153 | }
|
1154 | }
|
1155 |
|
1156 | case 1:
|
1157 | this.local$response = this.result_0;
|
1158 | this.exceptionState_0 = 4;
|
1159 | var tmp$_7;
|
1160 | var tmp$_8 = this.local$response.call;
|
1161 | var typeInfo$result_0;
|
1162 | typeInfo$break: do {
|
1163 | try {
|
1164 | typeInfo$result_0 = new TypeInfo_init(getKClass(GiteaRepo), call.JsType, createKType(getKClass(GiteaRepo), [], true));
|
1165 | } catch (_) {
|
1166 | typeInfo$result_0 = new TypeInfo_init(getKClass(GiteaRepo), call.JsType);
|
1167 | break typeInfo$break;
|
1168 | }
|
1169 | }
|
1170 | while (false);
|
1171 | this.state_0 = 2;
|
1172 | this.result_0 = tmp$_8.receive_jo9acv$(typeInfo$result_0, this);
|
1173 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1174 | return COROUTINE_SUSPENDED;
|
1175 | continue;
|
1176 | case 2:
|
1177 | this.result_0 = (tmp$_7 = this.result_0) == null || Kotlin.isType(tmp$_7, GiteaRepo) ? tmp$_7 : throwCCE();
|
1178 | this.exceptionState_0 = 6;
|
1179 | this.finallyPath_0 = [3];
|
1180 | this.state_0 = 5;
|
1181 | continue;
|
1182 | case 3:
|
1183 | this.state_0 = 8;
|
1184 | continue;
|
1185 | case 4:
|
1186 | this.finallyPath_0 = [6];
|
1187 | this.state_0 = 5;
|
1188 | continue;
|
1189 | case 5:
|
1190 | this.exceptionState_0 = 6;
|
1191 | complete(this.local$response);
|
1192 | this.state_0 = this.finallyPath_0.shift();
|
1193 | continue;
|
1194 | case 6:
|
1195 | throw this.exception_0;
|
1196 | case 7:
|
1197 | this.result_0 = (tmp$_6 = this.result_0) == null || Kotlin.isType(tmp$_6, GiteaRepo) ? tmp$_6 : throwCCE();
|
1198 | this.state_0 = 8;
|
1199 | continue;
|
1200 | case 8:
|
1201 | this.state_0 = 9;
|
1202 | continue;
|
1203 | case 9:
|
1204 | this.result_0;
|
1205 | return this.result_0;
|
1206 | default:this.state_0 = 6;
|
1207 | throw new Error('State Machine Unreachable execution');
|
1208 | }
|
1209 | } catch (e) {
|
1210 | if (this.state_0 === 6) {
|
1211 | this.exceptionState_0 = this.state_0;
|
1212 | throw e;
|
1213 | } else {
|
1214 | this.state_0 = this.exceptionState_0;
|
1215 | this.exception_0 = e;
|
1216 | }
|
1217 | }
|
1218 | while (true);
|
1219 | };
|
1220 | GiteaProvider.prototype.getRepo_61zpoe$ = function (str_0, continuation_0, suspended) {
|
1221 | var instance = new Coroutine$getRepo_61zpoe$(this, str_0, continuation_0);
|
1222 | if (suspended)
|
1223 | return instance;
|
1224 | else
|
1225 | return instance.doResume(null);
|
1226 | };
|
1227 | function Coroutine$getRepoContributors_61zpoe$($this, str_0, continuation_0) {
|
1228 | CoroutineImpl.call(this, continuation_0);
|
1229 | this.exceptionState_0 = 6;
|
1230 | this.$this = $this;
|
1231 | this.local$response = void 0;
|
1232 | this.local$str = str_0;
|
1233 | }
|
1234 | Coroutine$getRepoContributors_61zpoe$.$metadata$ = {
|
1235 | kind: Kotlin.Kind.CLASS,
|
1236 | simpleName: null,
|
1237 | interfaces: [CoroutineImpl]
|
1238 | };
|
1239 | Coroutine$getRepoContributors_61zpoe$.prototype = Object.create(CoroutineImpl.prototype);
|
1240 | Coroutine$getRepoContributors_61zpoe$.prototype.constructor = Coroutine$getRepoContributors_61zpoe$;
|
1241 | Coroutine$getRepoContributors_61zpoe$.prototype.doResume = function () {
|
1242 | do
|
1243 | try {
|
1244 | switch (this.state_0) {
|
1245 | case 0:
|
1246 | var $receiver_0 = this.$this.client;
|
1247 | var urlString = 'api/v1/repos/' + this.local$str + '/collaborators';
|
1248 | var host_0;
|
1249 | var body_0;
|
1250 | host_0 = 'localhost';
|
1251 | body_0 = utils.EmptyContent;
|
1252 | var $receiver_1 = new HttpRequestBuilder_init();
|
1253 | url($receiver_1, 'http', host_0, 0, '/');
|
1254 | $receiver_1.method = HttpMethod.Companion.Get;
|
1255 | $receiver_1.body = body_0;
|
1256 | takeFrom($receiver_1.url, urlString);
|
1257 | get$lambda($receiver_1);
|
1258 | var $this_0 = new HttpStatement_init($receiver_1, $receiver_0);
|
1259 | var tmp$_4, tmp$_5, tmp$_6;
|
1260 | tmp$_4 = getKClass(List);
|
1261 | if (equals(tmp$_4, getKClass(HttpStatement_init))) {
|
1262 | this.result_0 = (tmp$_5 = $this_0) == null || Kotlin.isType(tmp$_5, List) ? tmp$_5 : throwCCE();
|
1263 | this.state_0 = 9;
|
1264 | continue;
|
1265 | } else {
|
1266 | if (equals(tmp$_4, getKClass(HttpResponse))) {
|
1267 | this.state_0 = 7;
|
1268 | this.result_0 = $this_0.execute(this);
|
1269 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1270 | return COROUTINE_SUSPENDED;
|
1271 | continue;
|
1272 | } else {
|
1273 | this.state_0 = 1;
|
1274 | this.result_0 = $this_0.executeUnsafe(this);
|
1275 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1276 | return COROUTINE_SUSPENDED;
|
1277 | continue;
|
1278 | }
|
1279 | }
|
1280 |
|
1281 | case 1:
|
1282 | this.local$response = this.result_0;
|
1283 | this.exceptionState_0 = 4;
|
1284 | var tmp$_7;
|
1285 | var tmp$_8 = this.local$response.call;
|
1286 | var typeInfo$result_0;
|
1287 | typeInfo$break: do {
|
1288 | try {
|
1289 | typeInfo$result_0 = new TypeInfo_init(getKClass(List), call.JsType, createKType(getKClass(List), [createInvariantKTypeProjection(createKType(getKClass(GiteaUser), [], false))], true));
|
1290 | } catch (_) {
|
1291 | typeInfo$result_0 = new TypeInfo_init(getKClass(List), call.JsType);
|
1292 | break typeInfo$break;
|
1293 | }
|
1294 | }
|
1295 | while (false);
|
1296 | this.state_0 = 2;
|
1297 | this.result_0 = tmp$_8.receive_jo9acv$(typeInfo$result_0, this);
|
1298 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1299 | return COROUTINE_SUSPENDED;
|
1300 | continue;
|
1301 | case 2:
|
1302 | this.result_0 = (tmp$_7 = this.result_0) == null || Kotlin.isType(tmp$_7, List) ? tmp$_7 : throwCCE();
|
1303 | this.exceptionState_0 = 6;
|
1304 | this.finallyPath_0 = [3];
|
1305 | this.state_0 = 5;
|
1306 | continue;
|
1307 | case 3:
|
1308 | this.state_0 = 8;
|
1309 | continue;
|
1310 | case 4:
|
1311 | this.finallyPath_0 = [6];
|
1312 | this.state_0 = 5;
|
1313 | continue;
|
1314 | case 5:
|
1315 | this.exceptionState_0 = 6;
|
1316 | complete(this.local$response);
|
1317 | this.state_0 = this.finallyPath_0.shift();
|
1318 | continue;
|
1319 | case 6:
|
1320 | throw this.exception_0;
|
1321 | case 7:
|
1322 | this.result_0 = (tmp$_6 = this.result_0) == null || Kotlin.isType(tmp$_6, List) ? tmp$_6 : throwCCE();
|
1323 | this.state_0 = 8;
|
1324 | continue;
|
1325 | case 8:
|
1326 | this.state_0 = 9;
|
1327 | continue;
|
1328 | case 9:
|
1329 | this.result_0;
|
1330 | return this.result_0;
|
1331 | default:this.state_0 = 6;
|
1332 | throw new Error('State Machine Unreachable execution');
|
1333 | }
|
1334 | } catch (e) {
|
1335 | if (this.state_0 === 6) {
|
1336 | this.exceptionState_0 = this.state_0;
|
1337 | throw e;
|
1338 | } else {
|
1339 | this.state_0 = this.exceptionState_0;
|
1340 | this.exception_0 = e;
|
1341 | }
|
1342 | }
|
1343 | while (true);
|
1344 | };
|
1345 | GiteaProvider.prototype.getRepoContributors_61zpoe$ = function (str_0, continuation_0, suspended) {
|
1346 | var instance = new Coroutine$getRepoContributors_61zpoe$(this, str_0, continuation_0);
|
1347 | if (suspended)
|
1348 | return instance;
|
1349 | else
|
1350 | return instance.doResume(null);
|
1351 | };
|
1352 | GiteaProvider.prototype.getLicense_61zpoe$ = function (str, continuation) {
|
1353 | return null;
|
1354 | };
|
1355 | function GiteaProvider$Companion() {
|
1356 | GiteaProvider$Companion_instance = this;
|
1357 | this.key_j3w2ca$_0 = 'gitea';
|
1358 | this.tokens_ce47l7$_0 = HashMap_init();
|
1359 | }
|
1360 | Object.defineProperty(GiteaProvider$Companion.prototype, 'key', {
|
1361 | configurable: true,
|
1362 | get: function () {
|
1363 | return this.key_j3w2ca$_0;
|
1364 | }
|
1365 | });
|
1366 | Object.defineProperty(GiteaProvider$Companion.prototype, 'tokens', {
|
1367 | configurable: true,
|
1368 | get: function () {
|
1369 | return this.tokens_ce47l7$_0;
|
1370 | }
|
1371 | });
|
1372 | function GiteaProvider$Companion$create$lambda$lambda$lambda(closure$hostname) {
|
1373 | return function ($receiver, it) {
|
1374 | $receiver.protocol = URLProtocol.Companion.HTTPS;
|
1375 | $receiver.host = closure$hostname;
|
1376 | return Unit;
|
1377 | };
|
1378 | }
|
1379 | function GiteaProvider$Companion$create$lambda$lambda(closure$hostname, this$GiteaProvider$) {
|
1380 | return function ($receiver) {
|
1381 | var tmp$;
|
1382 | $receiver.url_6yzzjr$(GiteaProvider$Companion$create$lambda$lambda$lambda(closure$hostname));
|
1383 | if ((tmp$ = this$GiteaProvider$.tokens.get_11rb$(closure$hostname)) != null) {
|
1384 | header($receiver, 'Authorization', 'token ' + tmp$);
|
1385 | }return Unit;
|
1386 | };
|
1387 | }
|
1388 | function GiteaProvider$Companion$create$lambda(closure$hostname, this$GiteaProvider$) {
|
1389 | return function ($receiver) {
|
1390 | defaultRequest($receiver, GiteaProvider$Companion$create$lambda$lambda(closure$hostname, this$GiteaProvider$));
|
1391 | return Unit;
|
1392 | };
|
1393 | }
|
1394 | GiteaProvider$Companion.prototype.create_wf0mc2$ = function (config, hostname) {
|
1395 | var client = this.ktor_1v6kay$(config, GiteaProvider$Companion$create$lambda(hostname, this));
|
1396 | return new GiteaProvider(client);
|
1397 | };
|
1398 | GiteaProvider$Companion.$metadata$ = {
|
1399 | kind: Kind_OBJECT,
|
1400 | simpleName: 'Companion',
|
1401 | interfaces: [ServiceBuilder]
|
1402 | };
|
1403 | var GiteaProvider$Companion_instance = null;
|
1404 | function GiteaProvider$Companion_getInstance() {
|
1405 | if (GiteaProvider$Companion_instance === null) {
|
1406 | new GiteaProvider$Companion();
|
1407 | }return GiteaProvider$Companion_instance;
|
1408 | }
|
1409 | GiteaProvider.$metadata$ = {
|
1410 | kind: Kind_CLASS,
|
1411 | simpleName: 'GiteaProvider',
|
1412 | interfaces: [RequestProvider]
|
1413 | };
|
1414 | function GiteaRepo() {
|
1415 | GiteaRepo$Companion_getInstance();
|
1416 | Repo.call(this);
|
1417 | this.id_gjulfy$_0 = '';
|
1418 | this.description_1u29ij$_0 = null;
|
1419 | this.url_fvc3fs$_0 = null;
|
1420 | this.websiteUrl_f1v89$_0 = null;
|
1421 | this.gitUrlHttp_ulw5qw$_0 = null;
|
1422 | this.gitUrlSsh_5kbq2s$_0 = null;
|
1423 | this.defaultBranch_frg4ck$_0 = null;
|
1424 | }
|
1425 | Object.defineProperty(GiteaRepo.prototype, 'id', {
|
1426 | configurable: true,
|
1427 | get: function () {
|
1428 | return this.id_gjulfy$_0;
|
1429 | },
|
1430 | set: function (id) {
|
1431 | this.id_gjulfy$_0 = id;
|
1432 | }
|
1433 | });
|
1434 | Object.defineProperty(GiteaRepo.prototype, 'description', {
|
1435 | configurable: true,
|
1436 | get: function () {
|
1437 | return this.description_1u29ij$_0;
|
1438 | }
|
1439 | });
|
1440 | Object.defineProperty(GiteaRepo.prototype, 'url', {
|
1441 | configurable: true,
|
1442 | get: function () {
|
1443 | return this.url_fvc3fs$_0;
|
1444 | }
|
1445 | });
|
1446 | Object.defineProperty(GiteaRepo.prototype, 'websiteUrl', {
|
1447 | configurable: true,
|
1448 | get: function () {
|
1449 | return this.websiteUrl_f1v89$_0;
|
1450 | }
|
1451 | });
|
1452 | Object.defineProperty(GiteaRepo.prototype, 'gitUrlHttp', {
|
1453 | configurable: true,
|
1454 | get: function () {
|
1455 | return this.gitUrlHttp_ulw5qw$_0;
|
1456 | }
|
1457 | });
|
1458 | Object.defineProperty(GiteaRepo.prototype, 'gitUrlSsh', {
|
1459 | configurable: true,
|
1460 | get: function () {
|
1461 | return this.gitUrlSsh_5kbq2s$_0;
|
1462 | }
|
1463 | });
|
1464 | Object.defineProperty(GiteaRepo.prototype, 'defaultBranch', {
|
1465 | configurable: true,
|
1466 | get: function () {
|
1467 | return this.defaultBranch_frg4ck$_0;
|
1468 | }
|
1469 | });
|
1470 | GiteaRepo.prototype.getRawFileUrl_puj7f4$$default = function (branchName, filePath) {
|
1471 | return toString(this.url) + '/raw/branch/' + branchName + '/' + filePath;
|
1472 | };
|
1473 | function GiteaRepo$Companion() {
|
1474 | GiteaRepo$Companion_instance = this;
|
1475 | }
|
1476 | GiteaRepo$Companion.prototype.serializer = function () {
|
1477 | return GiteaRepo$$serializer_getInstance();
|
1478 | };
|
1479 | GiteaRepo$Companion.$metadata$ = {
|
1480 | kind: Kind_OBJECT,
|
1481 | simpleName: 'Companion',
|
1482 | interfaces: []
|
1483 | };
|
1484 | var GiteaRepo$Companion_instance = null;
|
1485 | function GiteaRepo$Companion_getInstance() {
|
1486 | if (GiteaRepo$Companion_instance === null) {
|
1487 | new GiteaRepo$Companion();
|
1488 | }return GiteaRepo$Companion_instance;
|
1489 | }
|
1490 | function GiteaRepo$$serializer() {
|
1491 | this.descriptor_5gs2na$_0 = new PluginGeneratedSerialDescriptor('me.jfenn.gitrest.provider.gitea.model.GiteaRepo', this, 7);
|
1492 | this.descriptor.addElement_ivxn3r$('full_name', true);
|
1493 | this.descriptor.addElement_ivxn3r$('description', true);
|
1494 | this.descriptor.addElement_ivxn3r$('html_url', true);
|
1495 | this.descriptor.addElement_ivxn3r$('website', true);
|
1496 | this.descriptor.addElement_ivxn3r$('clone_url', true);
|
1497 | this.descriptor.addElement_ivxn3r$('ssh_url', true);
|
1498 | this.descriptor.addElement_ivxn3r$('default_branch', true);
|
1499 | GiteaRepo$$serializer_instance = this;
|
1500 | }
|
1501 | Object.defineProperty(GiteaRepo$$serializer.prototype, 'descriptor', {
|
1502 | configurable: true,
|
1503 | get: function () {
|
1504 | return this.descriptor_5gs2na$_0;
|
1505 | }
|
1506 | });
|
1507 | GiteaRepo$$serializer.prototype.serialize_55azsf$ = function (encoder, value) {
|
1508 | var output = encoder.beginStructure_24f42q$(this.descriptor);
|
1509 | if (!equals(value.id, '') || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 0))
|
1510 | output.encodeStringElement_iij8qq$(this.descriptor, 0, value.id);
|
1511 | if (!equals(value.description, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 1))
|
1512 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 1, new OptionalStringSerializer(), value.description);
|
1513 | if (!equals(value.url, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 2))
|
1514 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 2, internal.StringSerializer, value.url);
|
1515 | if (!equals(value.websiteUrl, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 3))
|
1516 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 3, new OptionalStringSerializer(), value.websiteUrl);
|
1517 | if (!equals(value.gitUrlHttp, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 4))
|
1518 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 4, internal.StringSerializer, value.gitUrlHttp);
|
1519 | if (!equals(value.gitUrlSsh, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 5))
|
1520 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 5, internal.StringSerializer, value.gitUrlSsh);
|
1521 | if (!equals(value.defaultBranch, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 6))
|
1522 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 6, internal.StringSerializer, value.defaultBranch);
|
1523 | output.endStructure_24f42q$(this.descriptor);
|
1524 | };
|
1525 | GiteaRepo$$serializer.prototype.deserialize_bq71mq$ = function (decoder) {
|
1526 | var index;
|
1527 | var bitMask0 = 0;
|
1528 | var local0
|
1529 | , local1
|
1530 | , local2
|
1531 | , local3
|
1532 | , local4
|
1533 | , local5
|
1534 | , local6;
|
1535 | var input = decoder.beginStructure_24f42q$(this.descriptor);
|
1536 | loopLabel: while (true) {
|
1537 | index = input.decodeElementIndex_24f42q$(this.descriptor);
|
1538 | switch (index) {
|
1539 | case 0:
|
1540 | local0 = input.decodeStringElement_szpzho$(this.descriptor, 0);
|
1541 | bitMask0 |= 1;
|
1542 | break;
|
1543 | case 1:
|
1544 | local1 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 1, new OptionalStringSerializer(), local1);
|
1545 | bitMask0 |= 2;
|
1546 | break;
|
1547 | case 2:
|
1548 | local2 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 2, internal.StringSerializer, local2);
|
1549 | bitMask0 |= 4;
|
1550 | break;
|
1551 | case 3:
|
1552 | local3 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 3, new OptionalStringSerializer(), local3);
|
1553 | bitMask0 |= 8;
|
1554 | break;
|
1555 | case 4:
|
1556 | local4 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 4, internal.StringSerializer, local4);
|
1557 | bitMask0 |= 16;
|
1558 | break;
|
1559 | case 5:
|
1560 | local5 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 5, internal.StringSerializer, local5);
|
1561 | bitMask0 |= 32;
|
1562 | break;
|
1563 | case 6:
|
1564 | local6 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 6, internal.StringSerializer, local6);
|
1565 | bitMask0 |= 64;
|
1566 | break;
|
1567 | case -1:
|
1568 | break loopLabel;
|
1569 | default:throw new UnknownFieldException(index);
|
1570 | }
|
1571 | }
|
1572 | input.endStructure_24f42q$(this.descriptor);
|
1573 | return GiteaRepo_init(bitMask0, local0, local1, local2, local3, local4, local5, local6, null);
|
1574 | };
|
1575 | GiteaRepo$$serializer.prototype.childSerializers = function () {
|
1576 | return [internal.StringSerializer, new NullableSerializer(new OptionalStringSerializer()), new NullableSerializer(internal.StringSerializer), new NullableSerializer(new OptionalStringSerializer()), new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer)];
|
1577 | };
|
1578 | GiteaRepo$$serializer.$metadata$ = {
|
1579 | kind: Kind_OBJECT,
|
1580 | simpleName: '$serializer',
|
1581 | interfaces: [GeneratedSerializer]
|
1582 | };
|
1583 | var GiteaRepo$$serializer_instance = null;
|
1584 | function GiteaRepo$$serializer_getInstance() {
|
1585 | if (GiteaRepo$$serializer_instance === null) {
|
1586 | new GiteaRepo$$serializer();
|
1587 | }return GiteaRepo$$serializer_instance;
|
1588 | }
|
1589 | function GiteaRepo_init(seen1, id, description, url, websiteUrl, gitUrlHttp, gitUrlSsh, defaultBranch, serializationConstructorMarker) {
|
1590 | var $this = serializationConstructorMarker || Object.create(GiteaRepo.prototype);
|
1591 | Repo.call($this);
|
1592 | if ((seen1 & 1) === 0)
|
1593 | $this.id_gjulfy$_0 = '';
|
1594 | else
|
1595 | $this.id_gjulfy$_0 = id;
|
1596 | if ((seen1 & 2) === 0)
|
1597 | $this.description_1u29ij$_0 = null;
|
1598 | else
|
1599 | $this.description_1u29ij$_0 = description;
|
1600 | if ((seen1 & 4) === 0)
|
1601 | $this.url_fvc3fs$_0 = null;
|
1602 | else
|
1603 | $this.url_fvc3fs$_0 = url;
|
1604 | if ((seen1 & 8) === 0)
|
1605 | $this.websiteUrl_f1v89$_0 = null;
|
1606 | else
|
1607 | $this.websiteUrl_f1v89$_0 = websiteUrl;
|
1608 | if ((seen1 & 16) === 0)
|
1609 | $this.gitUrlHttp_ulw5qw$_0 = null;
|
1610 | else
|
1611 | $this.gitUrlHttp_ulw5qw$_0 = gitUrlHttp;
|
1612 | if ((seen1 & 32) === 0)
|
1613 | $this.gitUrlSsh_5kbq2s$_0 = null;
|
1614 | else
|
1615 | $this.gitUrlSsh_5kbq2s$_0 = gitUrlSsh;
|
1616 | if ((seen1 & 64) === 0)
|
1617 | $this.defaultBranch_frg4ck$_0 = null;
|
1618 | else
|
1619 | $this.defaultBranch_frg4ck$_0 = defaultBranch;
|
1620 | return $this;
|
1621 | }
|
1622 | GiteaRepo.$metadata$ = {
|
1623 | kind: Kind_CLASS,
|
1624 | simpleName: 'GiteaRepo',
|
1625 | interfaces: [Repo]
|
1626 | };
|
1627 | function GiteaUser() {
|
1628 | GiteaUser$Companion_getInstance();
|
1629 | User.call(this);
|
1630 | this.id_dvpvlh$_0 = '';
|
1631 | this.name_e641gb$_0 = null;
|
1632 | this.avatarUrl_vjaj3c$_0 = null;
|
1633 | this.email_8zsb4i$_0 = null;
|
1634 | }
|
1635 | Object.defineProperty(GiteaUser.prototype, 'id', {
|
1636 | configurable: true,
|
1637 | get: function () {
|
1638 | return this.id_dvpvlh$_0;
|
1639 | },
|
1640 | set: function (id) {
|
1641 | this.id_dvpvlh$_0 = id;
|
1642 | }
|
1643 | });
|
1644 | Object.defineProperty(GiteaUser.prototype, 'name', {
|
1645 | configurable: true,
|
1646 | get: function () {
|
1647 | return this.name_e641gb$_0;
|
1648 | }
|
1649 | });
|
1650 | Object.defineProperty(GiteaUser.prototype, 'url', {
|
1651 | configurable: true,
|
1652 | get: function () {
|
1653 | return 'https://' + this.hostname + '/' + this.id;
|
1654 | }
|
1655 | });
|
1656 | Object.defineProperty(GiteaUser.prototype, 'avatarUrl', {
|
1657 | configurable: true,
|
1658 | get: function () {
|
1659 | return this.avatarUrl_vjaj3c$_0;
|
1660 | }
|
1661 | });
|
1662 | Object.defineProperty(GiteaUser.prototype, 'email', {
|
1663 | configurable: true,
|
1664 | get: function () {
|
1665 | return this.email_8zsb4i$_0;
|
1666 | }
|
1667 | });
|
1668 | function GiteaUser$Companion() {
|
1669 | GiteaUser$Companion_instance = this;
|
1670 | }
|
1671 | GiteaUser$Companion.prototype.serializer = function () {
|
1672 | return GiteaUser$$serializer_getInstance();
|
1673 | };
|
1674 | GiteaUser$Companion.$metadata$ = {
|
1675 | kind: Kind_OBJECT,
|
1676 | simpleName: 'Companion',
|
1677 | interfaces: []
|
1678 | };
|
1679 | var GiteaUser$Companion_instance = null;
|
1680 | function GiteaUser$Companion_getInstance() {
|
1681 | if (GiteaUser$Companion_instance === null) {
|
1682 | new GiteaUser$Companion();
|
1683 | }return GiteaUser$Companion_instance;
|
1684 | }
|
1685 | function GiteaUser$$serializer() {
|
1686 | this.descriptor_zagfup$_0 = new PluginGeneratedSerialDescriptor('me.jfenn.gitrest.provider.gitea.model.GiteaUser', this, 4);
|
1687 | this.descriptor.addElement_ivxn3r$('login', true);
|
1688 | this.descriptor.addElement_ivxn3r$('full_name', true);
|
1689 | this.descriptor.addElement_ivxn3r$('avatar_url', true);
|
1690 | this.descriptor.addElement_ivxn3r$('email', true);
|
1691 | GiteaUser$$serializer_instance = this;
|
1692 | }
|
1693 | Object.defineProperty(GiteaUser$$serializer.prototype, 'descriptor', {
|
1694 | configurable: true,
|
1695 | get: function () {
|
1696 | return this.descriptor_zagfup$_0;
|
1697 | }
|
1698 | });
|
1699 | GiteaUser$$serializer.prototype.serialize_55azsf$ = function (encoder, value) {
|
1700 | var output = encoder.beginStructure_24f42q$(this.descriptor);
|
1701 | if (!equals(value.id, '') || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 0))
|
1702 | output.encodeStringElement_iij8qq$(this.descriptor, 0, value.id);
|
1703 | if (!equals(value.name, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 1))
|
1704 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 1, new OptionalStringSerializer(), value.name);
|
1705 | if (!equals(value.avatarUrl, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 2))
|
1706 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 2, internal.StringSerializer, value.avatarUrl);
|
1707 | if (!equals(value.email, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 3))
|
1708 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 3, new OptionalStringSerializer(), value.email);
|
1709 | output.endStructure_24f42q$(this.descriptor);
|
1710 | };
|
1711 | GiteaUser$$serializer.prototype.deserialize_bq71mq$ = function (decoder) {
|
1712 | var index;
|
1713 | var bitMask0 = 0;
|
1714 | var local0
|
1715 | , local1
|
1716 | , local2
|
1717 | , local3;
|
1718 | var input = decoder.beginStructure_24f42q$(this.descriptor);
|
1719 | loopLabel: while (true) {
|
1720 | index = input.decodeElementIndex_24f42q$(this.descriptor);
|
1721 | switch (index) {
|
1722 | case 0:
|
1723 | local0 = input.decodeStringElement_szpzho$(this.descriptor, 0);
|
1724 | bitMask0 |= 1;
|
1725 | break;
|
1726 | case 1:
|
1727 | local1 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 1, new OptionalStringSerializer(), local1);
|
1728 | bitMask0 |= 2;
|
1729 | break;
|
1730 | case 2:
|
1731 | local2 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 2, internal.StringSerializer, local2);
|
1732 | bitMask0 |= 4;
|
1733 | break;
|
1734 | case 3:
|
1735 | local3 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 3, new OptionalStringSerializer(), local3);
|
1736 | bitMask0 |= 8;
|
1737 | break;
|
1738 | case -1:
|
1739 | break loopLabel;
|
1740 | default:throw new UnknownFieldException(index);
|
1741 | }
|
1742 | }
|
1743 | input.endStructure_24f42q$(this.descriptor);
|
1744 | return GiteaUser_init(bitMask0, local0, local1, local2, local3, null);
|
1745 | };
|
1746 | GiteaUser$$serializer.prototype.childSerializers = function () {
|
1747 | return [internal.StringSerializer, new NullableSerializer(new OptionalStringSerializer()), new NullableSerializer(internal.StringSerializer), new NullableSerializer(new OptionalStringSerializer())];
|
1748 | };
|
1749 | GiteaUser$$serializer.$metadata$ = {
|
1750 | kind: Kind_OBJECT,
|
1751 | simpleName: '$serializer',
|
1752 | interfaces: [GeneratedSerializer]
|
1753 | };
|
1754 | var GiteaUser$$serializer_instance = null;
|
1755 | function GiteaUser$$serializer_getInstance() {
|
1756 | if (GiteaUser$$serializer_instance === null) {
|
1757 | new GiteaUser$$serializer();
|
1758 | }return GiteaUser$$serializer_instance;
|
1759 | }
|
1760 | function GiteaUser_init(seen1, id, name, avatarUrl, email, serializationConstructorMarker) {
|
1761 | var $this = serializationConstructorMarker || Object.create(GiteaUser.prototype);
|
1762 | User.call($this);
|
1763 | if ((seen1 & 1) === 0)
|
1764 | $this.id_dvpvlh$_0 = '';
|
1765 | else
|
1766 | $this.id_dvpvlh$_0 = id;
|
1767 | if ((seen1 & 2) === 0)
|
1768 | $this.name_e641gb$_0 = null;
|
1769 | else
|
1770 | $this.name_e641gb$_0 = name;
|
1771 | if ((seen1 & 4) === 0)
|
1772 | $this.avatarUrl_vjaj3c$_0 = null;
|
1773 | else
|
1774 | $this.avatarUrl_vjaj3c$_0 = avatarUrl;
|
1775 | if ((seen1 & 8) === 0)
|
1776 | $this.email_8zsb4i$_0 = null;
|
1777 | else
|
1778 | $this.email_8zsb4i$_0 = email;
|
1779 | return $this;
|
1780 | }
|
1781 | GiteaUser.$metadata$ = {
|
1782 | kind: Kind_CLASS,
|
1783 | simpleName: 'GiteaUser',
|
1784 | interfaces: [User]
|
1785 | };
|
1786 | function get$lambda_0($receiver) {
|
1787 | return Unit;
|
1788 | }
|
1789 | function GithubProvider(client) {
|
1790 | GithubProvider$Companion_getInstance();
|
1791 | if (client === void 0)
|
1792 | client = HttpClient();
|
1793 | this.client = client;
|
1794 | }
|
1795 | function Coroutine$getUser_61zpoe$_0($this, str_0, continuation_0) {
|
1796 | CoroutineImpl.call(this, continuation_0);
|
1797 | this.exceptionState_0 = 6;
|
1798 | this.$this = $this;
|
1799 | this.local$response = void 0;
|
1800 | this.local$str = str_0;
|
1801 | }
|
1802 | Coroutine$getUser_61zpoe$_0.$metadata$ = {
|
1803 | kind: Kotlin.Kind.CLASS,
|
1804 | simpleName: null,
|
1805 | interfaces: [CoroutineImpl]
|
1806 | };
|
1807 | Coroutine$getUser_61zpoe$_0.prototype = Object.create(CoroutineImpl.prototype);
|
1808 | Coroutine$getUser_61zpoe$_0.prototype.constructor = Coroutine$getUser_61zpoe$_0;
|
1809 | Coroutine$getUser_61zpoe$_0.prototype.doResume = function () {
|
1810 | do
|
1811 | try {
|
1812 | switch (this.state_0) {
|
1813 | case 0:
|
1814 | var $receiver_0 = this.$this.client;
|
1815 | var urlString = 'users/' + this.local$str;
|
1816 | var host_0;
|
1817 | var body_0;
|
1818 | host_0 = 'localhost';
|
1819 | body_0 = utils.EmptyContent;
|
1820 | var $receiver_1 = new HttpRequestBuilder_init();
|
1821 | url($receiver_1, 'http', host_0, 0, '/');
|
1822 | $receiver_1.method = HttpMethod.Companion.Get;
|
1823 | $receiver_1.body = body_0;
|
1824 | takeFrom($receiver_1.url, urlString);
|
1825 | get$lambda_0($receiver_1);
|
1826 | var $this_0 = new HttpStatement_init($receiver_1, $receiver_0);
|
1827 | var tmp$_4, tmp$_5, tmp$_6;
|
1828 | tmp$_4 = getKClass(GithubUser);
|
1829 | if (equals(tmp$_4, getKClass(HttpStatement_init))) {
|
1830 | this.result_0 = (tmp$_5 = $this_0) == null || Kotlin.isType(tmp$_5, GithubUser) ? tmp$_5 : throwCCE();
|
1831 | this.state_0 = 9;
|
1832 | continue;
|
1833 | } else {
|
1834 | if (equals(tmp$_4, getKClass(HttpResponse))) {
|
1835 | this.state_0 = 7;
|
1836 | this.result_0 = $this_0.execute(this);
|
1837 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1838 | return COROUTINE_SUSPENDED;
|
1839 | continue;
|
1840 | } else {
|
1841 | this.state_0 = 1;
|
1842 | this.result_0 = $this_0.executeUnsafe(this);
|
1843 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1844 | return COROUTINE_SUSPENDED;
|
1845 | continue;
|
1846 | }
|
1847 | }
|
1848 |
|
1849 | case 1:
|
1850 | this.local$response = this.result_0;
|
1851 | this.exceptionState_0 = 4;
|
1852 | var tmp$_7;
|
1853 | var tmp$_8 = this.local$response.call;
|
1854 | var typeInfo$result_0;
|
1855 | typeInfo$break: do {
|
1856 | try {
|
1857 | typeInfo$result_0 = new TypeInfo_init(getKClass(GithubUser), call.JsType, createKType(getKClass(GithubUser), [], true));
|
1858 | } catch (_) {
|
1859 | typeInfo$result_0 = new TypeInfo_init(getKClass(GithubUser), call.JsType);
|
1860 | break typeInfo$break;
|
1861 | }
|
1862 | }
|
1863 | while (false);
|
1864 | this.state_0 = 2;
|
1865 | this.result_0 = tmp$_8.receive_jo9acv$(typeInfo$result_0, this);
|
1866 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1867 | return COROUTINE_SUSPENDED;
|
1868 | continue;
|
1869 | case 2:
|
1870 | this.result_0 = (tmp$_7 = this.result_0) == null || Kotlin.isType(tmp$_7, GithubUser) ? tmp$_7 : throwCCE();
|
1871 | this.exceptionState_0 = 6;
|
1872 | this.finallyPath_0 = [3];
|
1873 | this.state_0 = 5;
|
1874 | continue;
|
1875 | case 3:
|
1876 | this.state_0 = 8;
|
1877 | continue;
|
1878 | case 4:
|
1879 | this.finallyPath_0 = [6];
|
1880 | this.state_0 = 5;
|
1881 | continue;
|
1882 | case 5:
|
1883 | this.exceptionState_0 = 6;
|
1884 | complete(this.local$response);
|
1885 | this.state_0 = this.finallyPath_0.shift();
|
1886 | continue;
|
1887 | case 6:
|
1888 | throw this.exception_0;
|
1889 | case 7:
|
1890 | this.result_0 = (tmp$_6 = this.result_0) == null || Kotlin.isType(tmp$_6, GithubUser) ? tmp$_6 : throwCCE();
|
1891 | this.state_0 = 8;
|
1892 | continue;
|
1893 | case 8:
|
1894 | this.state_0 = 9;
|
1895 | continue;
|
1896 | case 9:
|
1897 | this.result_0;
|
1898 | return this.result_0;
|
1899 | default:this.state_0 = 6;
|
1900 | throw new Error('State Machine Unreachable execution');
|
1901 | }
|
1902 | } catch (e) {
|
1903 | if (this.state_0 === 6) {
|
1904 | this.exceptionState_0 = this.state_0;
|
1905 | throw e;
|
1906 | } else {
|
1907 | this.state_0 = this.exceptionState_0;
|
1908 | this.exception_0 = e;
|
1909 | }
|
1910 | }
|
1911 | while (true);
|
1912 | };
|
1913 | GithubProvider.prototype.getUser_61zpoe$ = function (str_0, continuation_0, suspended) {
|
1914 | var instance = new Coroutine$getUser_61zpoe$_0(this, str_0, continuation_0);
|
1915 | if (suspended)
|
1916 | return instance;
|
1917 | else
|
1918 | return instance.doResume(null);
|
1919 | };
|
1920 | function Coroutine$getRepo_61zpoe$_0($this, str_0, continuation_0) {
|
1921 | CoroutineImpl.call(this, continuation_0);
|
1922 | this.exceptionState_0 = 6;
|
1923 | this.$this = $this;
|
1924 | this.local$response = void 0;
|
1925 | this.local$str = str_0;
|
1926 | }
|
1927 | Coroutine$getRepo_61zpoe$_0.$metadata$ = {
|
1928 | kind: Kotlin.Kind.CLASS,
|
1929 | simpleName: null,
|
1930 | interfaces: [CoroutineImpl]
|
1931 | };
|
1932 | Coroutine$getRepo_61zpoe$_0.prototype = Object.create(CoroutineImpl.prototype);
|
1933 | Coroutine$getRepo_61zpoe$_0.prototype.constructor = Coroutine$getRepo_61zpoe$_0;
|
1934 | Coroutine$getRepo_61zpoe$_0.prototype.doResume = function () {
|
1935 | do
|
1936 | try {
|
1937 | switch (this.state_0) {
|
1938 | case 0:
|
1939 | var $receiver_0 = this.$this.client;
|
1940 | var urlString = 'repos/' + this.local$str;
|
1941 | var host_0;
|
1942 | var body_0;
|
1943 | host_0 = 'localhost';
|
1944 | body_0 = utils.EmptyContent;
|
1945 | var $receiver_1 = new HttpRequestBuilder_init();
|
1946 | url($receiver_1, 'http', host_0, 0, '/');
|
1947 | $receiver_1.method = HttpMethod.Companion.Get;
|
1948 | $receiver_1.body = body_0;
|
1949 | takeFrom($receiver_1.url, urlString);
|
1950 | get$lambda_0($receiver_1);
|
1951 | var $this_0 = new HttpStatement_init($receiver_1, $receiver_0);
|
1952 | var tmp$_4, tmp$_5, tmp$_6;
|
1953 | tmp$_4 = getKClass(GithubRepo);
|
1954 | if (equals(tmp$_4, getKClass(HttpStatement_init))) {
|
1955 | this.result_0 = (tmp$_5 = $this_0) == null || Kotlin.isType(tmp$_5, GithubRepo) ? tmp$_5 : throwCCE();
|
1956 | this.state_0 = 9;
|
1957 | continue;
|
1958 | } else {
|
1959 | if (equals(tmp$_4, getKClass(HttpResponse))) {
|
1960 | this.state_0 = 7;
|
1961 | this.result_0 = $this_0.execute(this);
|
1962 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1963 | return COROUTINE_SUSPENDED;
|
1964 | continue;
|
1965 | } else {
|
1966 | this.state_0 = 1;
|
1967 | this.result_0 = $this_0.executeUnsafe(this);
|
1968 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1969 | return COROUTINE_SUSPENDED;
|
1970 | continue;
|
1971 | }
|
1972 | }
|
1973 |
|
1974 | case 1:
|
1975 | this.local$response = this.result_0;
|
1976 | this.exceptionState_0 = 4;
|
1977 | var tmp$_7;
|
1978 | var tmp$_8 = this.local$response.call;
|
1979 | var typeInfo$result_0;
|
1980 | typeInfo$break: do {
|
1981 | try {
|
1982 | typeInfo$result_0 = new TypeInfo_init(getKClass(GithubRepo), call.JsType, createKType(getKClass(GithubRepo), [], true));
|
1983 | } catch (_) {
|
1984 | typeInfo$result_0 = new TypeInfo_init(getKClass(GithubRepo), call.JsType);
|
1985 | break typeInfo$break;
|
1986 | }
|
1987 | }
|
1988 | while (false);
|
1989 | this.state_0 = 2;
|
1990 | this.result_0 = tmp$_8.receive_jo9acv$(typeInfo$result_0, this);
|
1991 | if (this.result_0 === COROUTINE_SUSPENDED)
|
1992 | return COROUTINE_SUSPENDED;
|
1993 | continue;
|
1994 | case 2:
|
1995 | this.result_0 = (tmp$_7 = this.result_0) == null || Kotlin.isType(tmp$_7, GithubRepo) ? tmp$_7 : throwCCE();
|
1996 | this.exceptionState_0 = 6;
|
1997 | this.finallyPath_0 = [3];
|
1998 | this.state_0 = 5;
|
1999 | continue;
|
2000 | case 3:
|
2001 | this.state_0 = 8;
|
2002 | continue;
|
2003 | case 4:
|
2004 | this.finallyPath_0 = [6];
|
2005 | this.state_0 = 5;
|
2006 | continue;
|
2007 | case 5:
|
2008 | this.exceptionState_0 = 6;
|
2009 | complete(this.local$response);
|
2010 | this.state_0 = this.finallyPath_0.shift();
|
2011 | continue;
|
2012 | case 6:
|
2013 | throw this.exception_0;
|
2014 | case 7:
|
2015 | this.result_0 = (tmp$_6 = this.result_0) == null || Kotlin.isType(tmp$_6, GithubRepo) ? tmp$_6 : throwCCE();
|
2016 | this.state_0 = 8;
|
2017 | continue;
|
2018 | case 8:
|
2019 | this.state_0 = 9;
|
2020 | continue;
|
2021 | case 9:
|
2022 | this.result_0;
|
2023 | return this.result_0;
|
2024 | default:this.state_0 = 6;
|
2025 | throw new Error('State Machine Unreachable execution');
|
2026 | }
|
2027 | } catch (e) {
|
2028 | if (this.state_0 === 6) {
|
2029 | this.exceptionState_0 = this.state_0;
|
2030 | throw e;
|
2031 | } else {
|
2032 | this.state_0 = this.exceptionState_0;
|
2033 | this.exception_0 = e;
|
2034 | }
|
2035 | }
|
2036 | while (true);
|
2037 | };
|
2038 | GithubProvider.prototype.getRepo_61zpoe$ = function (str_0, continuation_0, suspended) {
|
2039 | var instance = new Coroutine$getRepo_61zpoe$_0(this, str_0, continuation_0);
|
2040 | if (suspended)
|
2041 | return instance;
|
2042 | else
|
2043 | return instance.doResume(null);
|
2044 | };
|
2045 | function Coroutine$getRepoContributors_61zpoe$_0($this, str_0, continuation_0) {
|
2046 | CoroutineImpl.call(this, continuation_0);
|
2047 | this.exceptionState_0 = 6;
|
2048 | this.$this = $this;
|
2049 | this.local$response = void 0;
|
2050 | this.local$str = str_0;
|
2051 | }
|
2052 | Coroutine$getRepoContributors_61zpoe$_0.$metadata$ = {
|
2053 | kind: Kotlin.Kind.CLASS,
|
2054 | simpleName: null,
|
2055 | interfaces: [CoroutineImpl]
|
2056 | };
|
2057 | Coroutine$getRepoContributors_61zpoe$_0.prototype = Object.create(CoroutineImpl.prototype);
|
2058 | Coroutine$getRepoContributors_61zpoe$_0.prototype.constructor = Coroutine$getRepoContributors_61zpoe$_0;
|
2059 | Coroutine$getRepoContributors_61zpoe$_0.prototype.doResume = function () {
|
2060 | do
|
2061 | try {
|
2062 | switch (this.state_0) {
|
2063 | case 0:
|
2064 | var $receiver_0 = this.$this.client;
|
2065 | var urlString = 'repos/' + this.local$str + '/contributors';
|
2066 | var host_0;
|
2067 | var body_0;
|
2068 | host_0 = 'localhost';
|
2069 | body_0 = utils.EmptyContent;
|
2070 | var $receiver_1 = new HttpRequestBuilder_init();
|
2071 | url($receiver_1, 'http', host_0, 0, '/');
|
2072 | $receiver_1.method = HttpMethod.Companion.Get;
|
2073 | $receiver_1.body = body_0;
|
2074 | takeFrom($receiver_1.url, urlString);
|
2075 | get$lambda_0($receiver_1);
|
2076 | var $this_0 = new HttpStatement_init($receiver_1, $receiver_0);
|
2077 | var tmp$_4, tmp$_5, tmp$_6;
|
2078 | tmp$_4 = getKClass(List);
|
2079 | if (equals(tmp$_4, getKClass(HttpStatement_init))) {
|
2080 | this.result_0 = (tmp$_5 = $this_0) == null || Kotlin.isType(tmp$_5, List) ? tmp$_5 : throwCCE();
|
2081 | this.state_0 = 9;
|
2082 | continue;
|
2083 | } else {
|
2084 | if (equals(tmp$_4, getKClass(HttpResponse))) {
|
2085 | this.state_0 = 7;
|
2086 | this.result_0 = $this_0.execute(this);
|
2087 | if (this.result_0 === COROUTINE_SUSPENDED)
|
2088 | return COROUTINE_SUSPENDED;
|
2089 | continue;
|
2090 | } else {
|
2091 | this.state_0 = 1;
|
2092 | this.result_0 = $this_0.executeUnsafe(this);
|
2093 | if (this.result_0 === COROUTINE_SUSPENDED)
|
2094 | return COROUTINE_SUSPENDED;
|
2095 | continue;
|
2096 | }
|
2097 | }
|
2098 |
|
2099 | case 1:
|
2100 | this.local$response = this.result_0;
|
2101 | this.exceptionState_0 = 4;
|
2102 | var tmp$_7;
|
2103 | var tmp$_8 = this.local$response.call;
|
2104 | var typeInfo$result_0;
|
2105 | typeInfo$break: do {
|
2106 | try {
|
2107 | typeInfo$result_0 = new TypeInfo_init(getKClass(List), call.JsType, createKType(getKClass(List), [createInvariantKTypeProjection(createKType(getKClass(GithubUser), [], false))], true));
|
2108 | } catch (_) {
|
2109 | typeInfo$result_0 = new TypeInfo_init(getKClass(List), call.JsType);
|
2110 | break typeInfo$break;
|
2111 | }
|
2112 | }
|
2113 | while (false);
|
2114 | this.state_0 = 2;
|
2115 | this.result_0 = tmp$_8.receive_jo9acv$(typeInfo$result_0, this);
|
2116 | if (this.result_0 === COROUTINE_SUSPENDED)
|
2117 | return COROUTINE_SUSPENDED;
|
2118 | continue;
|
2119 | case 2:
|
2120 | this.result_0 = (tmp$_7 = this.result_0) == null || Kotlin.isType(tmp$_7, List) ? tmp$_7 : throwCCE();
|
2121 | this.exceptionState_0 = 6;
|
2122 | this.finallyPath_0 = [3];
|
2123 | this.state_0 = 5;
|
2124 | continue;
|
2125 | case 3:
|
2126 | this.state_0 = 8;
|
2127 | continue;
|
2128 | case 4:
|
2129 | this.finallyPath_0 = [6];
|
2130 | this.state_0 = 5;
|
2131 | continue;
|
2132 | case 5:
|
2133 | this.exceptionState_0 = 6;
|
2134 | complete(this.local$response);
|
2135 | this.state_0 = this.finallyPath_0.shift();
|
2136 | continue;
|
2137 | case 6:
|
2138 | throw this.exception_0;
|
2139 | case 7:
|
2140 | this.result_0 = (tmp$_6 = this.result_0) == null || Kotlin.isType(tmp$_6, List) ? tmp$_6 : throwCCE();
|
2141 | this.state_0 = 8;
|
2142 | continue;
|
2143 | case 8:
|
2144 | this.state_0 = 9;
|
2145 | continue;
|
2146 | case 9:
|
2147 | this.result_0;
|
2148 | return this.result_0;
|
2149 | default:this.state_0 = 6;
|
2150 | throw new Error('State Machine Unreachable execution');
|
2151 | }
|
2152 | } catch (e) {
|
2153 | if (this.state_0 === 6) {
|
2154 | this.exceptionState_0 = this.state_0;
|
2155 | throw e;
|
2156 | } else {
|
2157 | this.state_0 = this.exceptionState_0;
|
2158 | this.exception_0 = e;
|
2159 | }
|
2160 | }
|
2161 | while (true);
|
2162 | };
|
2163 | GithubProvider.prototype.getRepoContributors_61zpoe$ = function (str_0, continuation_0, suspended) {
|
2164 | var instance = new Coroutine$getRepoContributors_61zpoe$_0(this, str_0, continuation_0);
|
2165 | if (suspended)
|
2166 | return instance;
|
2167 | else
|
2168 | return instance.doResume(null);
|
2169 | };
|
2170 | function Coroutine$getLicense_61zpoe$($this, str_0, continuation_0) {
|
2171 | CoroutineImpl.call(this, continuation_0);
|
2172 | this.exceptionState_0 = 6;
|
2173 | this.$this = $this;
|
2174 | this.local$response = void 0;
|
2175 | this.local$str = str_0;
|
2176 | }
|
2177 | Coroutine$getLicense_61zpoe$.$metadata$ = {
|
2178 | kind: Kotlin.Kind.CLASS,
|
2179 | simpleName: null,
|
2180 | interfaces: [CoroutineImpl]
|
2181 | };
|
2182 | Coroutine$getLicense_61zpoe$.prototype = Object.create(CoroutineImpl.prototype);
|
2183 | Coroutine$getLicense_61zpoe$.prototype.constructor = Coroutine$getLicense_61zpoe$;
|
2184 | Coroutine$getLicense_61zpoe$.prototype.doResume = function () {
|
2185 | do
|
2186 | try {
|
2187 | switch (this.state_0) {
|
2188 | case 0:
|
2189 | var $receiver_0 = this.$this.client;
|
2190 | var urlString = 'licenses/' + this.local$str;
|
2191 | var host_0;
|
2192 | var body_0;
|
2193 | host_0 = 'localhost';
|
2194 | body_0 = utils.EmptyContent;
|
2195 | var $receiver_1 = new HttpRequestBuilder_init();
|
2196 | url($receiver_1, 'http', host_0, 0, '/');
|
2197 | $receiver_1.method = HttpMethod.Companion.Get;
|
2198 | $receiver_1.body = body_0;
|
2199 | takeFrom($receiver_1.url, urlString);
|
2200 | get$lambda_0($receiver_1);
|
2201 | var $this_0 = new HttpStatement_init($receiver_1, $receiver_0);
|
2202 | var tmp$_4, tmp$_5, tmp$_6;
|
2203 | tmp$_4 = getKClass(GithubLicense);
|
2204 | if (equals(tmp$_4, getKClass(HttpStatement_init))) {
|
2205 | this.result_0 = (tmp$_5 = $this_0) == null || Kotlin.isType(tmp$_5, GithubLicense) ? tmp$_5 : throwCCE();
|
2206 | this.state_0 = 9;
|
2207 | continue;
|
2208 | } else {
|
2209 | if (equals(tmp$_4, getKClass(HttpResponse))) {
|
2210 | this.state_0 = 7;
|
2211 | this.result_0 = $this_0.execute(this);
|
2212 | if (this.result_0 === COROUTINE_SUSPENDED)
|
2213 | return COROUTINE_SUSPENDED;
|
2214 | continue;
|
2215 | } else {
|
2216 | this.state_0 = 1;
|
2217 | this.result_0 = $this_0.executeUnsafe(this);
|
2218 | if (this.result_0 === COROUTINE_SUSPENDED)
|
2219 | return COROUTINE_SUSPENDED;
|
2220 | continue;
|
2221 | }
|
2222 | }
|
2223 |
|
2224 | case 1:
|
2225 | this.local$response = this.result_0;
|
2226 | this.exceptionState_0 = 4;
|
2227 | var tmp$_7;
|
2228 | var tmp$_8 = this.local$response.call;
|
2229 | var typeInfo$result_0;
|
2230 | typeInfo$break: do {
|
2231 | try {
|
2232 | typeInfo$result_0 = new TypeInfo_init(getKClass(GithubLicense), call.JsType, createKType(getKClass(GithubLicense), [], true));
|
2233 | } catch (_) {
|
2234 | typeInfo$result_0 = new TypeInfo_init(getKClass(GithubLicense), call.JsType);
|
2235 | break typeInfo$break;
|
2236 | }
|
2237 | }
|
2238 | while (false);
|
2239 | this.state_0 = 2;
|
2240 | this.result_0 = tmp$_8.receive_jo9acv$(typeInfo$result_0, this);
|
2241 | if (this.result_0 === COROUTINE_SUSPENDED)
|
2242 | return COROUTINE_SUSPENDED;
|
2243 | continue;
|
2244 | case 2:
|
2245 | this.result_0 = (tmp$_7 = this.result_0) == null || Kotlin.isType(tmp$_7, GithubLicense) ? tmp$_7 : throwCCE();
|
2246 | this.exceptionState_0 = 6;
|
2247 | this.finallyPath_0 = [3];
|
2248 | this.state_0 = 5;
|
2249 | continue;
|
2250 | case 3:
|
2251 | this.state_0 = 8;
|
2252 | continue;
|
2253 | case 4:
|
2254 | this.finallyPath_0 = [6];
|
2255 | this.state_0 = 5;
|
2256 | continue;
|
2257 | case 5:
|
2258 | this.exceptionState_0 = 6;
|
2259 | complete(this.local$response);
|
2260 | this.state_0 = this.finallyPath_0.shift();
|
2261 | continue;
|
2262 | case 6:
|
2263 | throw this.exception_0;
|
2264 | case 7:
|
2265 | this.result_0 = (tmp$_6 = this.result_0) == null || Kotlin.isType(tmp$_6, GithubLicense) ? tmp$_6 : throwCCE();
|
2266 | this.state_0 = 8;
|
2267 | continue;
|
2268 | case 8:
|
2269 | this.state_0 = 9;
|
2270 | continue;
|
2271 | case 9:
|
2272 | this.result_0;
|
2273 | return this.result_0;
|
2274 | default:this.state_0 = 6;
|
2275 | throw new Error('State Machine Unreachable execution');
|
2276 | }
|
2277 | } catch (e) {
|
2278 | if (this.state_0 === 6) {
|
2279 | this.exceptionState_0 = this.state_0;
|
2280 | throw e;
|
2281 | } else {
|
2282 | this.state_0 = this.exceptionState_0;
|
2283 | this.exception_0 = e;
|
2284 | }
|
2285 | }
|
2286 | while (true);
|
2287 | };
|
2288 | GithubProvider.prototype.getLicense_61zpoe$ = function (str_0, continuation_0, suspended) {
|
2289 | var instance = new Coroutine$getLicense_61zpoe$(this, str_0, continuation_0);
|
2290 | if (suspended)
|
2291 | return instance;
|
2292 | else
|
2293 | return instance.doResume(null);
|
2294 | };
|
2295 | function GithubProvider$Companion() {
|
2296 | GithubProvider$Companion_instance = this;
|
2297 | this.key_n7o64m$_0 = 'github';
|
2298 | this.tokens_l15paj$_0 = HashMap_init();
|
2299 | }
|
2300 | Object.defineProperty(GithubProvider$Companion.prototype, 'key', {
|
2301 | configurable: true,
|
2302 | get: function () {
|
2303 | return this.key_n7o64m$_0;
|
2304 | }
|
2305 | });
|
2306 | Object.defineProperty(GithubProvider$Companion.prototype, 'tokens', {
|
2307 | configurable: true,
|
2308 | get: function () {
|
2309 | return this.tokens_l15paj$_0;
|
2310 | }
|
2311 | });
|
2312 | function GithubProvider$Companion$create$lambda$lambda$lambda(closure$hostname) {
|
2313 | return function ($receiver, it) {
|
2314 | $receiver.protocol = URLProtocol.Companion.HTTPS;
|
2315 | $receiver.host = closure$hostname;
|
2316 | return Unit;
|
2317 | };
|
2318 | }
|
2319 | function GithubProvider$Companion$create$lambda$lambda(closure$hostname, this$GithubProvider$) {
|
2320 | return function ($receiver) {
|
2321 | var tmp$;
|
2322 | $receiver.url_6yzzjr$(GithubProvider$Companion$create$lambda$lambda$lambda(closure$hostname));
|
2323 | header($receiver, 'Accept', 'application/vnd.github.v3+json');
|
2324 | if ((tmp$ = this$GithubProvider$.tokens.get_11rb$(closure$hostname)) != null) {
|
2325 | header($receiver, 'Authorization', 'token ' + tmp$);
|
2326 | }return Unit;
|
2327 | };
|
2328 | }
|
2329 | function GithubProvider$Companion$create$lambda(closure$hostname, this$GithubProvider$) {
|
2330 | return function ($receiver) {
|
2331 | defaultRequest($receiver, GithubProvider$Companion$create$lambda$lambda(closure$hostname, this$GithubProvider$));
|
2332 | return Unit;
|
2333 | };
|
2334 | }
|
2335 | GithubProvider$Companion.prototype.create_wf0mc2$ = function (config, hostname) {
|
2336 | var client = this.ktor_1v6kay$(config, GithubProvider$Companion$create$lambda(hostname, this));
|
2337 | return new GithubProvider(client);
|
2338 | };
|
2339 | GithubProvider$Companion.$metadata$ = {
|
2340 | kind: Kind_OBJECT,
|
2341 | simpleName: 'Companion',
|
2342 | interfaces: [ServiceBuilder]
|
2343 | };
|
2344 | var GithubProvider$Companion_instance = null;
|
2345 | function GithubProvider$Companion_getInstance() {
|
2346 | if (GithubProvider$Companion_instance === null) {
|
2347 | new GithubProvider$Companion();
|
2348 | }return GithubProvider$Companion_instance;
|
2349 | }
|
2350 | GithubProvider.$metadata$ = {
|
2351 | kind: Kind_CLASS,
|
2352 | simpleName: 'GithubProvider',
|
2353 | interfaces: [RequestProvider]
|
2354 | };
|
2355 | function GithubLicense() {
|
2356 | GithubLicense$Companion_getInstance();
|
2357 | License.call(this);
|
2358 | this.id_apklj$_0 = '';
|
2359 | this.name_1pgghj$_0 = null;
|
2360 | this.description_b2yzgc$_0 = null;
|
2361 | this.body_1vt7zi$_0 = null;
|
2362 | this.infoUrl_qv4jsx$_0 = null;
|
2363 | this.permissions_xocwak$_0 = null;
|
2364 | this.conditions_ycdnyc$_0 = null;
|
2365 | this.limitations_odm3uv$_0 = null;
|
2366 | }
|
2367 | Object.defineProperty(GithubLicense.prototype, 'id', {
|
2368 | configurable: true,
|
2369 | get: function () {
|
2370 | return this.id_apklj$_0;
|
2371 | },
|
2372 | set: function (id) {
|
2373 | this.id_apklj$_0 = id;
|
2374 | }
|
2375 | });
|
2376 | Object.defineProperty(GithubLicense.prototype, 'name', {
|
2377 | configurable: true,
|
2378 | get: function () {
|
2379 | return this.name_1pgghj$_0;
|
2380 | }
|
2381 | });
|
2382 | Object.defineProperty(GithubLicense.prototype, 'description', {
|
2383 | configurable: true,
|
2384 | get: function () {
|
2385 | return this.description_b2yzgc$_0;
|
2386 | }
|
2387 | });
|
2388 | Object.defineProperty(GithubLicense.prototype, 'body', {
|
2389 | configurable: true,
|
2390 | get: function () {
|
2391 | return this.body_1vt7zi$_0;
|
2392 | }
|
2393 | });
|
2394 | Object.defineProperty(GithubLicense.prototype, 'infoUrl', {
|
2395 | configurable: true,
|
2396 | get: function () {
|
2397 | return this.infoUrl_qv4jsx$_0;
|
2398 | }
|
2399 | });
|
2400 | Object.defineProperty(GithubLicense.prototype, 'permissions', {
|
2401 | configurable: true,
|
2402 | get: function () {
|
2403 | return this.permissions_xocwak$_0;
|
2404 | }
|
2405 | });
|
2406 | Object.defineProperty(GithubLicense.prototype, 'conditions', {
|
2407 | configurable: true,
|
2408 | get: function () {
|
2409 | return this.conditions_ycdnyc$_0;
|
2410 | }
|
2411 | });
|
2412 | Object.defineProperty(GithubLicense.prototype, 'limitations', {
|
2413 | configurable: true,
|
2414 | get: function () {
|
2415 | return this.limitations_odm3uv$_0;
|
2416 | }
|
2417 | });
|
2418 | function GithubLicense$Companion() {
|
2419 | GithubLicense$Companion_instance = this;
|
2420 | }
|
2421 | GithubLicense$Companion.prototype.serializer = function () {
|
2422 | return GithubLicense$$serializer_getInstance();
|
2423 | };
|
2424 | GithubLicense$Companion.$metadata$ = {
|
2425 | kind: Kind_OBJECT,
|
2426 | simpleName: 'Companion',
|
2427 | interfaces: []
|
2428 | };
|
2429 | var GithubLicense$Companion_instance = null;
|
2430 | function GithubLicense$Companion_getInstance() {
|
2431 | if (GithubLicense$Companion_instance === null) {
|
2432 | new GithubLicense$Companion();
|
2433 | }return GithubLicense$Companion_instance;
|
2434 | }
|
2435 | function GithubLicense$$serializer() {
|
2436 | this.descriptor_29cfwz$_0 = new PluginGeneratedSerialDescriptor('me.jfenn.gitrest.provider.github.model.GithubLicense', this, 8);
|
2437 | this.descriptor.addElement_ivxn3r$('key', true);
|
2438 | this.descriptor.addElement_ivxn3r$('name', true);
|
2439 | this.descriptor.addElement_ivxn3r$('description', true);
|
2440 | this.descriptor.addElement_ivxn3r$('body', true);
|
2441 | this.descriptor.addElement_ivxn3r$('html_url', true);
|
2442 | this.descriptor.addElement_ivxn3r$('permissions', true);
|
2443 | this.descriptor.addElement_ivxn3r$('conditions', true);
|
2444 | this.descriptor.addElement_ivxn3r$('limitations', true);
|
2445 | GithubLicense$$serializer_instance = this;
|
2446 | }
|
2447 | Object.defineProperty(GithubLicense$$serializer.prototype, 'descriptor', {
|
2448 | configurable: true,
|
2449 | get: function () {
|
2450 | return this.descriptor_29cfwz$_0;
|
2451 | }
|
2452 | });
|
2453 | GithubLicense$$serializer.prototype.serialize_55azsf$ = function (encoder, value) {
|
2454 | var output = encoder.beginStructure_24f42q$(this.descriptor);
|
2455 | if (!equals(value.id, '') || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 0))
|
2456 | output.encodeStringElement_iij8qq$(this.descriptor, 0, value.id);
|
2457 | if (!equals(value.name, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 1))
|
2458 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 1, internal.StringSerializer, value.name);
|
2459 | if (!equals(value.description, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 2))
|
2460 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 2, internal.StringSerializer, value.description);
|
2461 | if (!equals(value.body, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 3))
|
2462 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 3, internal.StringSerializer, value.body);
|
2463 | if (!equals(value.infoUrl, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 4))
|
2464 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 4, internal.StringSerializer, value.infoUrl);
|
2465 | if (!equals(value.permissions, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 5))
|
2466 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 5, new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer), value.permissions);
|
2467 | if (!equals(value.conditions, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 6))
|
2468 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 6, new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer), value.conditions);
|
2469 | if (!equals(value.limitations, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 7))
|
2470 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 7, new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer), value.limitations);
|
2471 | output.endStructure_24f42q$(this.descriptor);
|
2472 | };
|
2473 | GithubLicense$$serializer.prototype.deserialize_bq71mq$ = function (decoder) {
|
2474 | var index;
|
2475 | var bitMask0 = 0;
|
2476 | var local0
|
2477 | , local1
|
2478 | , local2
|
2479 | , local3
|
2480 | , local4
|
2481 | , local5
|
2482 | , local6
|
2483 | , local7;
|
2484 | var input = decoder.beginStructure_24f42q$(this.descriptor);
|
2485 | loopLabel: while (true) {
|
2486 | index = input.decodeElementIndex_24f42q$(this.descriptor);
|
2487 | switch (index) {
|
2488 | case 0:
|
2489 | local0 = input.decodeStringElement_szpzho$(this.descriptor, 0);
|
2490 | bitMask0 |= 1;
|
2491 | break;
|
2492 | case 1:
|
2493 | local1 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 1, internal.StringSerializer, local1);
|
2494 | bitMask0 |= 2;
|
2495 | break;
|
2496 | case 2:
|
2497 | local2 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 2, internal.StringSerializer, local2);
|
2498 | bitMask0 |= 4;
|
2499 | break;
|
2500 | case 3:
|
2501 | local3 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 3, internal.StringSerializer, local3);
|
2502 | bitMask0 |= 8;
|
2503 | break;
|
2504 | case 4:
|
2505 | local4 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 4, internal.StringSerializer, local4);
|
2506 | bitMask0 |= 16;
|
2507 | break;
|
2508 | case 5:
|
2509 | local5 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 5, new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer), local5);
|
2510 | bitMask0 |= 32;
|
2511 | break;
|
2512 | case 6:
|
2513 | local6 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 6, new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer), local6);
|
2514 | bitMask0 |= 64;
|
2515 | break;
|
2516 | case 7:
|
2517 | local7 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 7, new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer), local7);
|
2518 | bitMask0 |= 128;
|
2519 | break;
|
2520 | case -1:
|
2521 | break loopLabel;
|
2522 | default:throw new UnknownFieldException(index);
|
2523 | }
|
2524 | }
|
2525 | input.endStructure_24f42q$(this.descriptor);
|
2526 | return GithubLicense_init(bitMask0, local0, local1, local2, local3, local4, local5, local6, local7, null);
|
2527 | };
|
2528 | GithubLicense$$serializer.prototype.childSerializers = function () {
|
2529 | return [internal.StringSerializer, new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer)), new NullableSerializer(new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer)), new NullableSerializer(new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer))];
|
2530 | };
|
2531 | GithubLicense$$serializer.$metadata$ = {
|
2532 | kind: Kind_OBJECT,
|
2533 | simpleName: '$serializer',
|
2534 | interfaces: [GeneratedSerializer]
|
2535 | };
|
2536 | var GithubLicense$$serializer_instance = null;
|
2537 | function GithubLicense$$serializer_getInstance() {
|
2538 | if (GithubLicense$$serializer_instance === null) {
|
2539 | new GithubLicense$$serializer();
|
2540 | }return GithubLicense$$serializer_instance;
|
2541 | }
|
2542 | function GithubLicense_init(seen1, id, name, description, body, infoUrl, permissions, conditions, limitations, serializationConstructorMarker) {
|
2543 | var $this = serializationConstructorMarker || Object.create(GithubLicense.prototype);
|
2544 | License.call($this);
|
2545 | if ((seen1 & 1) === 0)
|
2546 | $this.id_apklj$_0 = '';
|
2547 | else
|
2548 | $this.id_apklj$_0 = id;
|
2549 | if ((seen1 & 2) === 0)
|
2550 | $this.name_1pgghj$_0 = null;
|
2551 | else
|
2552 | $this.name_1pgghj$_0 = name;
|
2553 | if ((seen1 & 4) === 0)
|
2554 | $this.description_b2yzgc$_0 = null;
|
2555 | else
|
2556 | $this.description_b2yzgc$_0 = description;
|
2557 | if ((seen1 & 8) === 0)
|
2558 | $this.body_1vt7zi$_0 = null;
|
2559 | else
|
2560 | $this.body_1vt7zi$_0 = body;
|
2561 | if ((seen1 & 16) === 0)
|
2562 | $this.infoUrl_qv4jsx$_0 = null;
|
2563 | else
|
2564 | $this.infoUrl_qv4jsx$_0 = infoUrl;
|
2565 | if ((seen1 & 32) === 0)
|
2566 | $this.permissions_xocwak$_0 = null;
|
2567 | else
|
2568 | $this.permissions_xocwak$_0 = permissions;
|
2569 | if ((seen1 & 64) === 0)
|
2570 | $this.conditions_ycdnyc$_0 = null;
|
2571 | else
|
2572 | $this.conditions_ycdnyc$_0 = conditions;
|
2573 | if ((seen1 & 128) === 0)
|
2574 | $this.limitations_odm3uv$_0 = null;
|
2575 | else
|
2576 | $this.limitations_odm3uv$_0 = limitations;
|
2577 | return $this;
|
2578 | }
|
2579 | GithubLicense.$metadata$ = {
|
2580 | kind: Kind_CLASS,
|
2581 | simpleName: 'GithubLicense',
|
2582 | interfaces: [License]
|
2583 | };
|
2584 | function GithubRepo() {
|
2585 | GithubRepo$Companion_getInstance();
|
2586 | Repo.call(this);
|
2587 | this.id_6jygxo$_0 = '';
|
2588 | this.description_uc2fdr$_0 = null;
|
2589 | this.url_9wflgy$_0 = null;
|
2590 | this.websiteUrl_57a5p9$_0 = null;
|
2591 | this.gitUrlHttp_ysvvaq$_0 = null;
|
2592 | this.gitUrlSsh_81c8r2$_0 = null;
|
2593 | this.license_cs82v8$_0 = null;
|
2594 | this.defaultBranch_1fsm12$_0 = null;
|
2595 | }
|
2596 | Object.defineProperty(GithubRepo.prototype, 'id', {
|
2597 | configurable: true,
|
2598 | get: function () {
|
2599 | return this.id_6jygxo$_0;
|
2600 | },
|
2601 | set: function (id) {
|
2602 | this.id_6jygxo$_0 = id;
|
2603 | }
|
2604 | });
|
2605 | Object.defineProperty(GithubRepo.prototype, 'description', {
|
2606 | configurable: true,
|
2607 | get: function () {
|
2608 | return this.description_uc2fdr$_0;
|
2609 | }
|
2610 | });
|
2611 | Object.defineProperty(GithubRepo.prototype, 'url', {
|
2612 | configurable: true,
|
2613 | get: function () {
|
2614 | return this.url_9wflgy$_0;
|
2615 | }
|
2616 | });
|
2617 | Object.defineProperty(GithubRepo.prototype, 'websiteUrl', {
|
2618 | configurable: true,
|
2619 | get: function () {
|
2620 | return this.websiteUrl_57a5p9$_0;
|
2621 | }
|
2622 | });
|
2623 | Object.defineProperty(GithubRepo.prototype, 'gitUrlHttp', {
|
2624 | configurable: true,
|
2625 | get: function () {
|
2626 | return this.gitUrlHttp_ysvvaq$_0;
|
2627 | }
|
2628 | });
|
2629 | Object.defineProperty(GithubRepo.prototype, 'gitUrlSsh', {
|
2630 | configurable: true,
|
2631 | get: function () {
|
2632 | return this.gitUrlSsh_81c8r2$_0;
|
2633 | }
|
2634 | });
|
2635 | Object.defineProperty(GithubRepo.prototype, 'license', {
|
2636 | configurable: true,
|
2637 | get: function () {
|
2638 | return this.license_cs82v8$_0;
|
2639 | }
|
2640 | });
|
2641 | Object.defineProperty(GithubRepo.prototype, 'defaultBranch', {
|
2642 | configurable: true,
|
2643 | get: function () {
|
2644 | return this.defaultBranch_1fsm12$_0;
|
2645 | }
|
2646 | });
|
2647 | GithubRepo.prototype.getRawFileUrl_puj7f4$$default = function (branchName, filePath) {
|
2648 | return 'https://raw.githubusercontent.com/' + this.id + '/' + branchName + '/' + filePath;
|
2649 | };
|
2650 | function GithubRepo$Companion() {
|
2651 | GithubRepo$Companion_instance = this;
|
2652 | }
|
2653 | GithubRepo$Companion.prototype.serializer = function () {
|
2654 | return GithubRepo$$serializer_getInstance();
|
2655 | };
|
2656 | GithubRepo$Companion.$metadata$ = {
|
2657 | kind: Kind_OBJECT,
|
2658 | simpleName: 'Companion',
|
2659 | interfaces: []
|
2660 | };
|
2661 | var GithubRepo$Companion_instance = null;
|
2662 | function GithubRepo$Companion_getInstance() {
|
2663 | if (GithubRepo$Companion_instance === null) {
|
2664 | new GithubRepo$Companion();
|
2665 | }return GithubRepo$Companion_instance;
|
2666 | }
|
2667 | function GithubRepo$$serializer() {
|
2668 | this.descriptor_xjpwhc$_0 = new PluginGeneratedSerialDescriptor('me.jfenn.gitrest.provider.github.model.GithubRepo', this, 8);
|
2669 | this.descriptor.addElement_ivxn3r$('full_name', true);
|
2670 | this.descriptor.addElement_ivxn3r$('description', true);
|
2671 | this.descriptor.addElement_ivxn3r$('html_url', true);
|
2672 | this.descriptor.addElement_ivxn3r$('homepage', true);
|
2673 | this.descriptor.addElement_ivxn3r$('clone_url', true);
|
2674 | this.descriptor.addElement_ivxn3r$('ssh_url', true);
|
2675 | this.descriptor.addElement_ivxn3r$('license', true);
|
2676 | this.descriptor.addElement_ivxn3r$('default_branch', true);
|
2677 | GithubRepo$$serializer_instance = this;
|
2678 | }
|
2679 | Object.defineProperty(GithubRepo$$serializer.prototype, 'descriptor', {
|
2680 | configurable: true,
|
2681 | get: function () {
|
2682 | return this.descriptor_xjpwhc$_0;
|
2683 | }
|
2684 | });
|
2685 | GithubRepo$$serializer.prototype.serialize_55azsf$ = function (encoder, value) {
|
2686 | var output = encoder.beginStructure_24f42q$(this.descriptor);
|
2687 | if (!equals(value.id, '') || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 0))
|
2688 | output.encodeStringElement_iij8qq$(this.descriptor, 0, value.id);
|
2689 | if (!equals(value.description, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 1))
|
2690 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 1, new OptionalStringSerializer(), value.description);
|
2691 | if (!equals(value.url, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 2))
|
2692 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 2, internal.StringSerializer, value.url);
|
2693 | if (!equals(value.websiteUrl, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 3))
|
2694 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 3, new OptionalStringSerializer(), value.websiteUrl);
|
2695 | if (!equals(value.gitUrlHttp, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 4))
|
2696 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 4, internal.StringSerializer, value.gitUrlHttp);
|
2697 | if (!equals(value.gitUrlSsh, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 5))
|
2698 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 5, internal.StringSerializer, value.gitUrlSsh);
|
2699 | if (!equals(value.license, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 6))
|
2700 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 6, GithubLicense$$serializer_getInstance(), value.license);
|
2701 | if (!equals(value.defaultBranch, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 7))
|
2702 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 7, internal.StringSerializer, value.defaultBranch);
|
2703 | output.endStructure_24f42q$(this.descriptor);
|
2704 | };
|
2705 | GithubRepo$$serializer.prototype.deserialize_bq71mq$ = function (decoder) {
|
2706 | var index;
|
2707 | var bitMask0 = 0;
|
2708 | var local0
|
2709 | , local1
|
2710 | , local2
|
2711 | , local3
|
2712 | , local4
|
2713 | , local5
|
2714 | , local6
|
2715 | , local7;
|
2716 | var input = decoder.beginStructure_24f42q$(this.descriptor);
|
2717 | loopLabel: while (true) {
|
2718 | index = input.decodeElementIndex_24f42q$(this.descriptor);
|
2719 | switch (index) {
|
2720 | case 0:
|
2721 | local0 = input.decodeStringElement_szpzho$(this.descriptor, 0);
|
2722 | bitMask0 |= 1;
|
2723 | break;
|
2724 | case 1:
|
2725 | local1 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 1, new OptionalStringSerializer(), local1);
|
2726 | bitMask0 |= 2;
|
2727 | break;
|
2728 | case 2:
|
2729 | local2 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 2, internal.StringSerializer, local2);
|
2730 | bitMask0 |= 4;
|
2731 | break;
|
2732 | case 3:
|
2733 | local3 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 3, new OptionalStringSerializer(), local3);
|
2734 | bitMask0 |= 8;
|
2735 | break;
|
2736 | case 4:
|
2737 | local4 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 4, internal.StringSerializer, local4);
|
2738 | bitMask0 |= 16;
|
2739 | break;
|
2740 | case 5:
|
2741 | local5 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 5, internal.StringSerializer, local5);
|
2742 | bitMask0 |= 32;
|
2743 | break;
|
2744 | case 6:
|
2745 | local6 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 6, GithubLicense$$serializer_getInstance(), local6);
|
2746 | bitMask0 |= 64;
|
2747 | break;
|
2748 | case 7:
|
2749 | local7 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 7, internal.StringSerializer, local7);
|
2750 | bitMask0 |= 128;
|
2751 | break;
|
2752 | case -1:
|
2753 | break loopLabel;
|
2754 | default:throw new UnknownFieldException(index);
|
2755 | }
|
2756 | }
|
2757 | input.endStructure_24f42q$(this.descriptor);
|
2758 | return GithubRepo_init(bitMask0, local0, local1, local2, local3, local4, local5, local6, local7, null);
|
2759 | };
|
2760 | GithubRepo$$serializer.prototype.childSerializers = function () {
|
2761 | return [internal.StringSerializer, new NullableSerializer(new OptionalStringSerializer()), new NullableSerializer(internal.StringSerializer), new NullableSerializer(new OptionalStringSerializer()), new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(GithubLicense$$serializer_getInstance()), new NullableSerializer(internal.StringSerializer)];
|
2762 | };
|
2763 | GithubRepo$$serializer.$metadata$ = {
|
2764 | kind: Kind_OBJECT,
|
2765 | simpleName: '$serializer',
|
2766 | interfaces: [GeneratedSerializer]
|
2767 | };
|
2768 | var GithubRepo$$serializer_instance = null;
|
2769 | function GithubRepo$$serializer_getInstance() {
|
2770 | if (GithubRepo$$serializer_instance === null) {
|
2771 | new GithubRepo$$serializer();
|
2772 | }return GithubRepo$$serializer_instance;
|
2773 | }
|
2774 | function GithubRepo_init(seen1, id, description, url, websiteUrl, gitUrlHttp, gitUrlSsh, license, defaultBranch, serializationConstructorMarker) {
|
2775 | var $this = serializationConstructorMarker || Object.create(GithubRepo.prototype);
|
2776 | Repo.call($this);
|
2777 | if ((seen1 & 1) === 0)
|
2778 | $this.id_6jygxo$_0 = '';
|
2779 | else
|
2780 | $this.id_6jygxo$_0 = id;
|
2781 | if ((seen1 & 2) === 0)
|
2782 | $this.description_uc2fdr$_0 = null;
|
2783 | else
|
2784 | $this.description_uc2fdr$_0 = description;
|
2785 | if ((seen1 & 4) === 0)
|
2786 | $this.url_9wflgy$_0 = null;
|
2787 | else
|
2788 | $this.url_9wflgy$_0 = url;
|
2789 | if ((seen1 & 8) === 0)
|
2790 | $this.websiteUrl_57a5p9$_0 = null;
|
2791 | else
|
2792 | $this.websiteUrl_57a5p9$_0 = websiteUrl;
|
2793 | if ((seen1 & 16) === 0)
|
2794 | $this.gitUrlHttp_ysvvaq$_0 = null;
|
2795 | else
|
2796 | $this.gitUrlHttp_ysvvaq$_0 = gitUrlHttp;
|
2797 | if ((seen1 & 32) === 0)
|
2798 | $this.gitUrlSsh_81c8r2$_0 = null;
|
2799 | else
|
2800 | $this.gitUrlSsh_81c8r2$_0 = gitUrlSsh;
|
2801 | if ((seen1 & 64) === 0)
|
2802 | $this.license_cs82v8$_0 = null;
|
2803 | else
|
2804 | $this.license_cs82v8$_0 = license;
|
2805 | if ((seen1 & 128) === 0)
|
2806 | $this.defaultBranch_1fsm12$_0 = null;
|
2807 | else
|
2808 | $this.defaultBranch_1fsm12$_0 = defaultBranch;
|
2809 | return $this;
|
2810 | }
|
2811 | GithubRepo.$metadata$ = {
|
2812 | kind: Kind_CLASS,
|
2813 | simpleName: 'GithubRepo',
|
2814 | interfaces: [Repo]
|
2815 | };
|
2816 | function GithubUser() {
|
2817 | GithubUser$Companion_getInstance();
|
2818 | User.call(this);
|
2819 | this.id_9836s5$_0 = '';
|
2820 | this.name_dv8nh7$_0 = null;
|
2821 | this.url_1uilsl$_0 = null;
|
2822 | this.avatarUrl_y0b1rm$_0 = null;
|
2823 | this.websiteUrl_u94eis$_0 = null;
|
2824 | this.email_7ssi0o$_0 = null;
|
2825 | this.bio_1u6afw$_0 = null;
|
2826 | }
|
2827 | Object.defineProperty(GithubUser.prototype, 'id', {
|
2828 | configurable: true,
|
2829 | get: function () {
|
2830 | return this.id_9836s5$_0;
|
2831 | },
|
2832 | set: function (id) {
|
2833 | this.id_9836s5$_0 = id;
|
2834 | }
|
2835 | });
|
2836 | Object.defineProperty(GithubUser.prototype, 'name', {
|
2837 | configurable: true,
|
2838 | get: function () {
|
2839 | return this.name_dv8nh7$_0;
|
2840 | }
|
2841 | });
|
2842 | Object.defineProperty(GithubUser.prototype, 'url', {
|
2843 | configurable: true,
|
2844 | get: function () {
|
2845 | return this.url_1uilsl$_0;
|
2846 | }
|
2847 | });
|
2848 | Object.defineProperty(GithubUser.prototype, 'avatarUrl', {
|
2849 | configurable: true,
|
2850 | get: function () {
|
2851 | return this.avatarUrl_y0b1rm$_0;
|
2852 | }
|
2853 | });
|
2854 | Object.defineProperty(GithubUser.prototype, 'websiteUrl', {
|
2855 | configurable: true,
|
2856 | get: function () {
|
2857 | return this.websiteUrl_u94eis$_0;
|
2858 | }
|
2859 | });
|
2860 | Object.defineProperty(GithubUser.prototype, 'email', {
|
2861 | configurable: true,
|
2862 | get: function () {
|
2863 | return this.email_7ssi0o$_0;
|
2864 | }
|
2865 | });
|
2866 | Object.defineProperty(GithubUser.prototype, 'bio', {
|
2867 | configurable: true,
|
2868 | get: function () {
|
2869 | return this.bio_1u6afw$_0;
|
2870 | }
|
2871 | });
|
2872 | function GithubUser$Companion() {
|
2873 | GithubUser$Companion_instance = this;
|
2874 | }
|
2875 | GithubUser$Companion.prototype.serializer = function () {
|
2876 | return GithubUser$$serializer_getInstance();
|
2877 | };
|
2878 | GithubUser$Companion.$metadata$ = {
|
2879 | kind: Kind_OBJECT,
|
2880 | simpleName: 'Companion',
|
2881 | interfaces: []
|
2882 | };
|
2883 | var GithubUser$Companion_instance = null;
|
2884 | function GithubUser$Companion_getInstance() {
|
2885 | if (GithubUser$Companion_instance === null) {
|
2886 | new GithubUser$Companion();
|
2887 | }return GithubUser$Companion_instance;
|
2888 | }
|
2889 | function GithubUser$$serializer() {
|
2890 | this.descriptor_77im0n$_0 = new PluginGeneratedSerialDescriptor('me.jfenn.gitrest.provider.github.model.GithubUser', this, 7);
|
2891 | this.descriptor.addElement_ivxn3r$('login', true);
|
2892 | this.descriptor.addElement_ivxn3r$('name', true);
|
2893 | this.descriptor.addElement_ivxn3r$('html_url', true);
|
2894 | this.descriptor.addElement_ivxn3r$('avatar_url', true);
|
2895 | this.descriptor.addElement_ivxn3r$('blog', true);
|
2896 | this.descriptor.addElement_ivxn3r$('email', true);
|
2897 | this.descriptor.addElement_ivxn3r$('bio', true);
|
2898 | GithubUser$$serializer_instance = this;
|
2899 | }
|
2900 | Object.defineProperty(GithubUser$$serializer.prototype, 'descriptor', {
|
2901 | configurable: true,
|
2902 | get: function () {
|
2903 | return this.descriptor_77im0n$_0;
|
2904 | }
|
2905 | });
|
2906 | GithubUser$$serializer.prototype.serialize_55azsf$ = function (encoder, value) {
|
2907 | var output = encoder.beginStructure_24f42q$(this.descriptor);
|
2908 | if (!equals(value.id, '') || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 0))
|
2909 | output.encodeStringElement_iij8qq$(this.descriptor, 0, value.id);
|
2910 | if (!equals(value.name, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 1))
|
2911 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 1, new OptionalStringSerializer(), value.name);
|
2912 | if (!equals(value.url, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 2))
|
2913 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 2, internal.StringSerializer, value.url);
|
2914 | if (!equals(value.avatarUrl, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 3))
|
2915 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 3, internal.StringSerializer, value.avatarUrl);
|
2916 | if (!equals(value.websiteUrl, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 4))
|
2917 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 4, new OptionalStringSerializer(), value.websiteUrl);
|
2918 | if (!equals(value.email, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 5))
|
2919 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 5, new OptionalStringSerializer(), value.email);
|
2920 | if (!equals(value.bio, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 6))
|
2921 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 6, new OptionalStringSerializer(), value.bio);
|
2922 | output.endStructure_24f42q$(this.descriptor);
|
2923 | };
|
2924 | GithubUser$$serializer.prototype.deserialize_bq71mq$ = function (decoder) {
|
2925 | var index;
|
2926 | var bitMask0 = 0;
|
2927 | var local0
|
2928 | , local1
|
2929 | , local2
|
2930 | , local3
|
2931 | , local4
|
2932 | , local5
|
2933 | , local6;
|
2934 | var input = decoder.beginStructure_24f42q$(this.descriptor);
|
2935 | loopLabel: while (true) {
|
2936 | index = input.decodeElementIndex_24f42q$(this.descriptor);
|
2937 | switch (index) {
|
2938 | case 0:
|
2939 | local0 = input.decodeStringElement_szpzho$(this.descriptor, 0);
|
2940 | bitMask0 |= 1;
|
2941 | break;
|
2942 | case 1:
|
2943 | local1 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 1, new OptionalStringSerializer(), local1);
|
2944 | bitMask0 |= 2;
|
2945 | break;
|
2946 | case 2:
|
2947 | local2 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 2, internal.StringSerializer, local2);
|
2948 | bitMask0 |= 4;
|
2949 | break;
|
2950 | case 3:
|
2951 | local3 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 3, internal.StringSerializer, local3);
|
2952 | bitMask0 |= 8;
|
2953 | break;
|
2954 | case 4:
|
2955 | local4 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 4, new OptionalStringSerializer(), local4);
|
2956 | bitMask0 |= 16;
|
2957 | break;
|
2958 | case 5:
|
2959 | local5 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 5, new OptionalStringSerializer(), local5);
|
2960 | bitMask0 |= 32;
|
2961 | break;
|
2962 | case 6:
|
2963 | local6 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 6, new OptionalStringSerializer(), local6);
|
2964 | bitMask0 |= 64;
|
2965 | break;
|
2966 | case -1:
|
2967 | break loopLabel;
|
2968 | default:throw new UnknownFieldException(index);
|
2969 | }
|
2970 | }
|
2971 | input.endStructure_24f42q$(this.descriptor);
|
2972 | return GithubUser_init(bitMask0, local0, local1, local2, local3, local4, local5, local6, null);
|
2973 | };
|
2974 | GithubUser$$serializer.prototype.childSerializers = function () {
|
2975 | return [internal.StringSerializer, new NullableSerializer(new OptionalStringSerializer()), new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(new OptionalStringSerializer()), new NullableSerializer(new OptionalStringSerializer()), new NullableSerializer(new OptionalStringSerializer())];
|
2976 | };
|
2977 | GithubUser$$serializer.$metadata$ = {
|
2978 | kind: Kind_OBJECT,
|
2979 | simpleName: '$serializer',
|
2980 | interfaces: [GeneratedSerializer]
|
2981 | };
|
2982 | var GithubUser$$serializer_instance = null;
|
2983 | function GithubUser$$serializer_getInstance() {
|
2984 | if (GithubUser$$serializer_instance === null) {
|
2985 | new GithubUser$$serializer();
|
2986 | }return GithubUser$$serializer_instance;
|
2987 | }
|
2988 | function GithubUser_init(seen1, id, name, url, avatarUrl, websiteUrl, email, bio, serializationConstructorMarker) {
|
2989 | var $this = serializationConstructorMarker || Object.create(GithubUser.prototype);
|
2990 | User.call($this);
|
2991 | if ((seen1 & 1) === 0)
|
2992 | $this.id_9836s5$_0 = '';
|
2993 | else
|
2994 | $this.id_9836s5$_0 = id;
|
2995 | if ((seen1 & 2) === 0)
|
2996 | $this.name_dv8nh7$_0 = null;
|
2997 | else
|
2998 | $this.name_dv8nh7$_0 = name;
|
2999 | if ((seen1 & 4) === 0)
|
3000 | $this.url_1uilsl$_0 = null;
|
3001 | else
|
3002 | $this.url_1uilsl$_0 = url;
|
3003 | if ((seen1 & 8) === 0)
|
3004 | $this.avatarUrl_y0b1rm$_0 = null;
|
3005 | else
|
3006 | $this.avatarUrl_y0b1rm$_0 = avatarUrl;
|
3007 | if ((seen1 & 16) === 0)
|
3008 | $this.websiteUrl_u94eis$_0 = null;
|
3009 | else
|
3010 | $this.websiteUrl_u94eis$_0 = websiteUrl;
|
3011 | if ((seen1 & 32) === 0)
|
3012 | $this.email_7ssi0o$_0 = null;
|
3013 | else
|
3014 | $this.email_7ssi0o$_0 = email;
|
3015 | if ((seen1 & 64) === 0)
|
3016 | $this.bio_1u6afw$_0 = null;
|
3017 | else
|
3018 | $this.bio_1u6afw$_0 = bio;
|
3019 | return $this;
|
3020 | }
|
3021 | GithubUser.$metadata$ = {
|
3022 | kind: Kind_CLASS,
|
3023 | simpleName: 'GithubUser',
|
3024 | interfaces: [User]
|
3025 | };
|
3026 | function get$lambda_1($receiver) {
|
3027 | return Unit;
|
3028 | }
|
3029 | function GitlabProvider(client) {
|
3030 | GitlabProvider$Companion_getInstance();
|
3031 | this.client = client;
|
3032 | }
|
3033 | function Coroutine$getUser_61zpoe$_1($this, str_0, continuation_0) {
|
3034 | CoroutineImpl.call(this, continuation_0);
|
3035 | this.exceptionState_0 = 6;
|
3036 | this.$this = $this;
|
3037 | this.local$response = void 0;
|
3038 | this.local$str = str_0;
|
3039 | }
|
3040 | Coroutine$getUser_61zpoe$_1.$metadata$ = {
|
3041 | kind: Kotlin.Kind.CLASS,
|
3042 | simpleName: null,
|
3043 | interfaces: [CoroutineImpl]
|
3044 | };
|
3045 | Coroutine$getUser_61zpoe$_1.prototype = Object.create(CoroutineImpl.prototype);
|
3046 | Coroutine$getUser_61zpoe$_1.prototype.constructor = Coroutine$getUser_61zpoe$_1;
|
3047 | Coroutine$getUser_61zpoe$_1.prototype.doResume = function () {
|
3048 | do
|
3049 | try {
|
3050 | switch (this.state_0) {
|
3051 | case 0:
|
3052 | var $receiver_0 = this.$this.client;
|
3053 | var urlString = 'api/v4/users?username=' + this.local$str;
|
3054 | var host_0;
|
3055 | var body_0;
|
3056 | host_0 = 'localhost';
|
3057 | body_0 = utils.EmptyContent;
|
3058 | var $receiver_1 = new HttpRequestBuilder_init();
|
3059 | url($receiver_1, 'http', host_0, 0, '/');
|
3060 | $receiver_1.method = HttpMethod.Companion.Get;
|
3061 | $receiver_1.body = body_0;
|
3062 | takeFrom($receiver_1.url, urlString);
|
3063 | get$lambda_1($receiver_1);
|
3064 | var $this_0 = new HttpStatement_init($receiver_1, $receiver_0);
|
3065 | var tmp$_4, tmp$_5, tmp$_6;
|
3066 | tmp$_4 = getKClass(List);
|
3067 | if (equals(tmp$_4, getKClass(HttpStatement_init))) {
|
3068 | this.result_0 = Kotlin.isType(tmp$_5 = $this_0, List) ? tmp$_5 : throwCCE();
|
3069 | this.state_0 = 9;
|
3070 | continue;
|
3071 | } else {
|
3072 | if (equals(tmp$_4, getKClass(HttpResponse))) {
|
3073 | this.state_0 = 7;
|
3074 | this.result_0 = $this_0.execute(this);
|
3075 | if (this.result_0 === COROUTINE_SUSPENDED)
|
3076 | return COROUTINE_SUSPENDED;
|
3077 | continue;
|
3078 | } else {
|
3079 | this.state_0 = 1;
|
3080 | this.result_0 = $this_0.executeUnsafe(this);
|
3081 | if (this.result_0 === COROUTINE_SUSPENDED)
|
3082 | return COROUTINE_SUSPENDED;
|
3083 | continue;
|
3084 | }
|
3085 | }
|
3086 |
|
3087 | case 1:
|
3088 | this.local$response = this.result_0;
|
3089 | this.exceptionState_0 = 4;
|
3090 | var tmp$_7;
|
3091 | var tmp$_8 = this.local$response.call;
|
3092 | var typeInfo$result_0;
|
3093 | typeInfo$break: do {
|
3094 | try {
|
3095 | typeInfo$result_0 = new TypeInfo_init(getKClass(List), call.JsType, createKType(getKClass(List), [createInvariantKTypeProjection(createKType(getKClass(GitlabUser), [], false))], false));
|
3096 | } catch (_) {
|
3097 | typeInfo$result_0 = new TypeInfo_init(getKClass(List), call.JsType);
|
3098 | break typeInfo$break;
|
3099 | }
|
3100 | }
|
3101 | while (false);
|
3102 | this.state_0 = 2;
|
3103 | this.result_0 = tmp$_8.receive_jo9acv$(typeInfo$result_0, this);
|
3104 | if (this.result_0 === COROUTINE_SUSPENDED)
|
3105 | return COROUTINE_SUSPENDED;
|
3106 | continue;
|
3107 | case 2:
|
3108 | this.result_0 = Kotlin.isType(tmp$_7 = this.result_0, List) ? tmp$_7 : throwCCE();
|
3109 | this.exceptionState_0 = 6;
|
3110 | this.finallyPath_0 = [3];
|
3111 | this.state_0 = 5;
|
3112 | continue;
|
3113 | case 3:
|
3114 | this.state_0 = 8;
|
3115 | continue;
|
3116 | case 4:
|
3117 | this.finallyPath_0 = [6];
|
3118 | this.state_0 = 5;
|
3119 | continue;
|
3120 | case 5:
|
3121 | this.exceptionState_0 = 6;
|
3122 | complete(this.local$response);
|
3123 | this.state_0 = this.finallyPath_0.shift();
|
3124 | continue;
|
3125 | case 6:
|
3126 | throw this.exception_0;
|
3127 | case 7:
|
3128 | this.result_0 = Kotlin.isType(tmp$_6 = this.result_0, List) ? tmp$_6 : throwCCE();
|
3129 | this.state_0 = 8;
|
3130 | continue;
|
3131 | case 8:
|
3132 | this.state_0 = 9;
|
3133 | continue;
|
3134 | case 9:
|
3135 | this.result_0;
|
3136 | var userList = this.result_0;
|
3137 | return firstOrNull(userList);
|
3138 | default:this.state_0 = 6;
|
3139 | throw new Error('State Machine Unreachable execution');
|
3140 | }
|
3141 | } catch (e) {
|
3142 | if (this.state_0 === 6) {
|
3143 | this.exceptionState_0 = this.state_0;
|
3144 | throw e;
|
3145 | } else {
|
3146 | this.state_0 = this.exceptionState_0;
|
3147 | this.exception_0 = e;
|
3148 | }
|
3149 | }
|
3150 | while (true);
|
3151 | };
|
3152 | GitlabProvider.prototype.getUser_61zpoe$ = function (str_0, continuation_0, suspended) {
|
3153 | var instance = new Coroutine$getUser_61zpoe$_1(this, str_0, continuation_0);
|
3154 | if (suspended)
|
3155 | return instance;
|
3156 | else
|
3157 | return instance.doResume(null);
|
3158 | };
|
3159 | function Coroutine$getRepo_61zpoe$_1($this, str_0, continuation_0) {
|
3160 | CoroutineImpl.call(this, continuation_0);
|
3161 | this.exceptionState_0 = 6;
|
3162 | this.$this = $this;
|
3163 | this.local$response = void 0;
|
3164 | this.local$str = str_0;
|
3165 | }
|
3166 | Coroutine$getRepo_61zpoe$_1.$metadata$ = {
|
3167 | kind: Kotlin.Kind.CLASS,
|
3168 | simpleName: null,
|
3169 | interfaces: [CoroutineImpl]
|
3170 | };
|
3171 | Coroutine$getRepo_61zpoe$_1.prototype = Object.create(CoroutineImpl.prototype);
|
3172 | Coroutine$getRepo_61zpoe$_1.prototype.constructor = Coroutine$getRepo_61zpoe$_1;
|
3173 | Coroutine$getRepo_61zpoe$_1.prototype.doResume = function () {
|
3174 | do
|
3175 | try {
|
3176 | switch (this.state_0) {
|
3177 | case 0:
|
3178 | var $receiver_0 = this.$this.client;
|
3179 | var urlString = 'api/v4/projects/' + replace(this.local$str, '/', '%2F') + '?license=true';
|
3180 | var host_0;
|
3181 | var body_0;
|
3182 | host_0 = 'localhost';
|
3183 | body_0 = utils.EmptyContent;
|
3184 | var $receiver_1 = new HttpRequestBuilder_init();
|
3185 | url($receiver_1, 'http', host_0, 0, '/');
|
3186 | $receiver_1.method = HttpMethod.Companion.Get;
|
3187 | $receiver_1.body = body_0;
|
3188 | takeFrom($receiver_1.url, urlString);
|
3189 | get$lambda_1($receiver_1);
|
3190 | var $this_0 = new HttpStatement_init($receiver_1, $receiver_0);
|
3191 | var tmp$_4, tmp$_5, tmp$_6;
|
3192 | tmp$_4 = getKClass(GitlabRepo);
|
3193 | if (equals(tmp$_4, getKClass(HttpStatement_init))) {
|
3194 | this.result_0 = (tmp$_5 = $this_0) == null || Kotlin.isType(tmp$_5, GitlabRepo) ? tmp$_5 : throwCCE();
|
3195 | this.state_0 = 9;
|
3196 | continue;
|
3197 | } else {
|
3198 | if (equals(tmp$_4, getKClass(HttpResponse))) {
|
3199 | this.state_0 = 7;
|
3200 | this.result_0 = $this_0.execute(this);
|
3201 | if (this.result_0 === COROUTINE_SUSPENDED)
|
3202 | return COROUTINE_SUSPENDED;
|
3203 | continue;
|
3204 | } else {
|
3205 | this.state_0 = 1;
|
3206 | this.result_0 = $this_0.executeUnsafe(this);
|
3207 | if (this.result_0 === COROUTINE_SUSPENDED)
|
3208 | return COROUTINE_SUSPENDED;
|
3209 | continue;
|
3210 | }
|
3211 | }
|
3212 |
|
3213 | case 1:
|
3214 | this.local$response = this.result_0;
|
3215 | this.exceptionState_0 = 4;
|
3216 | var tmp$_7;
|
3217 | var tmp$_8 = this.local$response.call;
|
3218 | var typeInfo$result_0;
|
3219 | typeInfo$break: do {
|
3220 | try {
|
3221 | typeInfo$result_0 = new TypeInfo_init(getKClass(GitlabRepo), call.JsType, createKType(getKClass(GitlabRepo), [], true));
|
3222 | } catch (_) {
|
3223 | typeInfo$result_0 = new TypeInfo_init(getKClass(GitlabRepo), call.JsType);
|
3224 | break typeInfo$break;
|
3225 | }
|
3226 | }
|
3227 | while (false);
|
3228 | this.state_0 = 2;
|
3229 | this.result_0 = tmp$_8.receive_jo9acv$(typeInfo$result_0, this);
|
3230 | if (this.result_0 === COROUTINE_SUSPENDED)
|
3231 | return COROUTINE_SUSPENDED;
|
3232 | continue;
|
3233 | case 2:
|
3234 | this.result_0 = (tmp$_7 = this.result_0) == null || Kotlin.isType(tmp$_7, GitlabRepo) ? tmp$_7 : throwCCE();
|
3235 | this.exceptionState_0 = 6;
|
3236 | this.finallyPath_0 = [3];
|
3237 | this.state_0 = 5;
|
3238 | continue;
|
3239 | case 3:
|
3240 | this.state_0 = 8;
|
3241 | continue;
|
3242 | case 4:
|
3243 | this.finallyPath_0 = [6];
|
3244 | this.state_0 = 5;
|
3245 | continue;
|
3246 | case 5:
|
3247 | this.exceptionState_0 = 6;
|
3248 | complete(this.local$response);
|
3249 | this.state_0 = this.finallyPath_0.shift();
|
3250 | continue;
|
3251 | case 6:
|
3252 | throw this.exception_0;
|
3253 | case 7:
|
3254 | this.result_0 = (tmp$_6 = this.result_0) == null || Kotlin.isType(tmp$_6, GitlabRepo) ? tmp$_6 : throwCCE();
|
3255 | this.state_0 = 8;
|
3256 | continue;
|
3257 | case 8:
|
3258 | this.state_0 = 9;
|
3259 | continue;
|
3260 | case 9:
|
3261 | this.result_0;
|
3262 | return this.result_0;
|
3263 | default:this.state_0 = 6;
|
3264 | throw new Error('State Machine Unreachable execution');
|
3265 | }
|
3266 | } catch (e) {
|
3267 | if (this.state_0 === 6) {
|
3268 | this.exceptionState_0 = this.state_0;
|
3269 | throw e;
|
3270 | } else {
|
3271 | this.state_0 = this.exceptionState_0;
|
3272 | this.exception_0 = e;
|
3273 | }
|
3274 | }
|
3275 | while (true);
|
3276 | };
|
3277 | GitlabProvider.prototype.getRepo_61zpoe$ = function (str_0, continuation_0, suspended) {
|
3278 | var instance = new Coroutine$getRepo_61zpoe$_1(this, str_0, continuation_0);
|
3279 | if (suspended)
|
3280 | return instance;
|
3281 | else
|
3282 | return instance.doResume(null);
|
3283 | };
|
3284 | function Coroutine$getRepoContributors_61zpoe$_1($this, str_0, continuation_0) {
|
3285 | CoroutineImpl.call(this, continuation_0);
|
3286 | this.exceptionState_0 = 6;
|
3287 | this.$this = $this;
|
3288 | this.local$response = void 0;
|
3289 | this.local$str = str_0;
|
3290 | }
|
3291 | Coroutine$getRepoContributors_61zpoe$_1.$metadata$ = {
|
3292 | kind: Kotlin.Kind.CLASS,
|
3293 | simpleName: null,
|
3294 | interfaces: [CoroutineImpl]
|
3295 | };
|
3296 | Coroutine$getRepoContributors_61zpoe$_1.prototype = Object.create(CoroutineImpl.prototype);
|
3297 | Coroutine$getRepoContributors_61zpoe$_1.prototype.constructor = Coroutine$getRepoContributors_61zpoe$_1;
|
3298 | Coroutine$getRepoContributors_61zpoe$_1.prototype.doResume = function () {
|
3299 | do
|
3300 | try {
|
3301 | switch (this.state_0) {
|
3302 | case 0:
|
3303 | var $receiver_0 = this.$this.client;
|
3304 | var urlString = 'api/v4/projects/' + replace(this.local$str, '/', '%2F') + '/users';
|
3305 | var host_0;
|
3306 | var body_0;
|
3307 | host_0 = 'localhost';
|
3308 | body_0 = utils.EmptyContent;
|
3309 | var $receiver_1 = new HttpRequestBuilder_init();
|
3310 | url($receiver_1, 'http', host_0, 0, '/');
|
3311 | $receiver_1.method = HttpMethod.Companion.Get;
|
3312 | $receiver_1.body = body_0;
|
3313 | takeFrom($receiver_1.url, urlString);
|
3314 | get$lambda_1($receiver_1);
|
3315 | var $this_0 = new HttpStatement_init($receiver_1, $receiver_0);
|
3316 | var tmp$_4, tmp$_5, tmp$_6;
|
3317 | tmp$_4 = getKClass(List);
|
3318 | if (equals(tmp$_4, getKClass(HttpStatement_init))) {
|
3319 | this.result_0 = (tmp$_5 = $this_0) == null || Kotlin.isType(tmp$_5, List) ? tmp$_5 : throwCCE();
|
3320 | this.state_0 = 9;
|
3321 | continue;
|
3322 | } else {
|
3323 | if (equals(tmp$_4, getKClass(HttpResponse))) {
|
3324 | this.state_0 = 7;
|
3325 | this.result_0 = $this_0.execute(this);
|
3326 | if (this.result_0 === COROUTINE_SUSPENDED)
|
3327 | return COROUTINE_SUSPENDED;
|
3328 | continue;
|
3329 | } else {
|
3330 | this.state_0 = 1;
|
3331 | this.result_0 = $this_0.executeUnsafe(this);
|
3332 | if (this.result_0 === COROUTINE_SUSPENDED)
|
3333 | return COROUTINE_SUSPENDED;
|
3334 | continue;
|
3335 | }
|
3336 | }
|
3337 |
|
3338 | case 1:
|
3339 | this.local$response = this.result_0;
|
3340 | this.exceptionState_0 = 4;
|
3341 | var tmp$_7;
|
3342 | var tmp$_8 = this.local$response.call;
|
3343 | var typeInfo$result_0;
|
3344 | typeInfo$break: do {
|
3345 | try {
|
3346 | typeInfo$result_0 = new TypeInfo_init(getKClass(List), call.JsType, createKType(getKClass(List), [createInvariantKTypeProjection(createKType(getKClass(GitlabUser), [], false))], true));
|
3347 | } catch (_) {
|
3348 | typeInfo$result_0 = new TypeInfo_init(getKClass(List), call.JsType);
|
3349 | break typeInfo$break;
|
3350 | }
|
3351 | }
|
3352 | while (false);
|
3353 | this.state_0 = 2;
|
3354 | this.result_0 = tmp$_8.receive_jo9acv$(typeInfo$result_0, this);
|
3355 | if (this.result_0 === COROUTINE_SUSPENDED)
|
3356 | return COROUTINE_SUSPENDED;
|
3357 | continue;
|
3358 | case 2:
|
3359 | this.result_0 = (tmp$_7 = this.result_0) == null || Kotlin.isType(tmp$_7, List) ? tmp$_7 : throwCCE();
|
3360 | this.exceptionState_0 = 6;
|
3361 | this.finallyPath_0 = [3];
|
3362 | this.state_0 = 5;
|
3363 | continue;
|
3364 | case 3:
|
3365 | this.state_0 = 8;
|
3366 | continue;
|
3367 | case 4:
|
3368 | this.finallyPath_0 = [6];
|
3369 | this.state_0 = 5;
|
3370 | continue;
|
3371 | case 5:
|
3372 | this.exceptionState_0 = 6;
|
3373 | complete(this.local$response);
|
3374 | this.state_0 = this.finallyPath_0.shift();
|
3375 | continue;
|
3376 | case 6:
|
3377 | throw this.exception_0;
|
3378 | case 7:
|
3379 | this.result_0 = (tmp$_6 = this.result_0) == null || Kotlin.isType(tmp$_6, List) ? tmp$_6 : throwCCE();
|
3380 | this.state_0 = 8;
|
3381 | continue;
|
3382 | case 8:
|
3383 | this.state_0 = 9;
|
3384 | continue;
|
3385 | case 9:
|
3386 | this.result_0;
|
3387 | return this.result_0;
|
3388 | default:this.state_0 = 6;
|
3389 | throw new Error('State Machine Unreachable execution');
|
3390 | }
|
3391 | } catch (e) {
|
3392 | if (this.state_0 === 6) {
|
3393 | this.exceptionState_0 = this.state_0;
|
3394 | throw e;
|
3395 | } else {
|
3396 | this.state_0 = this.exceptionState_0;
|
3397 | this.exception_0 = e;
|
3398 | }
|
3399 | }
|
3400 | while (true);
|
3401 | };
|
3402 | GitlabProvider.prototype.getRepoContributors_61zpoe$ = function (str_0, continuation_0, suspended) {
|
3403 | var instance = new Coroutine$getRepoContributors_61zpoe$_1(this, str_0, continuation_0);
|
3404 | if (suspended)
|
3405 | return instance;
|
3406 | else
|
3407 | return instance.doResume(null);
|
3408 | };
|
3409 | function Coroutine$getLicense_61zpoe$_0($this, str_0, continuation_0) {
|
3410 | CoroutineImpl.call(this, continuation_0);
|
3411 | this.exceptionState_0 = 6;
|
3412 | this.$this = $this;
|
3413 | this.local$response = void 0;
|
3414 | this.local$str = str_0;
|
3415 | }
|
3416 | Coroutine$getLicense_61zpoe$_0.$metadata$ = {
|
3417 | kind: Kotlin.Kind.CLASS,
|
3418 | simpleName: null,
|
3419 | interfaces: [CoroutineImpl]
|
3420 | };
|
3421 | Coroutine$getLicense_61zpoe$_0.prototype = Object.create(CoroutineImpl.prototype);
|
3422 | Coroutine$getLicense_61zpoe$_0.prototype.constructor = Coroutine$getLicense_61zpoe$_0;
|
3423 | Coroutine$getLicense_61zpoe$_0.prototype.doResume = function () {
|
3424 | do
|
3425 | try {
|
3426 | switch (this.state_0) {
|
3427 | case 0:
|
3428 | var $receiver_0 = this.$this.client;
|
3429 | var urlString = 'api/v4/templates/licenses/' + this.local$str;
|
3430 | var host_0;
|
3431 | var body_0;
|
3432 | host_0 = 'localhost';
|
3433 | body_0 = utils.EmptyContent;
|
3434 | var $receiver_1 = new HttpRequestBuilder_init();
|
3435 | url($receiver_1, 'http', host_0, 0, '/');
|
3436 | $receiver_1.method = HttpMethod.Companion.Get;
|
3437 | $receiver_1.body = body_0;
|
3438 | takeFrom($receiver_1.url, urlString);
|
3439 | get$lambda_1($receiver_1);
|
3440 | var $this_0 = new HttpStatement_init($receiver_1, $receiver_0);
|
3441 | var tmp$_4, tmp$_5, tmp$_6;
|
3442 | tmp$_4 = getKClass(GitlabLicense);
|
3443 | if (equals(tmp$_4, getKClass(HttpStatement_init))) {
|
3444 | this.result_0 = (tmp$_5 = $this_0) == null || Kotlin.isType(tmp$_5, GitlabLicense) ? tmp$_5 : throwCCE();
|
3445 | this.state_0 = 9;
|
3446 | continue;
|
3447 | } else {
|
3448 | if (equals(tmp$_4, getKClass(HttpResponse))) {
|
3449 | this.state_0 = 7;
|
3450 | this.result_0 = $this_0.execute(this);
|
3451 | if (this.result_0 === COROUTINE_SUSPENDED)
|
3452 | return COROUTINE_SUSPENDED;
|
3453 | continue;
|
3454 | } else {
|
3455 | this.state_0 = 1;
|
3456 | this.result_0 = $this_0.executeUnsafe(this);
|
3457 | if (this.result_0 === COROUTINE_SUSPENDED)
|
3458 | return COROUTINE_SUSPENDED;
|
3459 | continue;
|
3460 | }
|
3461 | }
|
3462 |
|
3463 | case 1:
|
3464 | this.local$response = this.result_0;
|
3465 | this.exceptionState_0 = 4;
|
3466 | var tmp$_7;
|
3467 | var tmp$_8 = this.local$response.call;
|
3468 | var typeInfo$result_0;
|
3469 | typeInfo$break: do {
|
3470 | try {
|
3471 | typeInfo$result_0 = new TypeInfo_init(getKClass(GitlabLicense), call.JsType, createKType(getKClass(GitlabLicense), [], true));
|
3472 | } catch (_) {
|
3473 | typeInfo$result_0 = new TypeInfo_init(getKClass(GitlabLicense), call.JsType);
|
3474 | break typeInfo$break;
|
3475 | }
|
3476 | }
|
3477 | while (false);
|
3478 | this.state_0 = 2;
|
3479 | this.result_0 = tmp$_8.receive_jo9acv$(typeInfo$result_0, this);
|
3480 | if (this.result_0 === COROUTINE_SUSPENDED)
|
3481 | return COROUTINE_SUSPENDED;
|
3482 | continue;
|
3483 | case 2:
|
3484 | this.result_0 = (tmp$_7 = this.result_0) == null || Kotlin.isType(tmp$_7, GitlabLicense) ? tmp$_7 : throwCCE();
|
3485 | this.exceptionState_0 = 6;
|
3486 | this.finallyPath_0 = [3];
|
3487 | this.state_0 = 5;
|
3488 | continue;
|
3489 | case 3:
|
3490 | this.state_0 = 8;
|
3491 | continue;
|
3492 | case 4:
|
3493 | this.finallyPath_0 = [6];
|
3494 | this.state_0 = 5;
|
3495 | continue;
|
3496 | case 5:
|
3497 | this.exceptionState_0 = 6;
|
3498 | complete(this.local$response);
|
3499 | this.state_0 = this.finallyPath_0.shift();
|
3500 | continue;
|
3501 | case 6:
|
3502 | throw this.exception_0;
|
3503 | case 7:
|
3504 | this.result_0 = (tmp$_6 = this.result_0) == null || Kotlin.isType(tmp$_6, GitlabLicense) ? tmp$_6 : throwCCE();
|
3505 | this.state_0 = 8;
|
3506 | continue;
|
3507 | case 8:
|
3508 | this.state_0 = 9;
|
3509 | continue;
|
3510 | case 9:
|
3511 | this.result_0;
|
3512 | return this.result_0;
|
3513 | default:this.state_0 = 6;
|
3514 | throw new Error('State Machine Unreachable execution');
|
3515 | }
|
3516 | } catch (e) {
|
3517 | if (this.state_0 === 6) {
|
3518 | this.exceptionState_0 = this.state_0;
|
3519 | throw e;
|
3520 | } else {
|
3521 | this.state_0 = this.exceptionState_0;
|
3522 | this.exception_0 = e;
|
3523 | }
|
3524 | }
|
3525 | while (true);
|
3526 | };
|
3527 | GitlabProvider.prototype.getLicense_61zpoe$ = function (str_0, continuation_0, suspended) {
|
3528 | var instance = new Coroutine$getLicense_61zpoe$_0(this, str_0, continuation_0);
|
3529 | if (suspended)
|
3530 | return instance;
|
3531 | else
|
3532 | return instance.doResume(null);
|
3533 | };
|
3534 | function GitlabProvider$Companion() {
|
3535 | GitlabProvider$Companion_instance = this;
|
3536 | this.key_p7tpty$_0 = 'gitlab';
|
3537 | this.tokens_miskhh$_0 = HashMap_init();
|
3538 | }
|
3539 | Object.defineProperty(GitlabProvider$Companion.prototype, 'key', {
|
3540 | configurable: true,
|
3541 | get: function () {
|
3542 | return this.key_p7tpty$_0;
|
3543 | }
|
3544 | });
|
3545 | Object.defineProperty(GitlabProvider$Companion.prototype, 'tokens', {
|
3546 | configurable: true,
|
3547 | get: function () {
|
3548 | return this.tokens_miskhh$_0;
|
3549 | }
|
3550 | });
|
3551 | function GitlabProvider$Companion$create$lambda$lambda$lambda(closure$hostname) {
|
3552 | return function ($receiver, it) {
|
3553 | $receiver.protocol = URLProtocol.Companion.HTTPS;
|
3554 | $receiver.host = closure$hostname;
|
3555 | return Unit;
|
3556 | };
|
3557 | }
|
3558 | function GitlabProvider$Companion$create$lambda$lambda(closure$hostname, this$GitlabProvider$) {
|
3559 | return function ($receiver) {
|
3560 | var tmp$;
|
3561 | $receiver.url_6yzzjr$(GitlabProvider$Companion$create$lambda$lambda$lambda(closure$hostname));
|
3562 | if ((tmp$ = this$GitlabProvider$.tokens.get_11rb$(closure$hostname)) != null) {
|
3563 | header($receiver, 'Authorization', 'Bearer ' + tmp$);
|
3564 | }return Unit;
|
3565 | };
|
3566 | }
|
3567 | function GitlabProvider$Companion$create$lambda(closure$hostname, this$GitlabProvider$) {
|
3568 | return function ($receiver) {
|
3569 | defaultRequest($receiver, GitlabProvider$Companion$create$lambda$lambda(closure$hostname, this$GitlabProvider$));
|
3570 | return Unit;
|
3571 | };
|
3572 | }
|
3573 | GitlabProvider$Companion.prototype.create_wf0mc2$ = function (config, hostname) {
|
3574 | var client = this.ktor_1v6kay$(config, GitlabProvider$Companion$create$lambda(hostname, this));
|
3575 | return new GitlabProvider(client);
|
3576 | };
|
3577 | GitlabProvider$Companion.$metadata$ = {
|
3578 | kind: Kind_OBJECT,
|
3579 | simpleName: 'Companion',
|
3580 | interfaces: [ServiceBuilder]
|
3581 | };
|
3582 | var GitlabProvider$Companion_instance = null;
|
3583 | function GitlabProvider$Companion_getInstance() {
|
3584 | if (GitlabProvider$Companion_instance === null) {
|
3585 | new GitlabProvider$Companion();
|
3586 | }return GitlabProvider$Companion_instance;
|
3587 | }
|
3588 | GitlabProvider.$metadata$ = {
|
3589 | kind: Kind_CLASS,
|
3590 | simpleName: 'GitlabProvider',
|
3591 | interfaces: [RequestProvider]
|
3592 | };
|
3593 | function GitlabLicense() {
|
3594 | GitlabLicense$Companion_getInstance();
|
3595 | License.call(this);
|
3596 | this.id_peimpz$_0 = '';
|
3597 | this.name_m64ih5$_0 = null;
|
3598 | this.fullName = null;
|
3599 | this.description_jjllvo$_0 = null;
|
3600 | this.body_lzrqz6$_0 = null;
|
3601 | this.infoUrl_1xt6wx$_0 = null;
|
3602 | this.permissions_6q6kck$_0 = null;
|
3603 | this.conditions_x3bp18$_0 = null;
|
3604 | this.limitations_g0xcs9$_0 = null;
|
3605 | }
|
3606 | Object.defineProperty(GitlabLicense.prototype, 'id', {
|
3607 | configurable: true,
|
3608 | get: function () {
|
3609 | return this.id_peimpz$_0;
|
3610 | },
|
3611 | set: function (id) {
|
3612 | this.id_peimpz$_0 = id;
|
3613 | }
|
3614 | });
|
3615 | Object.defineProperty(GitlabLicense.prototype, 'name', {
|
3616 | configurable: true,
|
3617 | get: function () {
|
3618 | return this.name_m64ih5$_0;
|
3619 | }
|
3620 | });
|
3621 | Object.defineProperty(GitlabLicense.prototype, 'description', {
|
3622 | configurable: true,
|
3623 | get: function () {
|
3624 | return this.description_jjllvo$_0;
|
3625 | }
|
3626 | });
|
3627 | Object.defineProperty(GitlabLicense.prototype, 'body', {
|
3628 | configurable: true,
|
3629 | get: function () {
|
3630 | return this.body_lzrqz6$_0;
|
3631 | }
|
3632 | });
|
3633 | Object.defineProperty(GitlabLicense.prototype, 'infoUrl', {
|
3634 | configurable: true,
|
3635 | get: function () {
|
3636 | return this.infoUrl_1xt6wx$_0;
|
3637 | }
|
3638 | });
|
3639 | Object.defineProperty(GitlabLicense.prototype, 'permissions', {
|
3640 | configurable: true,
|
3641 | get: function () {
|
3642 | return this.permissions_6q6kck$_0;
|
3643 | }
|
3644 | });
|
3645 | Object.defineProperty(GitlabLicense.prototype, 'conditions', {
|
3646 | configurable: true,
|
3647 | get: function () {
|
3648 | return this.conditions_x3bp18$_0;
|
3649 | }
|
3650 | });
|
3651 | Object.defineProperty(GitlabLicense.prototype, 'limitations', {
|
3652 | configurable: true,
|
3653 | get: function () {
|
3654 | return this.limitations_g0xcs9$_0;
|
3655 | }
|
3656 | });
|
3657 | function GitlabLicense$Companion() {
|
3658 | GitlabLicense$Companion_instance = this;
|
3659 | }
|
3660 | GitlabLicense$Companion.prototype.serializer = function () {
|
3661 | return GitlabLicense$$serializer_getInstance();
|
3662 | };
|
3663 | GitlabLicense$Companion.$metadata$ = {
|
3664 | kind: Kind_OBJECT,
|
3665 | simpleName: 'Companion',
|
3666 | interfaces: []
|
3667 | };
|
3668 | var GitlabLicense$Companion_instance = null;
|
3669 | function GitlabLicense$Companion_getInstance() {
|
3670 | if (GitlabLicense$Companion_instance === null) {
|
3671 | new GitlabLicense$Companion();
|
3672 | }return GitlabLicense$Companion_instance;
|
3673 | }
|
3674 | function GitlabLicense$$serializer() {
|
3675 | this.descriptor_v3ek4t$_0 = new PluginGeneratedSerialDescriptor('me.jfenn.gitrest.provider.gitlab.model.GitlabLicense', this, 9);
|
3676 | this.descriptor.addElement_ivxn3r$('key', true);
|
3677 | this.descriptor.addElement_ivxn3r$('nickname', true);
|
3678 | this.descriptor.addElement_ivxn3r$('name', true);
|
3679 | this.descriptor.addElement_ivxn3r$('description', true);
|
3680 | this.descriptor.addElement_ivxn3r$('content', true);
|
3681 | this.descriptor.addElement_ivxn3r$('html_url', true);
|
3682 | this.descriptor.addElement_ivxn3r$('permissions', true);
|
3683 | this.descriptor.addElement_ivxn3r$('conditions', true);
|
3684 | this.descriptor.addElement_ivxn3r$('limitations', true);
|
3685 | GitlabLicense$$serializer_instance = this;
|
3686 | }
|
3687 | Object.defineProperty(GitlabLicense$$serializer.prototype, 'descriptor', {
|
3688 | configurable: true,
|
3689 | get: function () {
|
3690 | return this.descriptor_v3ek4t$_0;
|
3691 | }
|
3692 | });
|
3693 | GitlabLicense$$serializer.prototype.serialize_55azsf$ = function (encoder, value) {
|
3694 | var output = encoder.beginStructure_24f42q$(this.descriptor);
|
3695 | if (!equals(value.id, '') || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 0))
|
3696 | output.encodeStringElement_iij8qq$(this.descriptor, 0, value.id);
|
3697 | if (!equals(value.name, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 1))
|
3698 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 1, internal.StringSerializer, value.name);
|
3699 | if (!equals(value.fullName, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 2))
|
3700 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 2, internal.StringSerializer, value.fullName);
|
3701 | if (!equals(value.description, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 3))
|
3702 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 3, internal.StringSerializer, value.description);
|
3703 | if (!equals(value.body, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 4))
|
3704 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 4, internal.StringSerializer, value.body);
|
3705 | if (!equals(value.infoUrl, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 5))
|
3706 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 5, internal.StringSerializer, value.infoUrl);
|
3707 | if (!equals(value.permissions, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 6))
|
3708 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 6, new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer), value.permissions);
|
3709 | if (!equals(value.conditions, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 7))
|
3710 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 7, new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer), value.conditions);
|
3711 | if (!equals(value.limitations, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 8))
|
3712 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 8, new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer), value.limitations);
|
3713 | output.endStructure_24f42q$(this.descriptor);
|
3714 | };
|
3715 | GitlabLicense$$serializer.prototype.deserialize_bq71mq$ = function (decoder) {
|
3716 | var index;
|
3717 | var bitMask0 = 0;
|
3718 | var local0
|
3719 | , local1
|
3720 | , local2
|
3721 | , local3
|
3722 | , local4
|
3723 | , local5
|
3724 | , local6
|
3725 | , local7
|
3726 | , local8;
|
3727 | var input = decoder.beginStructure_24f42q$(this.descriptor);
|
3728 | loopLabel: while (true) {
|
3729 | index = input.decodeElementIndex_24f42q$(this.descriptor);
|
3730 | switch (index) {
|
3731 | case 0:
|
3732 | local0 = input.decodeStringElement_szpzho$(this.descriptor, 0);
|
3733 | bitMask0 |= 1;
|
3734 | break;
|
3735 | case 1:
|
3736 | local1 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 1, internal.StringSerializer, local1);
|
3737 | bitMask0 |= 2;
|
3738 | break;
|
3739 | case 2:
|
3740 | local2 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 2, internal.StringSerializer, local2);
|
3741 | bitMask0 |= 4;
|
3742 | break;
|
3743 | case 3:
|
3744 | local3 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 3, internal.StringSerializer, local3);
|
3745 | bitMask0 |= 8;
|
3746 | break;
|
3747 | case 4:
|
3748 | local4 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 4, internal.StringSerializer, local4);
|
3749 | bitMask0 |= 16;
|
3750 | break;
|
3751 | case 5:
|
3752 | local5 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 5, internal.StringSerializer, local5);
|
3753 | bitMask0 |= 32;
|
3754 | break;
|
3755 | case 6:
|
3756 | local6 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 6, new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer), local6);
|
3757 | bitMask0 |= 64;
|
3758 | break;
|
3759 | case 7:
|
3760 | local7 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 7, new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer), local7);
|
3761 | bitMask0 |= 128;
|
3762 | break;
|
3763 | case 8:
|
3764 | local8 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 8, new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer), local8);
|
3765 | bitMask0 |= 256;
|
3766 | break;
|
3767 | case -1:
|
3768 | break loopLabel;
|
3769 | default:throw new UnknownFieldException(index);
|
3770 | }
|
3771 | }
|
3772 | input.endStructure_24f42q$(this.descriptor);
|
3773 | return GitlabLicense_init(bitMask0, local0, local1, local2, local3, local4, local5, local6, local7, local8, null);
|
3774 | };
|
3775 | GitlabLicense$$serializer.prototype.childSerializers = function () {
|
3776 | return [internal.StringSerializer, new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer)), new NullableSerializer(new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer)), new NullableSerializer(new ReferenceArraySerializer(PrimitiveClasses$stringClass, internal.StringSerializer))];
|
3777 | };
|
3778 | GitlabLicense$$serializer.$metadata$ = {
|
3779 | kind: Kind_OBJECT,
|
3780 | simpleName: '$serializer',
|
3781 | interfaces: [GeneratedSerializer]
|
3782 | };
|
3783 | var GitlabLicense$$serializer_instance = null;
|
3784 | function GitlabLicense$$serializer_getInstance() {
|
3785 | if (GitlabLicense$$serializer_instance === null) {
|
3786 | new GitlabLicense$$serializer();
|
3787 | }return GitlabLicense$$serializer_instance;
|
3788 | }
|
3789 | function GitlabLicense_init(seen1, id, name, fullName, description, body, infoUrl, permissions, conditions, limitations, serializationConstructorMarker) {
|
3790 | var $this = serializationConstructorMarker || Object.create(GitlabLicense.prototype);
|
3791 | License.call($this);
|
3792 | if ((seen1 & 1) === 0)
|
3793 | $this.id_peimpz$_0 = '';
|
3794 | else
|
3795 | $this.id_peimpz$_0 = id;
|
3796 | if ((seen1 & 2) === 0)
|
3797 | $this.name_m64ih5$_0 = null;
|
3798 | else
|
3799 | $this.name_m64ih5$_0 = name;
|
3800 | if ((seen1 & 4) === 0)
|
3801 | $this.fullName = null;
|
3802 | else
|
3803 | $this.fullName = fullName;
|
3804 | if ((seen1 & 8) === 0)
|
3805 | $this.description_jjllvo$_0 = null;
|
3806 | else
|
3807 | $this.description_jjllvo$_0 = description;
|
3808 | if ((seen1 & 16) === 0)
|
3809 | $this.body_lzrqz6$_0 = null;
|
3810 | else
|
3811 | $this.body_lzrqz6$_0 = body;
|
3812 | if ((seen1 & 32) === 0)
|
3813 | $this.infoUrl_1xt6wx$_0 = null;
|
3814 | else
|
3815 | $this.infoUrl_1xt6wx$_0 = infoUrl;
|
3816 | if ((seen1 & 64) === 0)
|
3817 | $this.permissions_6q6kck$_0 = null;
|
3818 | else
|
3819 | $this.permissions_6q6kck$_0 = permissions;
|
3820 | if ((seen1 & 128) === 0)
|
3821 | $this.conditions_x3bp18$_0 = null;
|
3822 | else
|
3823 | $this.conditions_x3bp18$_0 = conditions;
|
3824 | if ((seen1 & 256) === 0)
|
3825 | $this.limitations_g0xcs9$_0 = null;
|
3826 | else
|
3827 | $this.limitations_g0xcs9$_0 = limitations;
|
3828 | return $this;
|
3829 | }
|
3830 | GitlabLicense.$metadata$ = {
|
3831 | kind: Kind_CLASS,
|
3832 | simpleName: 'GitlabLicense',
|
3833 | interfaces: [License]
|
3834 | };
|
3835 | function GitlabRepo() {
|
3836 | GitlabRepo$Companion_getInstance();
|
3837 | Repo.call(this);
|
3838 | this.id_xqpd18$_0 = '';
|
3839 | this.description_w1l4f5$_0 = null;
|
3840 | this.url_jgmm42$_0 = null;
|
3841 | this.gitUrlHttp_bawtse$_0 = null;
|
3842 | this.gitUrlSsh_4xwnda$_0 = null;
|
3843 | this.license_b3cw3g$_0 = null;
|
3844 | this.defaultBranch_517b0m$_0 = null;
|
3845 | }
|
3846 | Object.defineProperty(GitlabRepo.prototype, 'id', {
|
3847 | configurable: true,
|
3848 | get: function () {
|
3849 | return this.id_xqpd18$_0;
|
3850 | },
|
3851 | set: function (id) {
|
3852 | this.id_xqpd18$_0 = id;
|
3853 | }
|
3854 | });
|
3855 | Object.defineProperty(GitlabRepo.prototype, 'description', {
|
3856 | configurable: true,
|
3857 | get: function () {
|
3858 | return this.description_w1l4f5$_0;
|
3859 | }
|
3860 | });
|
3861 | Object.defineProperty(GitlabRepo.prototype, 'url', {
|
3862 | configurable: true,
|
3863 | get: function () {
|
3864 | return this.url_jgmm42$_0;
|
3865 | }
|
3866 | });
|
3867 | Object.defineProperty(GitlabRepo.prototype, 'gitUrlHttp', {
|
3868 | configurable: true,
|
3869 | get: function () {
|
3870 | return this.gitUrlHttp_bawtse$_0;
|
3871 | }
|
3872 | });
|
3873 | Object.defineProperty(GitlabRepo.prototype, 'gitUrlSsh', {
|
3874 | configurable: true,
|
3875 | get: function () {
|
3876 | return this.gitUrlSsh_4xwnda$_0;
|
3877 | }
|
3878 | });
|
3879 | Object.defineProperty(GitlabRepo.prototype, 'license', {
|
3880 | configurable: true,
|
3881 | get: function () {
|
3882 | return this.license_b3cw3g$_0;
|
3883 | }
|
3884 | });
|
3885 | Object.defineProperty(GitlabRepo.prototype, 'defaultBranch', {
|
3886 | configurable: true,
|
3887 | get: function () {
|
3888 | return this.defaultBranch_517b0m$_0;
|
3889 | }
|
3890 | });
|
3891 | GitlabRepo.prototype.getRawFileUrl_puj7f4$$default = function (branchName, filePath) {
|
3892 | return toString(this.url) + '/raw/' + branchName + '/' + filePath;
|
3893 | };
|
3894 | function GitlabRepo$Companion() {
|
3895 | GitlabRepo$Companion_instance = this;
|
3896 | }
|
3897 | GitlabRepo$Companion.prototype.serializer = function () {
|
3898 | return GitlabRepo$$serializer_getInstance();
|
3899 | };
|
3900 | GitlabRepo$Companion.$metadata$ = {
|
3901 | kind: Kind_OBJECT,
|
3902 | simpleName: 'Companion',
|
3903 | interfaces: []
|
3904 | };
|
3905 | var GitlabRepo$Companion_instance = null;
|
3906 | function GitlabRepo$Companion_getInstance() {
|
3907 | if (GitlabRepo$Companion_instance === null) {
|
3908 | new GitlabRepo$Companion();
|
3909 | }return GitlabRepo$Companion_instance;
|
3910 | }
|
3911 | function GitlabRepo$$serializer() {
|
3912 | this.descriptor_8fa3ww$_0 = new PluginGeneratedSerialDescriptor('me.jfenn.gitrest.provider.gitlab.model.GitlabRepo', this, 7);
|
3913 | this.descriptor.addElement_ivxn3r$('path_with_namespace', true);
|
3914 | this.descriptor.addElement_ivxn3r$('description', true);
|
3915 | this.descriptor.addElement_ivxn3r$('web_url', true);
|
3916 | this.descriptor.addElement_ivxn3r$('http_url_to_repo', true);
|
3917 | this.descriptor.addElement_ivxn3r$('ssh_url_to_repo', true);
|
3918 | this.descriptor.addElement_ivxn3r$('license', true);
|
3919 | this.descriptor.addElement_ivxn3r$('default_branch', true);
|
3920 | GitlabRepo$$serializer_instance = this;
|
3921 | }
|
3922 | Object.defineProperty(GitlabRepo$$serializer.prototype, 'descriptor', {
|
3923 | configurable: true,
|
3924 | get: function () {
|
3925 | return this.descriptor_8fa3ww$_0;
|
3926 | }
|
3927 | });
|
3928 | GitlabRepo$$serializer.prototype.serialize_55azsf$ = function (encoder, value) {
|
3929 | var output = encoder.beginStructure_24f42q$(this.descriptor);
|
3930 | if (!equals(value.id, '') || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 0))
|
3931 | output.encodeStringElement_iij8qq$(this.descriptor, 0, value.id);
|
3932 | if (!equals(value.description, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 1))
|
3933 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 1, new OptionalStringSerializer(), value.description);
|
3934 | if (!equals(value.url, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 2))
|
3935 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 2, internal.StringSerializer, value.url);
|
3936 | if (!equals(value.gitUrlHttp, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 3))
|
3937 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 3, internal.StringSerializer, value.gitUrlHttp);
|
3938 | if (!equals(value.gitUrlSsh, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 4))
|
3939 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 4, internal.StringSerializer, value.gitUrlSsh);
|
3940 | if (!equals(value.license, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 5))
|
3941 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 5, GitlabLicense$$serializer_getInstance(), value.license);
|
3942 | if (!equals(value.defaultBranch, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 6))
|
3943 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 6, internal.StringSerializer, value.defaultBranch);
|
3944 | output.endStructure_24f42q$(this.descriptor);
|
3945 | };
|
3946 | GitlabRepo$$serializer.prototype.deserialize_bq71mq$ = function (decoder) {
|
3947 | var index;
|
3948 | var bitMask0 = 0;
|
3949 | var local0
|
3950 | , local1
|
3951 | , local2
|
3952 | , local3
|
3953 | , local4
|
3954 | , local5
|
3955 | , local6;
|
3956 | var input = decoder.beginStructure_24f42q$(this.descriptor);
|
3957 | loopLabel: while (true) {
|
3958 | index = input.decodeElementIndex_24f42q$(this.descriptor);
|
3959 | switch (index) {
|
3960 | case 0:
|
3961 | local0 = input.decodeStringElement_szpzho$(this.descriptor, 0);
|
3962 | bitMask0 |= 1;
|
3963 | break;
|
3964 | case 1:
|
3965 | local1 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 1, new OptionalStringSerializer(), local1);
|
3966 | bitMask0 |= 2;
|
3967 | break;
|
3968 | case 2:
|
3969 | local2 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 2, internal.StringSerializer, local2);
|
3970 | bitMask0 |= 4;
|
3971 | break;
|
3972 | case 3:
|
3973 | local3 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 3, internal.StringSerializer, local3);
|
3974 | bitMask0 |= 8;
|
3975 | break;
|
3976 | case 4:
|
3977 | local4 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 4, internal.StringSerializer, local4);
|
3978 | bitMask0 |= 16;
|
3979 | break;
|
3980 | case 5:
|
3981 | local5 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 5, GitlabLicense$$serializer_getInstance(), local5);
|
3982 | bitMask0 |= 32;
|
3983 | break;
|
3984 | case 6:
|
3985 | local6 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 6, internal.StringSerializer, local6);
|
3986 | bitMask0 |= 64;
|
3987 | break;
|
3988 | case -1:
|
3989 | break loopLabel;
|
3990 | default:throw new UnknownFieldException(index);
|
3991 | }
|
3992 | }
|
3993 | input.endStructure_24f42q$(this.descriptor);
|
3994 | return GitlabRepo_init(bitMask0, local0, local1, local2, local3, local4, local5, local6, null);
|
3995 | };
|
3996 | GitlabRepo$$serializer.prototype.childSerializers = function () {
|
3997 | return [internal.StringSerializer, new NullableSerializer(new OptionalStringSerializer()), new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(GitlabLicense$$serializer_getInstance()), new NullableSerializer(internal.StringSerializer)];
|
3998 | };
|
3999 | GitlabRepo$$serializer.$metadata$ = {
|
4000 | kind: Kind_OBJECT,
|
4001 | simpleName: '$serializer',
|
4002 | interfaces: [GeneratedSerializer]
|
4003 | };
|
4004 | var GitlabRepo$$serializer_instance = null;
|
4005 | function GitlabRepo$$serializer_getInstance() {
|
4006 | if (GitlabRepo$$serializer_instance === null) {
|
4007 | new GitlabRepo$$serializer();
|
4008 | }return GitlabRepo$$serializer_instance;
|
4009 | }
|
4010 | function GitlabRepo_init(seen1, id, description, url, gitUrlHttp, gitUrlSsh, license, defaultBranch, serializationConstructorMarker) {
|
4011 | var $this = serializationConstructorMarker || Object.create(GitlabRepo.prototype);
|
4012 | Repo.call($this);
|
4013 | if ((seen1 & 1) === 0)
|
4014 | $this.id_xqpd18$_0 = '';
|
4015 | else
|
4016 | $this.id_xqpd18$_0 = id;
|
4017 | if ((seen1 & 2) === 0)
|
4018 | $this.description_w1l4f5$_0 = null;
|
4019 | else
|
4020 | $this.description_w1l4f5$_0 = description;
|
4021 | if ((seen1 & 4) === 0)
|
4022 | $this.url_jgmm42$_0 = null;
|
4023 | else
|
4024 | $this.url_jgmm42$_0 = url;
|
4025 | if ((seen1 & 8) === 0)
|
4026 | $this.gitUrlHttp_bawtse$_0 = null;
|
4027 | else
|
4028 | $this.gitUrlHttp_bawtse$_0 = gitUrlHttp;
|
4029 | if ((seen1 & 16) === 0)
|
4030 | $this.gitUrlSsh_4xwnda$_0 = null;
|
4031 | else
|
4032 | $this.gitUrlSsh_4xwnda$_0 = gitUrlSsh;
|
4033 | if ((seen1 & 32) === 0)
|
4034 | $this.license_b3cw3g$_0 = null;
|
4035 | else
|
4036 | $this.license_b3cw3g$_0 = license;
|
4037 | if ((seen1 & 64) === 0)
|
4038 | $this.defaultBranch_517b0m$_0 = null;
|
4039 | else
|
4040 | $this.defaultBranch_517b0m$_0 = defaultBranch;
|
4041 | return $this;
|
4042 | }
|
4043 | GitlabRepo.$metadata$ = {
|
4044 | kind: Kind_CLASS,
|
4045 | simpleName: 'GitlabRepo',
|
4046 | interfaces: [Repo]
|
4047 | };
|
4048 | function GitlabUser() {
|
4049 | GitlabUser$Companion_getInstance();
|
4050 | User.call(this);
|
4051 | this.id_ym9z3f$_0 = '';
|
4052 | this.name_q4tzh7$_0 = null;
|
4053 | this.url_7poeuj$_0 = null;
|
4054 | this.avatarUrl_uwvgdu$_0 = null;
|
4055 | this.websiteUrl_5bt1ms$_0 = null;
|
4056 | this.email_wwlk54$_0 = null;
|
4057 | this.bio_7q0q78$_0 = null;
|
4058 | }
|
4059 | Object.defineProperty(GitlabUser.prototype, 'id', {
|
4060 | configurable: true,
|
4061 | get: function () {
|
4062 | return this.id_ym9z3f$_0;
|
4063 | },
|
4064 | set: function (id) {
|
4065 | this.id_ym9z3f$_0 = id;
|
4066 | }
|
4067 | });
|
4068 | Object.defineProperty(GitlabUser.prototype, 'name', {
|
4069 | configurable: true,
|
4070 | get: function () {
|
4071 | return this.name_q4tzh7$_0;
|
4072 | }
|
4073 | });
|
4074 | Object.defineProperty(GitlabUser.prototype, 'url', {
|
4075 | configurable: true,
|
4076 | get: function () {
|
4077 | return this.url_7poeuj$_0;
|
4078 | }
|
4079 | });
|
4080 | Object.defineProperty(GitlabUser.prototype, 'avatarUrl', {
|
4081 | configurable: true,
|
4082 | get: function () {
|
4083 | return this.avatarUrl_uwvgdu$_0;
|
4084 | }
|
4085 | });
|
4086 | Object.defineProperty(GitlabUser.prototype, 'websiteUrl', {
|
4087 | configurable: true,
|
4088 | get: function () {
|
4089 | return this.websiteUrl_5bt1ms$_0;
|
4090 | }
|
4091 | });
|
4092 | Object.defineProperty(GitlabUser.prototype, 'email', {
|
4093 | configurable: true,
|
4094 | get: function () {
|
4095 | return this.email_wwlk54$_0;
|
4096 | }
|
4097 | });
|
4098 | Object.defineProperty(GitlabUser.prototype, 'bio', {
|
4099 | configurable: true,
|
4100 | get: function () {
|
4101 | return this.bio_7q0q78$_0;
|
4102 | }
|
4103 | });
|
4104 | function GitlabUser$Companion() {
|
4105 | GitlabUser$Companion_instance = this;
|
4106 | }
|
4107 | GitlabUser$Companion.prototype.serializer = function () {
|
4108 | return GitlabUser$$serializer_getInstance();
|
4109 | };
|
4110 | GitlabUser$Companion.$metadata$ = {
|
4111 | kind: Kind_OBJECT,
|
4112 | simpleName: 'Companion',
|
4113 | interfaces: []
|
4114 | };
|
4115 | var GitlabUser$Companion_instance = null;
|
4116 | function GitlabUser$Companion_getInstance() {
|
4117 | if (GitlabUser$Companion_instance === null) {
|
4118 | new GitlabUser$Companion();
|
4119 | }return GitlabUser$Companion_instance;
|
4120 | }
|
4121 | function GitlabUser$$serializer() {
|
4122 | this.descriptor_lulfk9$_0 = new PluginGeneratedSerialDescriptor('me.jfenn.gitrest.provider.gitlab.model.GitlabUser', this, 7);
|
4123 | this.descriptor.addElement_ivxn3r$('username', true);
|
4124 | this.descriptor.addElement_ivxn3r$('name', true);
|
4125 | this.descriptor.addElement_ivxn3r$('web_url', true);
|
4126 | this.descriptor.addElement_ivxn3r$('avatar_url', true);
|
4127 | this.descriptor.addElement_ivxn3r$('website_url', true);
|
4128 | this.descriptor.addElement_ivxn3r$('public_email', true);
|
4129 | this.descriptor.addElement_ivxn3r$('bio', true);
|
4130 | GitlabUser$$serializer_instance = this;
|
4131 | }
|
4132 | Object.defineProperty(GitlabUser$$serializer.prototype, 'descriptor', {
|
4133 | configurable: true,
|
4134 | get: function () {
|
4135 | return this.descriptor_lulfk9$_0;
|
4136 | }
|
4137 | });
|
4138 | GitlabUser$$serializer.prototype.serialize_55azsf$ = function (encoder, value) {
|
4139 | var output = encoder.beginStructure_24f42q$(this.descriptor);
|
4140 | if (!equals(value.id, '') || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 0))
|
4141 | output.encodeStringElement_iij8qq$(this.descriptor, 0, value.id);
|
4142 | if (!equals(value.name, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 1))
|
4143 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 1, new OptionalStringSerializer(), value.name);
|
4144 | if (!equals(value.url, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 2))
|
4145 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 2, internal.StringSerializer, value.url);
|
4146 | if (!equals(value.avatarUrl, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 3))
|
4147 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 3, internal.StringSerializer, value.avatarUrl);
|
4148 | if (!equals(value.websiteUrl, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 4))
|
4149 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 4, new OptionalStringSerializer(), value.websiteUrl);
|
4150 | if (!equals(value.email, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 5))
|
4151 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 5, new OptionalStringSerializer(), value.email);
|
4152 | if (!equals(value.bio, null) || output.shouldEncodeElementDefault_szpzho$(this.descriptor, 6))
|
4153 | output.encodeNullableSerializableElement_qw92s8$(this.descriptor, 6, new OptionalStringSerializer(), value.bio);
|
4154 | output.endStructure_24f42q$(this.descriptor);
|
4155 | };
|
4156 | GitlabUser$$serializer.prototype.deserialize_bq71mq$ = function (decoder) {
|
4157 | var index;
|
4158 | var bitMask0 = 0;
|
4159 | var local0
|
4160 | , local1
|
4161 | , local2
|
4162 | , local3
|
4163 | , local4
|
4164 | , local5
|
4165 | , local6;
|
4166 | var input = decoder.beginStructure_24f42q$(this.descriptor);
|
4167 | loopLabel: while (true) {
|
4168 | index = input.decodeElementIndex_24f42q$(this.descriptor);
|
4169 | switch (index) {
|
4170 | case 0:
|
4171 | local0 = input.decodeStringElement_szpzho$(this.descriptor, 0);
|
4172 | bitMask0 |= 1;
|
4173 | break;
|
4174 | case 1:
|
4175 | local1 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 1, new OptionalStringSerializer(), local1);
|
4176 | bitMask0 |= 2;
|
4177 | break;
|
4178 | case 2:
|
4179 | local2 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 2, internal.StringSerializer, local2);
|
4180 | bitMask0 |= 4;
|
4181 | break;
|
4182 | case 3:
|
4183 | local3 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 3, internal.StringSerializer, local3);
|
4184 | bitMask0 |= 8;
|
4185 | break;
|
4186 | case 4:
|
4187 | local4 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 4, new OptionalStringSerializer(), local4);
|
4188 | bitMask0 |= 16;
|
4189 | break;
|
4190 | case 5:
|
4191 | local5 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 5, new OptionalStringSerializer(), local5);
|
4192 | bitMask0 |= 32;
|
4193 | break;
|
4194 | case 6:
|
4195 | local6 = input.decodeNullableSerializableElement_8viuyw$(this.descriptor, 6, new OptionalStringSerializer(), local6);
|
4196 | bitMask0 |= 64;
|
4197 | break;
|
4198 | case -1:
|
4199 | break loopLabel;
|
4200 | default:throw new UnknownFieldException(index);
|
4201 | }
|
4202 | }
|
4203 | input.endStructure_24f42q$(this.descriptor);
|
4204 | return GitlabUser_init(bitMask0, local0, local1, local2, local3, local4, local5, local6, null);
|
4205 | };
|
4206 | GitlabUser$$serializer.prototype.childSerializers = function () {
|
4207 | return [internal.StringSerializer, new NullableSerializer(new OptionalStringSerializer()), new NullableSerializer(internal.StringSerializer), new NullableSerializer(internal.StringSerializer), new NullableSerializer(new OptionalStringSerializer()), new NullableSerializer(new OptionalStringSerializer()), new NullableSerializer(new OptionalStringSerializer())];
|
4208 | };
|
4209 | GitlabUser$$serializer.$metadata$ = {
|
4210 | kind: Kind_OBJECT,
|
4211 | simpleName: '$serializer',
|
4212 | interfaces: [GeneratedSerializer]
|
4213 | };
|
4214 | var GitlabUser$$serializer_instance = null;
|
4215 | function GitlabUser$$serializer_getInstance() {
|
4216 | if (GitlabUser$$serializer_instance === null) {
|
4217 | new GitlabUser$$serializer();
|
4218 | }return GitlabUser$$serializer_instance;
|
4219 | }
|
4220 | function GitlabUser_init(seen1, id, name, url, avatarUrl, websiteUrl, email, bio, serializationConstructorMarker) {
|
4221 | var $this = serializationConstructorMarker || Object.create(GitlabUser.prototype);
|
4222 | User.call($this);
|
4223 | if ((seen1 & 1) === 0)
|
4224 | $this.id_ym9z3f$_0 = '';
|
4225 | else
|
4226 | $this.id_ym9z3f$_0 = id;
|
4227 | if ((seen1 & 2) === 0)
|
4228 | $this.name_q4tzh7$_0 = null;
|
4229 | else
|
4230 | $this.name_q4tzh7$_0 = name;
|
4231 | if ((seen1 & 4) === 0)
|
4232 | $this.url_7poeuj$_0 = null;
|
4233 | else
|
4234 | $this.url_7poeuj$_0 = url;
|
4235 | if ((seen1 & 8) === 0)
|
4236 | $this.avatarUrl_uwvgdu$_0 = null;
|
4237 | else
|
4238 | $this.avatarUrl_uwvgdu$_0 = avatarUrl;
|
4239 | if ((seen1 & 16) === 0)
|
4240 | $this.websiteUrl_5bt1ms$_0 = null;
|
4241 | else
|
4242 | $this.websiteUrl_5bt1ms$_0 = websiteUrl;
|
4243 | if ((seen1 & 32) === 0)
|
4244 | $this.email_wwlk54$_0 = null;
|
4245 | else
|
4246 | $this.email_wwlk54$_0 = email;
|
4247 | if ((seen1 & 64) === 0)
|
4248 | $this.bio_7q0q78$_0 = null;
|
4249 | else
|
4250 | $this.bio_7q0q78$_0 = bio;
|
4251 | return $this;
|
4252 | }
|
4253 | GitlabUser.$metadata$ = {
|
4254 | kind: Kind_CLASS,
|
4255 | simpleName: 'GitlabUser',
|
4256 | interfaces: [User]
|
4257 | };
|
4258 | function Cache() {
|
4259 | }
|
4260 | Cache.$metadata$ = {
|
4261 | kind: Kind_INTERFACE,
|
4262 | simpleName: 'Cache',
|
4263 | interfaces: []
|
4264 | };
|
4265 | function NoCache() {
|
4266 | NoCache_instance = this;
|
4267 | }
|
4268 | NoCache.prototype.set_bm4g0d$ = function (key, value, continuation) {
|
4269 | };
|
4270 | NoCache.prototype.get_ytbaoo$ = function (id, continuation) {
|
4271 | return null;
|
4272 | };
|
4273 | NoCache.$metadata$ = {
|
4274 | kind: Kind_OBJECT,
|
4275 | simpleName: 'NoCache',
|
4276 | interfaces: [Cache]
|
4277 | };
|
4278 | var NoCache_instance = null;
|
4279 | function NoCache_getInstance() {
|
4280 | if (NoCache_instance === null) {
|
4281 | new NoCache();
|
4282 | }return NoCache_instance;
|
4283 | }
|
4284 | var DEFAULT_PROVIDERS;
|
4285 | function OptionalStringSerializer() {
|
4286 | this.descriptor_llni3b$_0 = PrimitiveSerialDescriptor('kotlin.OptionalString', PrimitiveKind.STRING);
|
4287 | this.valueSerializer_7gml4p$_0 = serializer(kotlin_js_internal_StringCompanionObject);
|
4288 | }
|
4289 | Object.defineProperty(OptionalStringSerializer.prototype, 'descriptor', {
|
4290 | configurable: true,
|
4291 | get: function () {
|
4292 | return this.descriptor_llni3b$_0;
|
4293 | }
|
4294 | });
|
4295 | OptionalStringSerializer.prototype.deserialize_bq71mq$ = function (decoder) {
|
4296 | var str = this.valueSerializer_7gml4p$_0.deserialize_bq71mq$(decoder);
|
4297 | return !isBlank(str) ? str : null;
|
4298 | };
|
4299 | OptionalStringSerializer.prototype.serialize_55azsf$ = function (encoder, value) {
|
4300 | if (value != null) {
|
4301 | this.valueSerializer_7gml4p$_0.serialize_55azsf$(encoder, value);
|
4302 | }};
|
4303 | OptionalStringSerializer.$metadata$ = {
|
4304 | kind: Kind_CLASS,
|
4305 | simpleName: 'OptionalStringSerializer',
|
4306 | interfaces: [KSerializer]
|
4307 | };
|
4308 | function Client(config) {
|
4309 | this.client = gitrest(Client$client$lambda(config));
|
4310 | }
|
4311 | Client.prototype.demangle_0 = function (obj) {
|
4312 | var ret = {};
|
4313 | var $receiver = Object.entries(obj);
|
4314 | var tmp$;
|
4315 | for (tmp$ = 0; tmp$ !== $receiver.length; ++tmp$) {
|
4316 | var element = $receiver[tmp$];
|
4317 | var tmp$_0, tmp$_1;
|
4318 | var name = split(element[0], ['_']).get_za3lpa$(0);
|
4319 | if (((tmp$_1 = typeof (tmp$_0 = ret[name]) === 'string' ? tmp$_0 : null) != null ? isBlank(tmp$_1) : null) !== false)
|
4320 | ret[name] = element[1];
|
4321 | }
|
4322 | return ret;
|
4323 | };
|
4324 | function Coroutine$Client$getUser$lambda(this$Client_0, closure$str_0, $receiver_0, controller, continuation_0) {
|
4325 | CoroutineImpl.call(this, continuation_0);
|
4326 | this.$controller = controller;
|
4327 | this.exceptionState_0 = 1;
|
4328 | this.local$this$Client = this$Client_0;
|
4329 | this.local$closure$str = closure$str_0;
|
4330 | }
|
4331 | Coroutine$Client$getUser$lambda.$metadata$ = {
|
4332 | kind: Kotlin.Kind.CLASS,
|
4333 | simpleName: null,
|
4334 | interfaces: [CoroutineImpl]
|
4335 | };
|
4336 | Coroutine$Client$getUser$lambda.prototype = Object.create(CoroutineImpl.prototype);
|
4337 | Coroutine$Client$getUser$lambda.prototype.constructor = Coroutine$Client$getUser$lambda;
|
4338 | Coroutine$Client$getUser$lambda.prototype.doResume = function () {
|
4339 | do
|
4340 | try {
|
4341 | switch (this.state_0) {
|
4342 | case 0:
|
4343 | var tmp$;
|
4344 | this.state_0 = 2;
|
4345 | this.result_0 = this.local$this$Client.client.getUser_61zpoe$(this.local$closure$str, this);
|
4346 | if (this.result_0 === COROUTINE_SUSPENDED)
|
4347 | return COROUTINE_SUSPENDED;
|
4348 | continue;
|
4349 | case 1:
|
4350 | throw this.exception_0;
|
4351 | case 2:
|
4352 | return (tmp$ = this.result_0) != null ? this.local$this$Client.demangle_0(tmp$) : null;
|
4353 | default:this.state_0 = 1;
|
4354 | throw new Error('State Machine Unreachable execution');
|
4355 | }
|
4356 | } catch (e) {
|
4357 | if (this.state_0 === 1) {
|
4358 | this.exceptionState_0 = this.state_0;
|
4359 | throw e;
|
4360 | } else {
|
4361 | this.state_0 = this.exceptionState_0;
|
4362 | this.exception_0 = e;
|
4363 | }
|
4364 | }
|
4365 | while (true);
|
4366 | };
|
4367 | function Client$getUser$lambda(this$Client_0, closure$str_0) {
|
4368 | return function ($receiver_0, continuation_0, suspended) {
|
4369 | var instance = new Coroutine$Client$getUser$lambda(this$Client_0, closure$str_0, $receiver_0, this, continuation_0);
|
4370 | if (suspended)
|
4371 | return instance;
|
4372 | else
|
4373 | return instance.doResume(null);
|
4374 | };
|
4375 | }
|
4376 | Client.prototype.getUser = function (str) {
|
4377 | return promise(coroutines.GlobalScope, void 0, void 0, Client$getUser$lambda(this, str));
|
4378 | };
|
4379 | function Coroutine$Client$getRepo$lambda(this$Client_0, closure$str_0, $receiver_0, controller, continuation_0) {
|
4380 | CoroutineImpl.call(this, continuation_0);
|
4381 | this.$controller = controller;
|
4382 | this.exceptionState_0 = 1;
|
4383 | this.local$this$Client = this$Client_0;
|
4384 | this.local$closure$str = closure$str_0;
|
4385 | }
|
4386 | Coroutine$Client$getRepo$lambda.$metadata$ = {
|
4387 | kind: Kotlin.Kind.CLASS,
|
4388 | simpleName: null,
|
4389 | interfaces: [CoroutineImpl]
|
4390 | };
|
4391 | Coroutine$Client$getRepo$lambda.prototype = Object.create(CoroutineImpl.prototype);
|
4392 | Coroutine$Client$getRepo$lambda.prototype.constructor = Coroutine$Client$getRepo$lambda;
|
4393 | Coroutine$Client$getRepo$lambda.prototype.doResume = function () {
|
4394 | do
|
4395 | try {
|
4396 | switch (this.state_0) {
|
4397 | case 0:
|
4398 | var tmp$;
|
4399 | this.state_0 = 2;
|
4400 | this.result_0 = this.local$this$Client.client.getRepo_61zpoe$(this.local$closure$str, this);
|
4401 | if (this.result_0 === COROUTINE_SUSPENDED)
|
4402 | return COROUTINE_SUSPENDED;
|
4403 | continue;
|
4404 | case 1:
|
4405 | throw this.exception_0;
|
4406 | case 2:
|
4407 | return (tmp$ = this.result_0) != null ? this.local$this$Client.demangle_0(tmp$) : null;
|
4408 | default:this.state_0 = 1;
|
4409 | throw new Error('State Machine Unreachable execution');
|
4410 | }
|
4411 | } catch (e) {
|
4412 | if (this.state_0 === 1) {
|
4413 | this.exceptionState_0 = this.state_0;
|
4414 | throw e;
|
4415 | } else {
|
4416 | this.state_0 = this.exceptionState_0;
|
4417 | this.exception_0 = e;
|
4418 | }
|
4419 | }
|
4420 | while (true);
|
4421 | };
|
4422 | function Client$getRepo$lambda(this$Client_0, closure$str_0) {
|
4423 | return function ($receiver_0, continuation_0, suspended) {
|
4424 | var instance = new Coroutine$Client$getRepo$lambda(this$Client_0, closure$str_0, $receiver_0, this, continuation_0);
|
4425 | if (suspended)
|
4426 | return instance;
|
4427 | else
|
4428 | return instance.doResume(null);
|
4429 | };
|
4430 | }
|
4431 | Client.prototype.getRepo = function (str) {
|
4432 | return promise(coroutines.GlobalScope, void 0, void 0, Client$getRepo$lambda(this, str));
|
4433 | };
|
4434 | function Coroutine$Client$getRepoContributors$lambda(this$Client_0, closure$str_0, $receiver_0, controller, continuation_0) {
|
4435 | CoroutineImpl.call(this, continuation_0);
|
4436 | this.$controller = controller;
|
4437 | this.exceptionState_0 = 1;
|
4438 | this.local$this$Client = this$Client_0;
|
4439 | this.local$closure$str = closure$str_0;
|
4440 | }
|
4441 | Coroutine$Client$getRepoContributors$lambda.$metadata$ = {
|
4442 | kind: Kotlin.Kind.CLASS,
|
4443 | simpleName: null,
|
4444 | interfaces: [CoroutineImpl]
|
4445 | };
|
4446 | Coroutine$Client$getRepoContributors$lambda.prototype = Object.create(CoroutineImpl.prototype);
|
4447 | Coroutine$Client$getRepoContributors$lambda.prototype.constructor = Coroutine$Client$getRepoContributors$lambda;
|
4448 | Coroutine$Client$getRepoContributors$lambda.prototype.doResume = function () {
|
4449 | do
|
4450 | try {
|
4451 | switch (this.state_0) {
|
4452 | case 0:
|
4453 | var tmp$, tmp$_0;
|
4454 | this.state_0 = 2;
|
4455 | this.result_0 = this.local$this$Client.client.getRepoContributors_61zpoe$(this.local$closure$str, this);
|
4456 | if (this.result_0 === COROUTINE_SUSPENDED)
|
4457 | return COROUTINE_SUSPENDED;
|
4458 | continue;
|
4459 | case 1:
|
4460 | throw this.exception_0;
|
4461 | case 2:
|
4462 | var tmp$_1;
|
4463 | if ((tmp$ = this.result_0) != null) {
|
4464 | var destination = ArrayList_init(collectionSizeOrDefault(tmp$, 10));
|
4465 | var tmp$_2;
|
4466 | tmp$_2 = tmp$.iterator();
|
4467 | while (tmp$_2.hasNext()) {
|
4468 | var item = tmp$_2.next();
|
4469 | destination.add_11rb$(this.local$this$Client.demangle_0(item));
|
4470 | }
|
4471 | tmp$_1 = destination;
|
4472 | } else
|
4473 | tmp$_1 = null;
|
4474 | return (tmp$_0 = tmp$_1) != null ? copyToArray(tmp$_0) : null;
|
4475 | default:this.state_0 = 1;
|
4476 | throw new Error('State Machine Unreachable execution');
|
4477 | }
|
4478 | } catch (e) {
|
4479 | if (this.state_0 === 1) {
|
4480 | this.exceptionState_0 = this.state_0;
|
4481 | throw e;
|
4482 | } else {
|
4483 | this.state_0 = this.exceptionState_0;
|
4484 | this.exception_0 = e;
|
4485 | }
|
4486 | }
|
4487 | while (true);
|
4488 | };
|
4489 | function Client$getRepoContributors$lambda(this$Client_0, closure$str_0) {
|
4490 | return function ($receiver_0, continuation_0, suspended) {
|
4491 | var instance = new Coroutine$Client$getRepoContributors$lambda(this$Client_0, closure$str_0, $receiver_0, this, continuation_0);
|
4492 | if (suspended)
|
4493 | return instance;
|
4494 | else
|
4495 | return instance.doResume(null);
|
4496 | };
|
4497 | }
|
4498 | Client.prototype.getRepoContributors = function (str) {
|
4499 | return promise(coroutines.GlobalScope, void 0, void 0, Client$getRepoContributors$lambda(this, str));
|
4500 | };
|
4501 | function Coroutine$Client$getLicense$lambda(this$Client_0, closure$str_0, $receiver_0, controller, continuation_0) {
|
4502 | CoroutineImpl.call(this, continuation_0);
|
4503 | this.$controller = controller;
|
4504 | this.exceptionState_0 = 1;
|
4505 | this.local$this$Client = this$Client_0;
|
4506 | this.local$closure$str = closure$str_0;
|
4507 | }
|
4508 | Coroutine$Client$getLicense$lambda.$metadata$ = {
|
4509 | kind: Kotlin.Kind.CLASS,
|
4510 | simpleName: null,
|
4511 | interfaces: [CoroutineImpl]
|
4512 | };
|
4513 | Coroutine$Client$getLicense$lambda.prototype = Object.create(CoroutineImpl.prototype);
|
4514 | Coroutine$Client$getLicense$lambda.prototype.constructor = Coroutine$Client$getLicense$lambda;
|
4515 | Coroutine$Client$getLicense$lambda.prototype.doResume = function () {
|
4516 | do
|
4517 | try {
|
4518 | switch (this.state_0) {
|
4519 | case 0:
|
4520 | var tmp$;
|
4521 | this.state_0 = 2;
|
4522 | this.result_0 = this.local$this$Client.client.getLicense_61zpoe$(this.local$closure$str, this);
|
4523 | if (this.result_0 === COROUTINE_SUSPENDED)
|
4524 | return COROUTINE_SUSPENDED;
|
4525 | continue;
|
4526 | case 1:
|
4527 | throw this.exception_0;
|
4528 | case 2:
|
4529 | return (tmp$ = this.result_0) != null ? this.local$this$Client.demangle_0(tmp$) : null;
|
4530 | default:this.state_0 = 1;
|
4531 | throw new Error('State Machine Unreachable execution');
|
4532 | }
|
4533 | } catch (e) {
|
4534 | if (this.state_0 === 1) {
|
4535 | this.exceptionState_0 = this.state_0;
|
4536 | throw e;
|
4537 | } else {
|
4538 | this.state_0 = this.exceptionState_0;
|
4539 | this.exception_0 = e;
|
4540 | }
|
4541 | }
|
4542 | while (true);
|
4543 | };
|
4544 | function Client$getLicense$lambda(this$Client_0, closure$str_0) {
|
4545 | return function ($receiver_0, continuation_0, suspended) {
|
4546 | var instance = new Coroutine$Client$getLicense$lambda(this$Client_0, closure$str_0, $receiver_0, this, continuation_0);
|
4547 | if (suspended)
|
4548 | return instance;
|
4549 | else
|
4550 | return instance.doResume(null);
|
4551 | };
|
4552 | }
|
4553 | Client.prototype.getLicense = function (str) {
|
4554 | return promise(coroutines.GlobalScope, void 0, void 0, Client$getLicense$lambda(this, str));
|
4555 | };
|
4556 | function Client$client$lambda(closure$config) {
|
4557 | return function ($receiver) {
|
4558 | var tmp$;
|
4559 | if ((closure$config != null ? closure$config.tokens : null) != null) {
|
4560 | var $receiver_0 = Object.entries(closure$config.tokens);
|
4561 | var destination = ArrayList_init($receiver_0.length);
|
4562 | var tmp$_0;
|
4563 | for (tmp$_0 = 0; tmp$_0 !== $receiver_0.length; ++tmp$_0) {
|
4564 | var item = $receiver_0[tmp$_0];
|
4565 | destination.add_11rb$(to(item[0], item[1]));
|
4566 | }
|
4567 | var tokens = toMap(destination);
|
4568 | var $receiver_1 = $receiver.providers;
|
4569 | var tmp$_1;
|
4570 | for (tmp$_1 = 0; tmp$_1 !== $receiver_1.length; ++tmp$_1) {
|
4571 | var element = $receiver_1[tmp$_1];
|
4572 | element.tokens.putAll_a2k3zr$(tokens);
|
4573 | }
|
4574 | }if (((tmp$ = closure$config != null ? closure$config.cache : null) != null ? tmp$.type : null) == 'disk') {
|
4575 | $receiver.cache = new DiskCache($receiver);
|
4576 | }return Unit;
|
4577 | };
|
4578 | }
|
4579 | Client.$metadata$ = {
|
4580 | kind: Kind_CLASS,
|
4581 | simpleName: 'Client',
|
4582 | interfaces: []
|
4583 | };
|
4584 | function PlatformConfig() {
|
4585 | }
|
4586 | PlatformConfig.$metadata$ = {
|
4587 | kind: Kind_CLASS,
|
4588 | simpleName: 'PlatformConfig',
|
4589 | interfaces: []
|
4590 | };
|
4591 | function DiskCache(config, cacheDuration) {
|
4592 | if (cacheDuration === void 0)
|
4593 | cacheDuration = L864000000;
|
4594 | this.config = config;
|
4595 | this.cacheDuration = cacheDuration;
|
4596 | this.persist_0 = null;
|
4597 | this.promisePersist_0 = null;
|
4598 | }
|
4599 | function Coroutine$getPersist_0($this, continuation_0) {
|
4600 | CoroutineImpl.call(this, continuation_0);
|
4601 | this.exceptionState_0 = 1;
|
4602 | this.$this = $this;
|
4603 | }
|
4604 | Coroutine$getPersist_0.$metadata$ = {
|
4605 | kind: Kotlin.Kind.CLASS,
|
4606 | simpleName: null,
|
4607 | interfaces: [CoroutineImpl]
|
4608 | };
|
4609 | Coroutine$getPersist_0.prototype = Object.create(CoroutineImpl.prototype);
|
4610 | Coroutine$getPersist_0.prototype.constructor = Coroutine$getPersist_0;
|
4611 | Coroutine$getPersist_0.prototype.doResume = function () {
|
4612 | do
|
4613 | try {
|
4614 | switch (this.state_0) {
|
4615 | case 0:
|
4616 | var tmp$, tmp$_0;
|
4617 | if (typeof localStorage != 'undefined')
|
4618 | this.$this.persist_0 = localStorage;
|
4619 | if (this.$this.persist_0 == null) {
|
4620 | this.$this.persist_0 = require('node-persist');
|
4621 | this.$this.promisePersist_0 = Kotlin.isType(tmp$ = this.$this.persist_0.init(), Promise) ? tmp$ : throwCCE();
|
4622 | }
|
4623 | if ((tmp$_0 = this.$this.promisePersist_0) != null) {
|
4624 | this.state_0 = 2;
|
4625 | this.result_0 = await_0(tmp$_0, this);
|
4626 | if (this.result_0 === COROUTINE_SUSPENDED)
|
4627 | return COROUTINE_SUSPENDED;
|
4628 | continue;
|
4629 | } else {
|
4630 | this.result_0 = null;
|
4631 | this.state_0 = 3;
|
4632 | continue;
|
4633 | }
|
4634 |
|
4635 | case 1:
|
4636 | throw this.exception_0;
|
4637 | case 2:
|
4638 | this.state_0 = 3;
|
4639 | continue;
|
4640 | case 3:
|
4641 | return this.$this.persist_0;
|
4642 | default:this.state_0 = 1;
|
4643 | throw new Error('State Machine Unreachable execution');
|
4644 | }
|
4645 | } catch (e) {
|
4646 | if (this.state_0 === 1) {
|
4647 | this.exceptionState_0 = this.state_0;
|
4648 | throw e;
|
4649 | } else {
|
4650 | this.state_0 = this.exceptionState_0;
|
4651 | this.exception_0 = e;
|
4652 | }
|
4653 | }
|
4654 | while (true);
|
4655 | };
|
4656 | DiskCache.prototype.getPersist_0 = function (continuation_0, suspended) {
|
4657 | var instance = new Coroutine$getPersist_0(this, continuation_0);
|
4658 | if (suspended)
|
4659 | return instance;
|
4660 | else
|
4661 | return instance.doResume(null);
|
4662 | };
|
4663 | DiskCache.prototype.getVersion_0 = function () {
|
4664 | var keys = Object.keys;
|
4665 | return keys(new Repo())[0];
|
4666 | };
|
4667 | function Coroutine$set_bm4g0d$($this, key_0, value_0, continuation_0) {
|
4668 | CoroutineImpl.call(this, continuation_0);
|
4669 | this.exceptionState_0 = 1;
|
4670 | this.$this = $this;
|
4671 | this.local$string = void 0;
|
4672 | this.local$key = key_0;
|
4673 | this.local$value = value_0;
|
4674 | }
|
4675 | Coroutine$set_bm4g0d$.$metadata$ = {
|
4676 | kind: Kotlin.Kind.CLASS,
|
4677 | simpleName: null,
|
4678 | interfaces: [CoroutineImpl]
|
4679 | };
|
4680 | Coroutine$set_bm4g0d$.prototype = Object.create(CoroutineImpl.prototype);
|
4681 | Coroutine$set_bm4g0d$.prototype.constructor = Coroutine$set_bm4g0d$;
|
4682 | Coroutine$set_bm4g0d$.prototype.doResume = function () {
|
4683 | do
|
4684 | try {
|
4685 | switch (this.state_0) {
|
4686 | case 0:
|
4687 | var tmp$;
|
4688 | this.local$string = this.$this.getVersion_0() + '#' + toString(Date.now()) + '#' + JSON.stringify(this.local$value);
|
4689 | this.state_0 = 2;
|
4690 | this.result_0 = this.$this.getPersist_0(this);
|
4691 | if (this.result_0 === COROUTINE_SUSPENDED)
|
4692 | return COROUTINE_SUSPENDED;
|
4693 | continue;
|
4694 | case 1:
|
4695 | throw this.exception_0;
|
4696 | case 2:
|
4697 | this.state_0 = 3;
|
4698 | this.result_0 = await_0(Kotlin.isType(tmp$ = this.result_0.setItem(this.local$key, this.local$string), Promise) ? tmp$ : throwCCE(), this);
|
4699 | if (this.result_0 === COROUTINE_SUSPENDED)
|
4700 | return COROUTINE_SUSPENDED;
|
4701 | continue;
|
4702 | case 3:
|
4703 | return;
|
4704 | default:this.state_0 = 1;
|
4705 | throw new Error('State Machine Unreachable execution');
|
4706 | }
|
4707 | } catch (e) {
|
4708 | if (this.state_0 === 1) {
|
4709 | this.exceptionState_0 = this.state_0;
|
4710 | throw e;
|
4711 | } else {
|
4712 | this.state_0 = this.exceptionState_0;
|
4713 | this.exception_0 = e;
|
4714 | }
|
4715 | }
|
4716 | while (true);
|
4717 | };
|
4718 | DiskCache.prototype.set_bm4g0d$ = function (key_0, value_0, continuation_0, suspended) {
|
4719 | var instance = new Coroutine$set_bm4g0d$(this, key_0, value_0, continuation_0);
|
4720 | if (suspended)
|
4721 | return instance;
|
4722 | else
|
4723 | return instance.doResume(null);
|
4724 | };
|
4725 | function Coroutine$get_ytbaoo$($this, key_0, continuation_0) {
|
4726 | CoroutineImpl.call(this, continuation_0);
|
4727 | this.exceptionState_0 = 1;
|
4728 | this.$this = $this;
|
4729 | this.local$tmp$_0 = void 0;
|
4730 | this.local$stringContents = void 0;
|
4731 | this.local$lastModified = void 0;
|
4732 | this.local$json = void 0;
|
4733 | this.local$key = key_0;
|
4734 | }
|
4735 | Coroutine$get_ytbaoo$.$metadata$ = {
|
4736 | kind: Kotlin.Kind.CLASS,
|
4737 | simpleName: null,
|
4738 | interfaces: [CoroutineImpl]
|
4739 | };
|
4740 | Coroutine$get_ytbaoo$.prototype = Object.create(CoroutineImpl.prototype);
|
4741 | Coroutine$get_ytbaoo$.prototype.constructor = Coroutine$get_ytbaoo$;
|
4742 | Coroutine$get_ytbaoo$.prototype.doResume = function () {
|
4743 | do
|
4744 | try {
|
4745 | switch (this.state_0) {
|
4746 | case 0:
|
4747 | var tmp$;
|
4748 | this.state_0 = 2;
|
4749 | this.result_0 = this.$this.getPersist_0(this);
|
4750 | if (this.result_0 === COROUTINE_SUSPENDED)
|
4751 | return COROUTINE_SUSPENDED;
|
4752 | continue;
|
4753 | case 1:
|
4754 | throw this.exception_0;
|
4755 | case 2:
|
4756 | this.state_0 = 3;
|
4757 | this.result_0 = await_0(Kotlin.isType(tmp$ = this.result_0.getItem(this.local$key), Promise) ? tmp$ : throwCCE(), this);
|
4758 | if (this.result_0 === COROUTINE_SUSPENDED)
|
4759 | return COROUTINE_SUSPENDED;
|
4760 | continue;
|
4761 | case 3:
|
4762 | this.local$tmp$_0 = this.result_0;
|
4763 | if (this.local$tmp$_0 == null) {
|
4764 | return null;
|
4765 | } else {
|
4766 | this.state_0 = 4;
|
4767 | continue;
|
4768 | }
|
4769 |
|
4770 | case 4:
|
4771 | var string = this.local$tmp$_0;
|
4772 | this.local$stringContents = split(string, ['#'], void 0, 3);
|
4773 | if (this.local$stringContents.size !== 3) {
|
4774 | return null;
|
4775 | } else {
|
4776 | this.state_0 = 5;
|
4777 | continue;
|
4778 | }
|
4779 |
|
4780 | case 5:
|
4781 | var version = this.local$stringContents.get_za3lpa$(0);
|
4782 | this.local$lastModified = this.local$stringContents.get_za3lpa$(1);
|
4783 | this.local$json = this.local$stringContents.get_za3lpa$(2);
|
4784 | if (!equals(version, this.$this.getVersion_0())) {
|
4785 | return null;
|
4786 | } else {
|
4787 | this.state_0 = 6;
|
4788 | continue;
|
4789 | }
|
4790 |
|
4791 | case 6:
|
4792 | if (Date.now() - toLong(this.local$lastModified).toNumber() < this.$this.cacheDuration.toNumber()) {
|
4793 | return null;
|
4794 | } else {
|
4795 | this.state_0 = 7;
|
4796 | continue;
|
4797 | }
|
4798 |
|
4799 | case 7:
|
4800 | return startsWith(this.local$json, '{') ? JSON.parse(this.local$json) : null;
|
4801 | default:this.state_0 = 1;
|
4802 | throw new Error('State Machine Unreachable execution');
|
4803 | }
|
4804 | } catch (e) {
|
4805 | if (this.state_0 === 1) {
|
4806 | this.exceptionState_0 = this.state_0;
|
4807 | throw e;
|
4808 | } else {
|
4809 | this.state_0 = this.exceptionState_0;
|
4810 | this.exception_0 = e;
|
4811 | }
|
4812 | }
|
4813 | while (true);
|
4814 | };
|
4815 | DiskCache.prototype.get_ytbaoo$ = function (key_0, continuation_0, suspended) {
|
4816 | var instance = new Coroutine$get_ytbaoo$(this, key_0, continuation_0);
|
4817 | if (suspended)
|
4818 | return instance;
|
4819 | else
|
4820 | return instance.doResume(null);
|
4821 | };
|
4822 | DiskCache.$metadata$ = {
|
4823 | kind: Kind_CLASS,
|
4824 | simpleName: 'DiskCache',
|
4825 | interfaces: [Cache]
|
4826 | };
|
4827 | function MemoryCache(underlyingCache) {
|
4828 | if (underlyingCache === void 0)
|
4829 | underlyingCache = NoCache_getInstance();
|
4830 | this.underlyingCache = underlyingCache;
|
4831 | this.map_0 = HashMap_init();
|
4832 | }
|
4833 | function Coroutine$set_bm4g0d$_0($this, key_0, value_0, continuation_0) {
|
4834 | CoroutineImpl.call(this, continuation_0);
|
4835 | this.exceptionState_0 = 1;
|
4836 | this.$this = $this;
|
4837 | this.local$key = key_0;
|
4838 | this.local$value = value_0;
|
4839 | }
|
4840 | Coroutine$set_bm4g0d$_0.$metadata$ = {
|
4841 | kind: Kotlin.Kind.CLASS,
|
4842 | simpleName: null,
|
4843 | interfaces: [CoroutineImpl]
|
4844 | };
|
4845 | Coroutine$set_bm4g0d$_0.prototype = Object.create(CoroutineImpl.prototype);
|
4846 | Coroutine$set_bm4g0d$_0.prototype.constructor = Coroutine$set_bm4g0d$_0;
|
4847 | Coroutine$set_bm4g0d$_0.prototype.doResume = function () {
|
4848 | do
|
4849 | try {
|
4850 | switch (this.state_0) {
|
4851 | case 0:
|
4852 | this.$this.map_0.put_xwzc9p$(this.local$key, this.local$value);
|
4853 | this.state_0 = 2;
|
4854 | this.result_0 = this.$this.underlyingCache.set_bm4g0d$(this.local$key, this.local$value, this);
|
4855 | if (this.result_0 === COROUTINE_SUSPENDED)
|
4856 | return COROUTINE_SUSPENDED;
|
4857 | continue;
|
4858 | case 1:
|
4859 | throw this.exception_0;
|
4860 | case 2:
|
4861 | return;
|
4862 | default:this.state_0 = 1;
|
4863 | throw new Error('State Machine Unreachable execution');
|
4864 | }
|
4865 | } catch (e) {
|
4866 | if (this.state_0 === 1) {
|
4867 | this.exceptionState_0 = this.state_0;
|
4868 | throw e;
|
4869 | } else {
|
4870 | this.state_0 = this.exceptionState_0;
|
4871 | this.exception_0 = e;
|
4872 | }
|
4873 | }
|
4874 | while (true);
|
4875 | };
|
4876 | MemoryCache.prototype.set_bm4g0d$ = function (key_0, value_0, continuation_0, suspended) {
|
4877 | var instance = new Coroutine$set_bm4g0d$_0(this, key_0, value_0, continuation_0);
|
4878 | if (suspended)
|
4879 | return instance;
|
4880 | else
|
4881 | return instance.doResume(null);
|
4882 | };
|
4883 | function Coroutine$get_ytbaoo$_0($this, key_0, continuation_0) {
|
4884 | CoroutineImpl.call(this, continuation_0);
|
4885 | this.exceptionState_0 = 1;
|
4886 | this.$this = $this;
|
4887 | this.local$tmp$ = void 0;
|
4888 | this.local$key = key_0;
|
4889 | }
|
4890 | Coroutine$get_ytbaoo$_0.$metadata$ = {
|
4891 | kind: Kotlin.Kind.CLASS,
|
4892 | simpleName: null,
|
4893 | interfaces: [CoroutineImpl]
|
4894 | };
|
4895 | Coroutine$get_ytbaoo$_0.prototype = Object.create(CoroutineImpl.prototype);
|
4896 | Coroutine$get_ytbaoo$_0.prototype.constructor = Coroutine$get_ytbaoo$_0;
|
4897 | Coroutine$get_ytbaoo$_0.prototype.doResume = function () {
|
4898 | do
|
4899 | try {
|
4900 | switch (this.state_0) {
|
4901 | case 0:
|
4902 | var tmp$;
|
4903 | this.local$tmp$ = this.$this.map_0.get_11rb$(this.local$key);
|
4904 | if (this.local$tmp$ == null) {
|
4905 | this.state_0 = 2;
|
4906 | this.result_0 = this.$this.underlyingCache.get_ytbaoo$(this.local$key, this);
|
4907 | if (this.result_0 === COROUTINE_SUSPENDED)
|
4908 | return COROUTINE_SUSPENDED;
|
4909 | continue;
|
4910 | } else {
|
4911 | this.state_0 = 3;
|
4912 | continue;
|
4913 | }
|
4914 |
|
4915 | case 1:
|
4916 | throw this.exception_0;
|
4917 | case 2:
|
4918 | this.local$tmp$ = this.result_0;
|
4919 | this.state_0 = 3;
|
4920 | continue;
|
4921 | case 3:
|
4922 | return (tmp$ = this.local$tmp$) == null || Kotlin.isType(tmp$, Any) ? tmp$ : null;
|
4923 | default:this.state_0 = 1;
|
4924 | throw new Error('State Machine Unreachable execution');
|
4925 | }
|
4926 | } catch (e) {
|
4927 | if (this.state_0 === 1) {
|
4928 | this.exceptionState_0 = this.state_0;
|
4929 | throw e;
|
4930 | } else {
|
4931 | this.state_0 = this.exceptionState_0;
|
4932 | this.exception_0 = e;
|
4933 | }
|
4934 | }
|
4935 | while (true);
|
4936 | };
|
4937 | MemoryCache.prototype.get_ytbaoo$ = function (key_0, continuation_0, suspended) {
|
4938 | var instance = new Coroutine$get_ytbaoo$_0(this, key_0, continuation_0);
|
4939 | if (suspended)
|
4940 | return instance;
|
4941 | else
|
4942 | return instance.doResume(null);
|
4943 | };
|
4944 | MemoryCache.$metadata$ = {
|
4945 | kind: Kind_CLASS,
|
4946 | simpleName: 'MemoryCache',
|
4947 | interfaces: [Cache]
|
4948 | };
|
4949 | var package$me = _.me || (_.me = {});
|
4950 | var package$jfenn = package$me.jfenn || (package$me.jfenn = {});
|
4951 | var package$gitrest = package$jfenn.gitrest || (package$jfenn.gitrest = {});
|
4952 | package$gitrest.gitrest_vws507$ = gitrest;
|
4953 | package$gitrest.GitrestClient = GitrestClient;
|
4954 | var package$base = package$gitrest.base || (package$gitrest.base = {});
|
4955 | package$base.RequestProvider = RequestProvider;
|
4956 | package$base.ServiceBuilder = ServiceBuilder;
|
4957 | var package$model = package$gitrest.model || (package$gitrest.model = {});
|
4958 | package$model.DelegateResource = DelegateResource;
|
4959 | package$model.GitrestConfig = GitrestConfig;
|
4960 | package$model.License = License;
|
4961 | package$model.ProviderString_init_wdz5eb$ = ProviderString_init;
|
4962 | package$model.ProviderString_init_6hosri$ = ProviderString_init_0;
|
4963 | package$model.ProviderString_init_61zpoe$ = ProviderString_init_1;
|
4964 | package$model.ProviderString = ProviderString;
|
4965 | package$model.Repo = Repo;
|
4966 | Object.defineProperty(UrlType, 'HTTP', {
|
4967 | get: UrlType$HTTP_getInstance
|
4968 | });
|
4969 | Object.defineProperty(UrlType, 'HTTPS', {
|
4970 | get: UrlType$HTTPS_getInstance
|
4971 | });
|
4972 | Object.defineProperty(UrlType, 'SSH', {
|
4973 | get: UrlType$SSH_getInstance
|
4974 | });
|
4975 | package$model.UrlType = UrlType;
|
4976 | package$model.User = User;
|
4977 | $$importsForInline$$['ktor-ktor-client-core-jsLegacy'] = $module$ktor_ktor_client_core_jsLegacy;
|
4978 | Object.defineProperty(GiteaProvider, 'Companion', {
|
4979 | get: GiteaProvider$Companion_getInstance
|
4980 | });
|
4981 | var package$provider = package$gitrest.provider || (package$gitrest.provider = {});
|
4982 | var package$gitea = package$provider.gitea || (package$provider.gitea = {});
|
4983 | package$gitea.GiteaProvider = GiteaProvider;
|
4984 | Object.defineProperty(GiteaRepo, 'Companion', {
|
4985 | get: GiteaRepo$Companion_getInstance
|
4986 | });
|
4987 | Object.defineProperty(GiteaRepo, '$serializer', {
|
4988 | get: GiteaRepo$$serializer_getInstance
|
4989 | });
|
4990 | var package$model_0 = package$gitea.model || (package$gitea.model = {});
|
4991 | package$model_0.GiteaRepo_init_d04kao$ = GiteaRepo_init;
|
4992 | package$model_0.GiteaRepo = GiteaRepo;
|
4993 | Object.defineProperty(GiteaUser, 'Companion', {
|
4994 | get: GiteaUser$Companion_getInstance
|
4995 | });
|
4996 | Object.defineProperty(GiteaUser, '$serializer', {
|
4997 | get: GiteaUser$$serializer_getInstance
|
4998 | });
|
4999 | package$model_0.GiteaUser_init_6zcyl3$ = GiteaUser_init;
|
5000 | package$model_0.GiteaUser = GiteaUser;
|
5001 | Object.defineProperty(GithubProvider, 'Companion', {
|
5002 | get: GithubProvider$Companion_getInstance
|
5003 | });
|
5004 | var package$github = package$provider.github || (package$provider.github = {});
|
5005 | package$github.GithubProvider = GithubProvider;
|
5006 | Object.defineProperty(GithubLicense, 'Companion', {
|
5007 | get: GithubLicense$Companion_getInstance
|
5008 | });
|
5009 | Object.defineProperty(GithubLicense, '$serializer', {
|
5010 | get: GithubLicense$$serializer_getInstance
|
5011 | });
|
5012 | var package$model_1 = package$github.model || (package$github.model = {});
|
5013 | package$model_1.GithubLicense_init_n27od7$ = GithubLicense_init;
|
5014 | package$model_1.GithubLicense = GithubLicense;
|
5015 | Object.defineProperty(GithubRepo, 'Companion', {
|
5016 | get: GithubRepo$Companion_getInstance
|
5017 | });
|
5018 | Object.defineProperty(GithubRepo, '$serializer', {
|
5019 | get: GithubRepo$$serializer_getInstance
|
5020 | });
|
5021 | package$model_1.GithubRepo_init_l3yca3$ = GithubRepo_init;
|
5022 | package$model_1.GithubRepo = GithubRepo;
|
5023 | Object.defineProperty(GithubUser, 'Companion', {
|
5024 | get: GithubUser$Companion_getInstance
|
5025 | });
|
5026 | Object.defineProperty(GithubUser, '$serializer', {
|
5027 | get: GithubUser$$serializer_getInstance
|
5028 | });
|
5029 | package$model_1.GithubUser_init_d04kao$ = GithubUser_init;
|
5030 | package$model_1.GithubUser = GithubUser;
|
5031 | Object.defineProperty(GitlabProvider, 'Companion', {
|
5032 | get: GitlabProvider$Companion_getInstance
|
5033 | });
|
5034 | var package$gitlab = package$provider.gitlab || (package$provider.gitlab = {});
|
5035 | package$gitlab.GitlabProvider = GitlabProvider;
|
5036 | Object.defineProperty(GitlabLicense, 'Companion', {
|
5037 | get: GitlabLicense$Companion_getInstance
|
5038 | });
|
5039 | Object.defineProperty(GitlabLicense, '$serializer', {
|
5040 | get: GitlabLicense$$serializer_getInstance
|
5041 | });
|
5042 | var package$model_2 = package$gitlab.model || (package$gitlab.model = {});
|
5043 | package$model_2.GitlabLicense_init_k68y0e$ = GitlabLicense_init;
|
5044 | package$model_2.GitlabLicense = GitlabLicense;
|
5045 | Object.defineProperty(GitlabRepo, 'Companion', {
|
5046 | get: GitlabRepo$Companion_getInstance
|
5047 | });
|
5048 | Object.defineProperty(GitlabRepo, '$serializer', {
|
5049 | get: GitlabRepo$$serializer_getInstance
|
5050 | });
|
5051 | package$model_2.GitlabRepo_init_ba7t8s$ = GitlabRepo_init;
|
5052 | package$model_2.GitlabRepo = GitlabRepo;
|
5053 | Object.defineProperty(GitlabUser, 'Companion', {
|
5054 | get: GitlabUser$Companion_getInstance
|
5055 | });
|
5056 | Object.defineProperty(GitlabUser, '$serializer', {
|
5057 | get: GitlabUser$$serializer_getInstance
|
5058 | });
|
5059 | package$model_2.GitlabUser_init_d04kao$ = GitlabUser_init;
|
5060 | package$model_2.GitlabUser = GitlabUser;
|
5061 | var package$service = package$gitrest.service || (package$gitrest.service = {});
|
5062 | package$service.Cache = Cache;
|
5063 | Object.defineProperty(package$service, 'NoCache', {
|
5064 | get: NoCache_getInstance
|
5065 | });
|
5066 | var package$util = package$gitrest.util || (package$gitrest.util = {});
|
5067 | Object.defineProperty(package$util, 'DEFAULT_PROVIDERS', {
|
5068 | get: function () {
|
5069 | return DEFAULT_PROVIDERS;
|
5070 | }
|
5071 | });
|
5072 | package$util.OptionalStringSerializer = OptionalStringSerializer;
|
5073 | _.Client = Client;
|
5074 | package$model.PlatformConfig = PlatformConfig;
|
5075 | package$service.DiskCache = DiskCache;
|
5076 | package$service.MemoryCache = MemoryCache;
|
5077 | GiteaProvider$Companion.prototype.ktor_1v6kay$ = ServiceBuilder.prototype.ktor_1v6kay$;
|
5078 | GiteaRepo$$serializer.prototype.typeParametersSerializers = GeneratedSerializer.prototype.typeParametersSerializers;
|
5079 | GiteaUser$$serializer.prototype.typeParametersSerializers = GeneratedSerializer.prototype.typeParametersSerializers;
|
5080 | GithubProvider$Companion.prototype.ktor_1v6kay$ = ServiceBuilder.prototype.ktor_1v6kay$;
|
5081 | GithubLicense$$serializer.prototype.typeParametersSerializers = GeneratedSerializer.prototype.typeParametersSerializers;
|
5082 | GithubRepo$$serializer.prototype.typeParametersSerializers = GeneratedSerializer.prototype.typeParametersSerializers;
|
5083 | GithubUser$$serializer.prototype.typeParametersSerializers = GeneratedSerializer.prototype.typeParametersSerializers;
|
5084 | GitlabProvider$Companion.prototype.ktor_1v6kay$ = ServiceBuilder.prototype.ktor_1v6kay$;
|
5085 | GitlabLicense$$serializer.prototype.typeParametersSerializers = GeneratedSerializer.prototype.typeParametersSerializers;
|
5086 | GitlabRepo$$serializer.prototype.typeParametersSerializers = GeneratedSerializer.prototype.typeParametersSerializers;
|
5087 | GitlabUser$$serializer.prototype.typeParametersSerializers = GeneratedSerializer.prototype.typeParametersSerializers;
|
5088 | DEFAULT_PROVIDERS = [ProviderString_init('github', 'api.github.com'), ProviderString_init('gitlab', 'gitlab.com'), ProviderString_init('gitea', 'codeberg.org')];
|
5089 | Kotlin.defineModule('git-rest-wrapper-gitrest', _);
|
5090 | return _;
|
5091 | }));
|
5092 |
|
5093 |
|