@salesforce/lds-adapters-service-gis 1.370.0 → 1.372.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,7 +4,7 @@
4
4
  * For full license text, see the LICENSE.txt file
5
5
  */
6
6
 
7
- import { serializeStructuredKey, ingestShape, deepFreeze, StoreKeyMap, createResourceParams as createResourceParams$2, typeCheckConfig as typeCheckConfig$2, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$1 } from '@luvio/engine';
7
+ import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$4, typeCheckConfig as typeCheckConfig$5, StoreKeyMap, createResourceParams as createResourceParams$5 } from '@luvio/engine';
8
8
 
9
9
  const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
10
10
  const { keys: ObjectKeys, create: ObjectCreate } = Object;
@@ -91,9 +91,237 @@ function createLink(ref) {
91
91
  };
92
92
  }
93
93
 
94
- const TTL$1 = 300;
95
- const VERSION$1 = "0f69e4358dd6aed8111c869611c4526c";
96
- function validate$1(obj, path = 'GisExternalAuthIdentityProviderOutputRepresentation') {
94
+ const TTL$6 = 300;
95
+ const VERSION$6 = "534766993185fd21f5aac8e706c226bf";
96
+ function validate$6(obj, path = 'GisExternalAccessTokenOutputRepresentation') {
97
+ const v_error = (() => {
98
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
99
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
100
+ }
101
+ const obj_expiresIn = obj.expiresIn;
102
+ const path_expiresIn = path + '.expiresIn';
103
+ if (typeof obj_expiresIn !== 'number' || (typeof obj_expiresIn === 'number' && Math.floor(obj_expiresIn) !== obj_expiresIn)) {
104
+ return new TypeError('Expected "integer" but received "' + typeof obj_expiresIn + '" (at "' + path_expiresIn + '")');
105
+ }
106
+ const obj_token = obj.token;
107
+ const path_token = path + '.token';
108
+ if (typeof obj_token !== 'string') {
109
+ return new TypeError('Expected "string" but received "' + typeof obj_token + '" (at "' + path_token + '")');
110
+ }
111
+ const obj_type = obj.type;
112
+ const path_type = path + '.type';
113
+ if (typeof obj_type !== 'string') {
114
+ return new TypeError('Expected "string" but received "' + typeof obj_type + '" (at "' + path_type + '")');
115
+ }
116
+ })();
117
+ return v_error === undefined ? null : v_error;
118
+ }
119
+ const RepresentationType$6 = 'GisExternalAccessTokenOutputRepresentation';
120
+ function normalize$6(input, existing, path, luvio, store, timestamp) {
121
+ return input;
122
+ }
123
+ const select$b = function GisExternalAccessTokenOutputRepresentationSelect() {
124
+ return {
125
+ kind: 'Fragment',
126
+ version: VERSION$6,
127
+ private: [],
128
+ selections: [
129
+ {
130
+ name: 'expiresIn',
131
+ kind: 'Scalar'
132
+ },
133
+ {
134
+ name: 'token',
135
+ kind: 'Scalar'
136
+ },
137
+ {
138
+ name: 'type',
139
+ kind: 'Scalar'
140
+ }
141
+ ]
142
+ };
143
+ };
144
+ function equals$6(existing, incoming) {
145
+ const existing_expiresIn = existing.expiresIn;
146
+ const incoming_expiresIn = incoming.expiresIn;
147
+ if (!(existing_expiresIn === incoming_expiresIn)) {
148
+ return false;
149
+ }
150
+ const existing_token = existing.token;
151
+ const incoming_token = incoming.token;
152
+ if (!(existing_token === incoming_token)) {
153
+ return false;
154
+ }
155
+ const existing_type = existing.type;
156
+ const incoming_type = incoming.type;
157
+ if (!(existing_type === incoming_type)) {
158
+ return false;
159
+ }
160
+ return true;
161
+ }
162
+ const ingest$6 = function GisExternalAccessTokenOutputRepresentationIngest(input, path, luvio, store, timestamp) {
163
+ if (process.env.NODE_ENV !== 'production') {
164
+ const validateError = validate$6(input);
165
+ if (validateError !== null) {
166
+ throw validateError;
167
+ }
168
+ }
169
+ const key = path.fullPath;
170
+ const ttlToUse = TTL$6;
171
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$6, "gis", VERSION$6, RepresentationType$6, equals$6);
172
+ return createLink(key);
173
+ };
174
+ function getTypeCacheKeys$6(rootKeySet, luvio, input, fullPathFactory) {
175
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
176
+ const rootKey = fullPathFactory();
177
+ rootKeySet.set(rootKey, {
178
+ namespace: keyPrefix,
179
+ representationName: RepresentationType$6,
180
+ mergeable: false
181
+ });
182
+ }
183
+
184
+ function select$a(luvio, params) {
185
+ return select$b();
186
+ }
187
+ function keyBuilder$a(luvio, params) {
188
+ return keyPrefix + '::GisExternalAccessTokenOutputRepresentation:(' + 'authSettingsId:' + params.queryParams.authSettingsId + ')';
189
+ }
190
+ function getResponseCacheKeys$4(storeKeyMap, luvio, resourceParams, response) {
191
+ getTypeCacheKeys$6(storeKeyMap, luvio, response, () => keyBuilder$a(luvio, resourceParams));
192
+ }
193
+ function ingestSuccess$4(luvio, resourceParams, response, snapshotRefresh) {
194
+ const { body } = response;
195
+ const key = keyBuilder$a(luvio, resourceParams);
196
+ luvio.storeIngest(key, ingest$6, body);
197
+ const snapshot = luvio.storeLookup({
198
+ recordId: key,
199
+ node: select$a(),
200
+ variables: {},
201
+ }, snapshotRefresh);
202
+ if (process.env.NODE_ENV !== 'production') {
203
+ if (snapshot.state !== 'Fulfilled') {
204
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
205
+ }
206
+ }
207
+ deepFreeze(snapshot.data);
208
+ return snapshot;
209
+ }
210
+ function ingestError$3(luvio, params, error, snapshotRefresh) {
211
+ const key = keyBuilder$a(luvio, params);
212
+ const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
213
+ const storeMetadataParams = {
214
+ ttl: TTL$6,
215
+ namespace: keyPrefix,
216
+ version: VERSION$6,
217
+ representationName: RepresentationType$6
218
+ };
219
+ luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
220
+ return errorSnapshot;
221
+ }
222
+ function createResourceRequest$4(config) {
223
+ const headers = {};
224
+ return {
225
+ baseUri: '/services/data/v65.0',
226
+ basePath: '/gis/auth/GisExternalAccessToken',
227
+ method: 'get',
228
+ body: null,
229
+ urlParams: {},
230
+ queryParams: config.queryParams,
231
+ headers,
232
+ priority: 'normal',
233
+ };
234
+ }
235
+
236
+ const adapterName$4 = 'getGisExternalAuthAccessToken';
237
+ const getGisExternalAuthAccessToken_ConfigPropertyMetadata = [
238
+ generateParamConfigMetadata('authSettingsId', true, 1 /* QueryParameter */, 0 /* String */),
239
+ ];
240
+ const getGisExternalAuthAccessToken_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$4, getGisExternalAuthAccessToken_ConfigPropertyMetadata);
241
+ const createResourceParams$4 = /*#__PURE__*/ createResourceParams$5(getGisExternalAuthAccessToken_ConfigPropertyMetadata);
242
+ function keyBuilder$9(luvio, config) {
243
+ const resourceParams = createResourceParams$4(config);
244
+ return keyBuilder$a(luvio, resourceParams);
245
+ }
246
+ function typeCheckConfig$4(untrustedConfig) {
247
+ const config = {};
248
+ typeCheckConfig$5(untrustedConfig, config, getGisExternalAuthAccessToken_ConfigPropertyMetadata);
249
+ return config;
250
+ }
251
+ function validateAdapterConfig$4(untrustedConfig, configPropertyNames) {
252
+ if (!untrustedIsObject(untrustedConfig)) {
253
+ return null;
254
+ }
255
+ if (process.env.NODE_ENV !== 'production') {
256
+ validateConfig(untrustedConfig, configPropertyNames);
257
+ }
258
+ const config = typeCheckConfig$4(untrustedConfig);
259
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
260
+ return null;
261
+ }
262
+ return config;
263
+ }
264
+ function adapterFragment$3(luvio, config) {
265
+ createResourceParams$4(config);
266
+ return select$a();
267
+ }
268
+ function onFetchResponseSuccess$3(luvio, config, resourceParams, response) {
269
+ const snapshot = ingestSuccess$4(luvio, resourceParams, response, {
270
+ config,
271
+ resolve: () => buildNetworkSnapshot$4(luvio, config, snapshotRefreshOptions)
272
+ });
273
+ return luvio.storeBroadcast().then(() => snapshot);
274
+ }
275
+ function onFetchResponseError$3(luvio, config, resourceParams, response) {
276
+ const snapshot = ingestError$3(luvio, resourceParams, response, {
277
+ config,
278
+ resolve: () => buildNetworkSnapshot$4(luvio, config, snapshotRefreshOptions)
279
+ });
280
+ return luvio.storeBroadcast().then(() => snapshot);
281
+ }
282
+ function buildNetworkSnapshot$4(luvio, config, options) {
283
+ const resourceParams = createResourceParams$4(config);
284
+ const request = createResourceRequest$4(resourceParams);
285
+ return luvio.dispatchResourceRequest(request, options)
286
+ .then((response) => {
287
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$3(luvio, config, resourceParams, response), () => {
288
+ const cache = new StoreKeyMap();
289
+ getResponseCacheKeys$4(cache, luvio, resourceParams, response.body);
290
+ return cache;
291
+ });
292
+ }, (response) => {
293
+ return luvio.handleErrorResponse(() => onFetchResponseError$3(luvio, config, resourceParams, response));
294
+ });
295
+ }
296
+ function buildNetworkSnapshotCachePolicy$3(context, coercedAdapterRequestContext) {
297
+ return buildNetworkSnapshotCachePolicy$4(context, coercedAdapterRequestContext, buildNetworkSnapshot$4, undefined, false);
298
+ }
299
+ function buildCachedSnapshotCachePolicy$3(context, storeLookup) {
300
+ const { luvio, config } = context;
301
+ const selector = {
302
+ recordId: keyBuilder$9(luvio, config),
303
+ node: adapterFragment$3(luvio, config),
304
+ variables: {},
305
+ };
306
+ const cacheSnapshot = storeLookup(selector, {
307
+ config,
308
+ resolve: () => buildNetworkSnapshot$4(luvio, config, snapshotRefreshOptions)
309
+ });
310
+ return cacheSnapshot;
311
+ }
312
+ const getGisExternalAuthAccessTokenAdapterFactory = (luvio) => function gis__getGisExternalAuthAccessToken(untrustedConfig, requestContext) {
313
+ const config = validateAdapterConfig$4(untrustedConfig, getGisExternalAuthAccessToken_ConfigPropertyNames);
314
+ // Invalid or incomplete config
315
+ if (config === null) {
316
+ return null;
317
+ }
318
+ return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
319
+ buildCachedSnapshotCachePolicy$3, buildNetworkSnapshotCachePolicy$3);
320
+ };
321
+
322
+ const TTL$5 = 300;
323
+ const VERSION$5 = "0f69e4358dd6aed8111c869611c4526c";
324
+ function validate$5(obj, path = 'GisExternalAuthIdentityProviderOutputRepresentation') {
97
325
  const v_error = (() => {
98
326
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
99
327
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -136,23 +364,23 @@ function validate$1(obj, path = 'GisExternalAuthIdentityProviderOutputRepresenta
136
364
  })();
137
365
  return v_error === undefined ? null : v_error;
138
366
  }
139
- const RepresentationType$1 = 'GisExternalAuthIdentityProviderOutputRepresentation';
140
- function keyBuilder$2(luvio, config) {
141
- return keyPrefix + '::' + RepresentationType$1 + ':' + config.id;
367
+ const RepresentationType$5 = 'GisExternalAuthIdentityProviderOutputRepresentation';
368
+ function keyBuilder$8(luvio, config) {
369
+ return keyPrefix + '::' + RepresentationType$5 + ':' + config.id;
142
370
  }
143
- function keyBuilderFromType(luvio, object) {
371
+ function keyBuilderFromType$2(luvio, object) {
144
372
  const keyParams = {
145
373
  id: object.id
146
374
  };
147
- return keyBuilder$2(luvio, keyParams);
375
+ return keyBuilder$8(luvio, keyParams);
148
376
  }
149
- function normalize$1(input, existing, path, luvio, store, timestamp) {
377
+ function normalize$5(input, existing, path, luvio, store, timestamp) {
150
378
  return input;
151
379
  }
152
- const select$3 = function GisExternalAuthIdentityProviderOutputRepresentationSelect() {
380
+ const select$9 = function GisExternalAuthIdentityProviderOutputRepresentationSelect() {
153
381
  return {
154
382
  kind: 'Fragment',
155
- version: VERSION$1,
383
+ version: VERSION$5,
156
384
  private: [],
157
385
  selections: [
158
386
  {
@@ -186,7 +414,7 @@ const select$3 = function GisExternalAuthIdentityProviderOutputRepresentationSel
186
414
  ]
187
415
  };
188
416
  };
189
- function equals$1(existing, incoming) {
417
+ function equals$5(existing, incoming) {
190
418
  const existing_authType = existing.authType;
191
419
  const incoming_authType = incoming.authType;
192
420
  if (!(existing_authType === incoming_authType)) {
@@ -224,41 +452,41 @@ function equals$1(existing, incoming) {
224
452
  }
225
453
  return true;
226
454
  }
227
- const ingest$1 = function GisExternalAuthIdentityProviderOutputRepresentationIngest(input, path, luvio, store, timestamp) {
455
+ const ingest$5 = function GisExternalAuthIdentityProviderOutputRepresentationIngest(input, path, luvio, store, timestamp) {
228
456
  if (process.env.NODE_ENV !== 'production') {
229
- const validateError = validate$1(input);
457
+ const validateError = validate$5(input);
230
458
  if (validateError !== null) {
231
459
  throw validateError;
232
460
  }
233
461
  }
234
- const key = keyBuilderFromType(luvio, input);
235
- const ttlToUse = TTL$1;
236
- ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$1, "gis", VERSION$1, RepresentationType$1, equals$1);
462
+ const key = keyBuilderFromType$2(luvio, input);
463
+ const ttlToUse = TTL$5;
464
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$5, "gis", VERSION$5, RepresentationType$5, equals$5);
237
465
  return createLink(key);
238
466
  };
239
- function getTypeCacheKeys$1(rootKeySet, luvio, input, fullPathFactory) {
467
+ function getTypeCacheKeys$5(rootKeySet, luvio, input, fullPathFactory) {
240
468
  // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
241
- const rootKey = keyBuilderFromType(luvio, input);
469
+ const rootKey = keyBuilderFromType$2(luvio, input);
242
470
  rootKeySet.set(rootKey, {
243
471
  namespace: keyPrefix,
244
- representationName: RepresentationType$1,
472
+ representationName: RepresentationType$5,
245
473
  mergeable: false
246
474
  });
247
475
  }
248
476
 
249
- function select$2(luvio, params) {
250
- return select$3();
477
+ function select$8(luvio, params) {
478
+ return select$9();
251
479
  }
252
- function getResponseCacheKeys$1(storeKeyMap, luvio, resourceParams, response) {
253
- getTypeCacheKeys$1(storeKeyMap, luvio, response);
480
+ function getResponseCacheKeys$3(storeKeyMap, luvio, resourceParams, response) {
481
+ getTypeCacheKeys$5(storeKeyMap, luvio, response);
254
482
  }
255
- function ingestSuccess$1(luvio, resourceParams, response) {
483
+ function ingestSuccess$3(luvio, resourceParams, response) {
256
484
  const { body } = response;
257
- const key = keyBuilderFromType(luvio, body);
258
- luvio.storeIngest(key, ingest$1, body);
485
+ const key = keyBuilderFromType$2(luvio, body);
486
+ luvio.storeIngest(key, ingest$5, body);
259
487
  const snapshot = luvio.storeLookup({
260
488
  recordId: key,
261
- node: select$2(),
489
+ node: select$8(),
262
490
  variables: {},
263
491
  });
264
492
  if (process.env.NODE_ENV !== 'production') {
@@ -269,7 +497,7 @@ function ingestSuccess$1(luvio, resourceParams, response) {
269
497
  deepFreeze(snapshot.data);
270
498
  return snapshot;
271
499
  }
272
- function createResourceRequest$1(config) {
500
+ function createResourceRequest$3(config) {
273
501
  const headers = {};
274
502
  return {
275
503
  baseUri: '/services/data/v65.0',
@@ -283,7 +511,7 @@ function createResourceRequest$1(config) {
283
511
  };
284
512
  }
285
513
 
286
- const adapterName$1 = 'createGisExternalAuthIdentityProvider';
514
+ const adapterName$3 = 'createGisExternalAuthIdentityProvider';
287
515
  const createGisExternalAuthIdentityProvider_ConfigPropertyMetadata = [
288
516
  generateParamConfigMetadata('authType', true, 2 /* Body */, 0 /* String */),
289
517
  generateParamConfigMetadata('baseUrl', true, 2 /* Body */, 0 /* String */),
@@ -292,37 +520,37 @@ const createGisExternalAuthIdentityProvider_ConfigPropertyMetadata = [
292
520
  generateParamConfigMetadata('gisProvider', true, 2 /* Body */, 0 /* String */),
293
521
  generateParamConfigMetadata('name', true, 2 /* Body */, 0 /* String */),
294
522
  ];
295
- const createGisExternalAuthIdentityProvider_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, createGisExternalAuthIdentityProvider_ConfigPropertyMetadata);
296
- const createResourceParams$1 = /*#__PURE__*/ createResourceParams$2(createGisExternalAuthIdentityProvider_ConfigPropertyMetadata);
297
- function typeCheckConfig$1(untrustedConfig) {
523
+ const createGisExternalAuthIdentityProvider_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$3, createGisExternalAuthIdentityProvider_ConfigPropertyMetadata);
524
+ const createResourceParams$3 = /*#__PURE__*/ createResourceParams$5(createGisExternalAuthIdentityProvider_ConfigPropertyMetadata);
525
+ function typeCheckConfig$3(untrustedConfig) {
298
526
  const config = {};
299
- typeCheckConfig$2(untrustedConfig, config, createGisExternalAuthIdentityProvider_ConfigPropertyMetadata);
527
+ typeCheckConfig$5(untrustedConfig, config, createGisExternalAuthIdentityProvider_ConfigPropertyMetadata);
300
528
  return config;
301
529
  }
302
- function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
530
+ function validateAdapterConfig$3(untrustedConfig, configPropertyNames) {
303
531
  if (!untrustedIsObject(untrustedConfig)) {
304
532
  return null;
305
533
  }
306
534
  if (process.env.NODE_ENV !== 'production') {
307
535
  validateConfig(untrustedConfig, configPropertyNames);
308
536
  }
309
- const config = typeCheckConfig$1(untrustedConfig);
537
+ const config = typeCheckConfig$3(untrustedConfig);
310
538
  if (!areRequiredParametersPresent(config, configPropertyNames)) {
311
539
  return null;
312
540
  }
313
541
  return config;
314
542
  }
315
- function buildNetworkSnapshot$1(luvio, config, options) {
316
- const resourceParams = createResourceParams$1(config);
317
- const request = createResourceRequest$1(resourceParams);
543
+ function buildNetworkSnapshot$3(luvio, config, options) {
544
+ const resourceParams = createResourceParams$3(config);
545
+ const request = createResourceRequest$3(resourceParams);
318
546
  return luvio.dispatchResourceRequest(request, options)
319
547
  .then((response) => {
320
548
  return luvio.handleSuccessResponse(() => {
321
- const snapshot = ingestSuccess$1(luvio, resourceParams, response);
549
+ const snapshot = ingestSuccess$3(luvio, resourceParams, response);
322
550
  return luvio.storeBroadcast().then(() => snapshot);
323
551
  }, () => {
324
552
  const cache = new StoreKeyMap();
325
- getResponseCacheKeys$1(cache, luvio, resourceParams, response.body);
553
+ getResponseCacheKeys$3(cache, luvio, resourceParams, response.body);
326
554
  return cache;
327
555
  });
328
556
  }, (response) => {
@@ -332,18 +560,18 @@ function buildNetworkSnapshot$1(luvio, config, options) {
332
560
  }
333
561
  const createGisExternalAuthIdentityProviderAdapterFactory = (luvio) => {
334
562
  return function createGisExternalAuthIdentityProvider(untrustedConfig) {
335
- const config = validateAdapterConfig$1(untrustedConfig, createGisExternalAuthIdentityProvider_ConfigPropertyNames);
563
+ const config = validateAdapterConfig$3(untrustedConfig, createGisExternalAuthIdentityProvider_ConfigPropertyNames);
336
564
  // Invalid or incomplete config
337
565
  if (config === null) {
338
566
  throw new Error('Invalid config for "createGisExternalAuthIdentityProvider"');
339
567
  }
340
- return buildNetworkSnapshot$1(luvio, config);
568
+ return buildNetworkSnapshot$3(luvio, config);
341
569
  };
342
570
  };
343
571
 
344
- const TTL = 300;
345
- const VERSION = "a7ac614251e70adfb9330b0fcdbfcbf2";
346
- function validate(obj, path = 'GisExternalAuthIdentityProviderCollectionRepresentation') {
572
+ const TTL$4 = 300;
573
+ const VERSION$4 = "a7ac614251e70adfb9330b0fcdbfcbf2";
574
+ function validate$4(obj, path = 'GisExternalAuthIdentityProviderCollectionRepresentation') {
347
575
  const v_error = (() => {
348
576
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
349
577
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -368,14 +596,14 @@ function validate(obj, path = 'GisExternalAuthIdentityProviderCollectionRepresen
368
596
  })();
369
597
  return v_error === undefined ? null : v_error;
370
598
  }
371
- const RepresentationType = 'GisExternalAuthIdentityProviderCollectionRepresentation';
372
- function normalize(input, existing, path, luvio, store, timestamp) {
599
+ const RepresentationType$4 = 'GisExternalAuthIdentityProviderCollectionRepresentation';
600
+ function normalize$4(input, existing, path, luvio, store, timestamp) {
373
601
  const input_gisExternalAuthIdentityProviderOutputRepresentation = input.gisExternalAuthIdentityProviderOutputRepresentation;
374
602
  const input_gisExternalAuthIdentityProviderOutputRepresentation_id = path.fullPath + '__gisExternalAuthIdentityProviderOutputRepresentation';
375
603
  for (let i = 0; i < input_gisExternalAuthIdentityProviderOutputRepresentation.length; i++) {
376
604
  const input_gisExternalAuthIdentityProviderOutputRepresentation_item = input_gisExternalAuthIdentityProviderOutputRepresentation[i];
377
605
  let input_gisExternalAuthIdentityProviderOutputRepresentation_item_id = input_gisExternalAuthIdentityProviderOutputRepresentation_id + '__' + i;
378
- input_gisExternalAuthIdentityProviderOutputRepresentation[i] = ingest$1(input_gisExternalAuthIdentityProviderOutputRepresentation_item, {
606
+ input_gisExternalAuthIdentityProviderOutputRepresentation[i] = ingest$5(input_gisExternalAuthIdentityProviderOutputRepresentation_item, {
379
607
  fullPath: input_gisExternalAuthIdentityProviderOutputRepresentation_item_id,
380
608
  propertyName: i,
381
609
  parent: {
@@ -388,10 +616,10 @@ function normalize(input, existing, path, luvio, store, timestamp) {
388
616
  }
389
617
  return input;
390
618
  }
391
- const select$1 = function GisExternalAuthIdentityProviderCollectionRepresentationSelect() {
619
+ const select$7 = function GisExternalAuthIdentityProviderCollectionRepresentationSelect() {
392
620
  return {
393
621
  kind: 'Fragment',
394
- version: VERSION,
622
+ version: VERSION$4,
395
623
  private: [],
396
624
  selections: [
397
625
  {
@@ -402,12 +630,12 @@ const select$1 = function GisExternalAuthIdentityProviderCollectionRepresentatio
402
630
  name: 'gisExternalAuthIdentityProviderOutputRepresentation',
403
631
  kind: 'Link',
404
632
  plural: true,
405
- fragment: select$3()
633
+ fragment: select$9()
406
634
  }
407
635
  ]
408
636
  };
409
637
  };
410
- function equals(existing, incoming) {
638
+ function equals$4(existing, incoming) {
411
639
  const existing_count = existing.count;
412
640
  const incoming_count = incoming.count;
413
641
  if (!(existing_count === incoming_count)) {
@@ -425,48 +653,48 @@ function equals(existing, incoming) {
425
653
  }
426
654
  return true;
427
655
  }
428
- const ingest = function GisExternalAuthIdentityProviderCollectionRepresentationIngest(input, path, luvio, store, timestamp) {
656
+ const ingest$4 = function GisExternalAuthIdentityProviderCollectionRepresentationIngest(input, path, luvio, store, timestamp) {
429
657
  if (process.env.NODE_ENV !== 'production') {
430
- const validateError = validate(input);
658
+ const validateError = validate$4(input);
431
659
  if (validateError !== null) {
432
660
  throw validateError;
433
661
  }
434
662
  }
435
663
  const key = path.fullPath;
436
- const ttlToUse = TTL;
437
- ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize, "gis", VERSION, RepresentationType, equals);
664
+ const ttlToUse = TTL$4;
665
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$4, "gis", VERSION$4, RepresentationType$4, equals$4);
438
666
  return createLink(key);
439
667
  };
440
- function getTypeCacheKeys(rootKeySet, luvio, input, fullPathFactory) {
668
+ function getTypeCacheKeys$4(rootKeySet, luvio, input, fullPathFactory) {
441
669
  // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
442
670
  const rootKey = fullPathFactory();
443
671
  rootKeySet.set(rootKey, {
444
672
  namespace: keyPrefix,
445
- representationName: RepresentationType,
673
+ representationName: RepresentationType$4,
446
674
  mergeable: false
447
675
  });
448
676
  const input_gisExternalAuthIdentityProviderOutputRepresentation_length = input.gisExternalAuthIdentityProviderOutputRepresentation.length;
449
677
  for (let i = 0; i < input_gisExternalAuthIdentityProviderOutputRepresentation_length; i++) {
450
- getTypeCacheKeys$1(rootKeySet, luvio, input.gisExternalAuthIdentityProviderOutputRepresentation[i]);
678
+ getTypeCacheKeys$5(rootKeySet, luvio, input.gisExternalAuthIdentityProviderOutputRepresentation[i]);
451
679
  }
452
680
  }
453
681
 
454
- function select(luvio, params) {
455
- return select$1();
682
+ function select$6(luvio, params) {
683
+ return select$7();
456
684
  }
457
- function keyBuilder$1(luvio, params) {
685
+ function keyBuilder$7(luvio, params) {
458
686
  return keyPrefix + '::GisExternalAuthIdentityProviderCollectionRepresentation:(' + 'limitByProfile:' + params.queryParams.limitByProfile + ')';
459
687
  }
460
- function getResponseCacheKeys(storeKeyMap, luvio, resourceParams, response) {
461
- getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$1(luvio, resourceParams));
688
+ function getResponseCacheKeys$2(storeKeyMap, luvio, resourceParams, response) {
689
+ getTypeCacheKeys$4(storeKeyMap, luvio, response, () => keyBuilder$7(luvio, resourceParams));
462
690
  }
463
- function ingestSuccess(luvio, resourceParams, response, snapshotRefresh) {
691
+ function ingestSuccess$2(luvio, resourceParams, response, snapshotRefresh) {
464
692
  const { body } = response;
465
- const key = keyBuilder$1(luvio, resourceParams);
466
- luvio.storeIngest(key, ingest, body);
693
+ const key = keyBuilder$7(luvio, resourceParams);
694
+ luvio.storeIngest(key, ingest$4, body);
467
695
  const snapshot = luvio.storeLookup({
468
696
  recordId: key,
469
- node: select(),
697
+ node: select$6(),
470
698
  variables: {},
471
699
  }, snapshotRefresh);
472
700
  if (process.env.NODE_ENV !== 'production') {
@@ -477,19 +705,19 @@ function ingestSuccess(luvio, resourceParams, response, snapshotRefresh) {
477
705
  deepFreeze(snapshot.data);
478
706
  return snapshot;
479
707
  }
480
- function ingestError(luvio, params, error, snapshotRefresh) {
481
- const key = keyBuilder$1(luvio, params);
708
+ function ingestError$2(luvio, params, error, snapshotRefresh) {
709
+ const key = keyBuilder$7(luvio, params);
482
710
  const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
483
711
  const storeMetadataParams = {
484
- ttl: TTL,
712
+ ttl: TTL$4,
485
713
  namespace: keyPrefix,
486
- version: VERSION,
487
- representationName: RepresentationType
714
+ version: VERSION$4,
715
+ representationName: RepresentationType$4
488
716
  };
489
717
  luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
490
718
  return errorSnapshot;
491
719
  }
492
- function createResourceRequest(config) {
720
+ function createResourceRequest$2(config) {
493
721
  const headers = {};
494
722
  return {
495
723
  baseUri: '/services/data/v65.0',
@@ -503,84 +731,920 @@ function createResourceRequest(config) {
503
731
  };
504
732
  }
505
733
 
506
- const adapterName = 'getGisExternalAuthIdentityProviders';
734
+ const adapterName$2 = 'getGisExternalAuthIdentityProviders';
507
735
  const getGisExternalAuthIdentityProviders_ConfigPropertyMetadata = [
508
736
  generateParamConfigMetadata('limitByProfile', true, 1 /* QueryParameter */, 1 /* Boolean */),
509
737
  ];
510
- const getGisExternalAuthIdentityProviders_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, getGisExternalAuthIdentityProviders_ConfigPropertyMetadata);
511
- const createResourceParams = /*#__PURE__*/ createResourceParams$2(getGisExternalAuthIdentityProviders_ConfigPropertyMetadata);
512
- function keyBuilder(luvio, config) {
513
- const resourceParams = createResourceParams(config);
514
- return keyBuilder$1(luvio, resourceParams);
738
+ const getGisExternalAuthIdentityProviders_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$2, getGisExternalAuthIdentityProviders_ConfigPropertyMetadata);
739
+ const createResourceParams$2 = /*#__PURE__*/ createResourceParams$5(getGisExternalAuthIdentityProviders_ConfigPropertyMetadata);
740
+ function keyBuilder$6(luvio, config) {
741
+ const resourceParams = createResourceParams$2(config);
742
+ return keyBuilder$7(luvio, resourceParams);
515
743
  }
516
- function typeCheckConfig(untrustedConfig) {
744
+ function typeCheckConfig$2(untrustedConfig) {
517
745
  const config = {};
518
- typeCheckConfig$2(untrustedConfig, config, getGisExternalAuthIdentityProviders_ConfigPropertyMetadata);
746
+ typeCheckConfig$5(untrustedConfig, config, getGisExternalAuthIdentityProviders_ConfigPropertyMetadata);
519
747
  return config;
520
748
  }
521
- function validateAdapterConfig(untrustedConfig, configPropertyNames) {
749
+ function validateAdapterConfig$2(untrustedConfig, configPropertyNames) {
522
750
  if (!untrustedIsObject(untrustedConfig)) {
523
751
  return null;
524
752
  }
525
753
  if (process.env.NODE_ENV !== 'production') {
526
754
  validateConfig(untrustedConfig, configPropertyNames);
527
755
  }
528
- const config = typeCheckConfig(untrustedConfig);
756
+ const config = typeCheckConfig$2(untrustedConfig);
529
757
  if (!areRequiredParametersPresent(config, configPropertyNames)) {
530
758
  return null;
531
759
  }
532
760
  return config;
533
761
  }
534
- function adapterFragment(luvio, config) {
535
- createResourceParams(config);
536
- return select();
762
+ function adapterFragment$2(luvio, config) {
763
+ createResourceParams$2(config);
764
+ return select$6();
537
765
  }
538
- function onFetchResponseSuccess(luvio, config, resourceParams, response) {
539
- const snapshot = ingestSuccess(luvio, resourceParams, response, {
766
+ function onFetchResponseSuccess$2(luvio, config, resourceParams, response) {
767
+ const snapshot = ingestSuccess$2(luvio, resourceParams, response, {
540
768
  config,
541
- resolve: () => buildNetworkSnapshot(luvio, config, snapshotRefreshOptions)
769
+ resolve: () => buildNetworkSnapshot$2(luvio, config, snapshotRefreshOptions)
542
770
  });
543
771
  return luvio.storeBroadcast().then(() => snapshot);
544
772
  }
545
- function onFetchResponseError(luvio, config, resourceParams, response) {
546
- const snapshot = ingestError(luvio, resourceParams, response, {
773
+ function onFetchResponseError$2(luvio, config, resourceParams, response) {
774
+ const snapshot = ingestError$2(luvio, resourceParams, response, {
547
775
  config,
548
- resolve: () => buildNetworkSnapshot(luvio, config, snapshotRefreshOptions)
776
+ resolve: () => buildNetworkSnapshot$2(luvio, config, snapshotRefreshOptions)
549
777
  });
550
778
  return luvio.storeBroadcast().then(() => snapshot);
551
779
  }
552
- function buildNetworkSnapshot(luvio, config, options) {
553
- const resourceParams = createResourceParams(config);
554
- const request = createResourceRequest(resourceParams);
780
+ function buildNetworkSnapshot$2(luvio, config, options) {
781
+ const resourceParams = createResourceParams$2(config);
782
+ const request = createResourceRequest$2(resourceParams);
555
783
  return luvio.dispatchResourceRequest(request, options)
556
784
  .then((response) => {
557
- return luvio.handleSuccessResponse(() => onFetchResponseSuccess(luvio, config, resourceParams, response), () => {
785
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$2(luvio, config, resourceParams, response), () => {
558
786
  const cache = new StoreKeyMap();
559
- getResponseCacheKeys(cache, luvio, resourceParams, response.body);
787
+ getResponseCacheKeys$2(cache, luvio, resourceParams, response.body);
560
788
  return cache;
561
789
  });
562
790
  }, (response) => {
563
- return luvio.handleErrorResponse(() => onFetchResponseError(luvio, config, resourceParams, response));
791
+ return luvio.handleErrorResponse(() => onFetchResponseError$2(luvio, config, resourceParams, response));
564
792
  });
565
793
  }
566
- function buildNetworkSnapshotCachePolicy(context, coercedAdapterRequestContext) {
567
- return buildNetworkSnapshotCachePolicy$1(context, coercedAdapterRequestContext, buildNetworkSnapshot, undefined, false);
794
+ function buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext) {
795
+ return buildNetworkSnapshotCachePolicy$4(context, coercedAdapterRequestContext, buildNetworkSnapshot$2, undefined, false);
568
796
  }
569
- function buildCachedSnapshotCachePolicy(context, storeLookup) {
797
+ function buildCachedSnapshotCachePolicy$2(context, storeLookup) {
570
798
  const { luvio, config } = context;
571
799
  const selector = {
572
- recordId: keyBuilder(luvio, config),
573
- node: adapterFragment(luvio, config),
800
+ recordId: keyBuilder$6(luvio, config),
801
+ node: adapterFragment$2(luvio, config),
574
802
  variables: {},
575
803
  };
576
804
  const cacheSnapshot = storeLookup(selector, {
577
805
  config,
578
- resolve: () => buildNetworkSnapshot(luvio, config, snapshotRefreshOptions)
806
+ resolve: () => buildNetworkSnapshot$2(luvio, config, snapshotRefreshOptions)
579
807
  });
580
808
  return cacheSnapshot;
581
809
  }
582
810
  const getGisExternalAuthIdentityProvidersAdapterFactory = (luvio) => function gis__getGisExternalAuthIdentityProviders(untrustedConfig, requestContext) {
583
- const config = validateAdapterConfig(untrustedConfig, getGisExternalAuthIdentityProviders_ConfigPropertyNames);
811
+ const config = validateAdapterConfig$2(untrustedConfig, getGisExternalAuthIdentityProviders_ConfigPropertyNames);
812
+ // Invalid or incomplete config
813
+ if (config === null) {
814
+ return null;
815
+ }
816
+ return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
817
+ buildCachedSnapshotCachePolicy$2, buildNetworkSnapshotCachePolicy$2);
818
+ };
819
+
820
+ const TTL$3 = 300;
821
+ const VERSION$3 = "d1f7afbf8cf734038f702e4ff23870c9";
822
+ function validate$3(obj, path = 'GisExtlMapObjectConfigOutputRepresentation') {
823
+ const v_error = (() => {
824
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
825
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
826
+ }
827
+ const obj_defaultMapId = obj.defaultMapId;
828
+ const path_defaultMapId = path + '.defaultMapId';
829
+ if (typeof obj_defaultMapId !== 'string') {
830
+ return new TypeError('Expected "string" but received "' + typeof obj_defaultMapId + '" (at "' + path_defaultMapId + '")');
831
+ }
832
+ const obj_id = obj.id;
833
+ const path_id = path + '.id';
834
+ if (typeof obj_id !== 'string') {
835
+ return new TypeError('Expected "string" but received "' + typeof obj_id + '" (at "' + path_id + '")');
836
+ }
837
+ const obj_mapIdFieldName = obj.mapIdFieldName;
838
+ const path_mapIdFieldName = path + '.mapIdFieldName';
839
+ let obj_mapIdFieldName_union0 = null;
840
+ const obj_mapIdFieldName_union0_error = (() => {
841
+ if (typeof obj_mapIdFieldName !== 'string') {
842
+ return new TypeError('Expected "string" but received "' + typeof obj_mapIdFieldName + '" (at "' + path_mapIdFieldName + '")');
843
+ }
844
+ })();
845
+ if (obj_mapIdFieldName_union0_error != null) {
846
+ obj_mapIdFieldName_union0 = obj_mapIdFieldName_union0_error.message;
847
+ }
848
+ let obj_mapIdFieldName_union1 = null;
849
+ const obj_mapIdFieldName_union1_error = (() => {
850
+ if (obj_mapIdFieldName !== null) {
851
+ return new TypeError('Expected "null" but received "' + typeof obj_mapIdFieldName + '" (at "' + path_mapIdFieldName + '")');
852
+ }
853
+ })();
854
+ if (obj_mapIdFieldName_union1_error != null) {
855
+ obj_mapIdFieldName_union1 = obj_mapIdFieldName_union1_error.message;
856
+ }
857
+ if (obj_mapIdFieldName_union0 && obj_mapIdFieldName_union1) {
858
+ let message = 'Object doesn\'t match union (at "' + path_mapIdFieldName + '")';
859
+ message += '\n' + obj_mapIdFieldName_union0.split('\n').map((line) => '\t' + line).join('\n');
860
+ message += '\n' + obj_mapIdFieldName_union1.split('\n').map((line) => '\t' + line).join('\n');
861
+ return new TypeError(message);
862
+ }
863
+ const obj_objectName = obj.objectName;
864
+ const path_objectName = path + '.objectName';
865
+ if (typeof obj_objectName !== 'string') {
866
+ return new TypeError('Expected "string" but received "' + typeof obj_objectName + '" (at "' + path_objectName + '")');
867
+ }
868
+ const obj_recordType = obj.recordType;
869
+ const path_recordType = path + '.recordType';
870
+ let obj_recordType_union0 = null;
871
+ const obj_recordType_union0_error = (() => {
872
+ if (typeof obj_recordType !== 'string') {
873
+ return new TypeError('Expected "string" but received "' + typeof obj_recordType + '" (at "' + path_recordType + '")');
874
+ }
875
+ })();
876
+ if (obj_recordType_union0_error != null) {
877
+ obj_recordType_union0 = obj_recordType_union0_error.message;
878
+ }
879
+ let obj_recordType_union1 = null;
880
+ const obj_recordType_union1_error = (() => {
881
+ if (obj_recordType !== null) {
882
+ return new TypeError('Expected "null" but received "' + typeof obj_recordType + '" (at "' + path_recordType + '")');
883
+ }
884
+ })();
885
+ if (obj_recordType_union1_error != null) {
886
+ obj_recordType_union1 = obj_recordType_union1_error.message;
887
+ }
888
+ if (obj_recordType_union0 && obj_recordType_union1) {
889
+ let message = 'Object doesn\'t match union (at "' + path_recordType + '")';
890
+ message += '\n' + obj_recordType_union0.split('\n').map((line) => '\t' + line).join('\n');
891
+ message += '\n' + obj_recordType_union1.split('\n').map((line) => '\t' + line).join('\n');
892
+ return new TypeError(message);
893
+ }
894
+ })();
895
+ return v_error === undefined ? null : v_error;
896
+ }
897
+ const RepresentationType$3 = 'GisExtlMapObjectConfigOutputRepresentation';
898
+ function keyBuilder$5(luvio, config) {
899
+ return keyPrefix + '::' + RepresentationType$3 + ':' + config.id;
900
+ }
901
+ function keyBuilderFromType$1(luvio, object) {
902
+ const keyParams = {
903
+ id: object.id
904
+ };
905
+ return keyBuilder$5(luvio, keyParams);
906
+ }
907
+ function normalize$3(input, existing, path, luvio, store, timestamp) {
908
+ return input;
909
+ }
910
+ const select$5 = function GisExtlMapObjectConfigOutputRepresentationSelect() {
911
+ return {
912
+ kind: 'Fragment',
913
+ version: VERSION$3,
914
+ private: [],
915
+ selections: [
916
+ {
917
+ name: 'defaultMapId',
918
+ kind: 'Scalar'
919
+ },
920
+ {
921
+ name: 'id',
922
+ kind: 'Scalar'
923
+ },
924
+ {
925
+ name: 'mapIdFieldName',
926
+ kind: 'Scalar'
927
+ },
928
+ {
929
+ name: 'objectName',
930
+ kind: 'Scalar'
931
+ },
932
+ {
933
+ name: 'recordType',
934
+ kind: 'Scalar'
935
+ }
936
+ ]
937
+ };
938
+ };
939
+ function equals$3(existing, incoming) {
940
+ const existing_defaultMapId = existing.defaultMapId;
941
+ const incoming_defaultMapId = incoming.defaultMapId;
942
+ if (!(existing_defaultMapId === incoming_defaultMapId)) {
943
+ return false;
944
+ }
945
+ const existing_id = existing.id;
946
+ const incoming_id = incoming.id;
947
+ if (!(existing_id === incoming_id)) {
948
+ return false;
949
+ }
950
+ const existing_objectName = existing.objectName;
951
+ const incoming_objectName = incoming.objectName;
952
+ if (!(existing_objectName === incoming_objectName)) {
953
+ return false;
954
+ }
955
+ const existing_mapIdFieldName = existing.mapIdFieldName;
956
+ const incoming_mapIdFieldName = incoming.mapIdFieldName;
957
+ if (!(existing_mapIdFieldName === incoming_mapIdFieldName)) {
958
+ return false;
959
+ }
960
+ const existing_recordType = existing.recordType;
961
+ const incoming_recordType = incoming.recordType;
962
+ if (!(existing_recordType === incoming_recordType)) {
963
+ return false;
964
+ }
965
+ return true;
966
+ }
967
+ const ingest$3 = function GisExtlMapObjectConfigOutputRepresentationIngest(input, path, luvio, store, timestamp) {
968
+ if (process.env.NODE_ENV !== 'production') {
969
+ const validateError = validate$3(input);
970
+ if (validateError !== null) {
971
+ throw validateError;
972
+ }
973
+ }
974
+ const key = keyBuilderFromType$1(luvio, input);
975
+ const ttlToUse = TTL$3;
976
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$3, "gis", VERSION$3, RepresentationType$3, equals$3);
977
+ return createLink(key);
978
+ };
979
+ function getTypeCacheKeys$3(rootKeySet, luvio, input, fullPathFactory) {
980
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
981
+ const rootKey = keyBuilderFromType$1(luvio, input);
982
+ rootKeySet.set(rootKey, {
983
+ namespace: keyPrefix,
984
+ representationName: RepresentationType$3,
985
+ mergeable: false
986
+ });
987
+ }
988
+
989
+ const TTL$2 = 300;
990
+ const VERSION$2 = "9cba8584dbb15a650cd322528530d375";
991
+ function validate$2(obj, path = 'GisExtlMapObjectConfigCollectionRepresentation') {
992
+ const v_error = (() => {
993
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
994
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
995
+ }
996
+ const obj_count = obj.count;
997
+ const path_count = path + '.count';
998
+ if (typeof obj_count !== 'number' || (typeof obj_count === 'number' && Math.floor(obj_count) !== obj_count)) {
999
+ return new TypeError('Expected "integer" but received "' + typeof obj_count + '" (at "' + path_count + '")');
1000
+ }
1001
+ const obj_gisExtlMapObjectConfigs = obj.gisExtlMapObjectConfigs;
1002
+ const path_gisExtlMapObjectConfigs = path + '.gisExtlMapObjectConfigs';
1003
+ if (!ArrayIsArray(obj_gisExtlMapObjectConfigs)) {
1004
+ return new TypeError('Expected "array" but received "' + typeof obj_gisExtlMapObjectConfigs + '" (at "' + path_gisExtlMapObjectConfigs + '")');
1005
+ }
1006
+ for (let i = 0; i < obj_gisExtlMapObjectConfigs.length; i++) {
1007
+ const obj_gisExtlMapObjectConfigs_item = obj_gisExtlMapObjectConfigs[i];
1008
+ const path_gisExtlMapObjectConfigs_item = path_gisExtlMapObjectConfigs + '[' + i + ']';
1009
+ if (typeof obj_gisExtlMapObjectConfigs_item !== 'object' || Array.isArray(obj_gisExtlMapObjectConfigs_item)) {
1010
+ return new TypeError('Expected "object" but received "' + typeof obj_gisExtlMapObjectConfigs_item + '" (at "' + path_gisExtlMapObjectConfigs_item + '")');
1011
+ }
1012
+ }
1013
+ })();
1014
+ return v_error === undefined ? null : v_error;
1015
+ }
1016
+ const RepresentationType$2 = 'GisExtlMapObjectConfigCollectionRepresentation';
1017
+ function normalize$2(input, existing, path, luvio, store, timestamp) {
1018
+ const input_gisExtlMapObjectConfigs = input.gisExtlMapObjectConfigs;
1019
+ const input_gisExtlMapObjectConfigs_id = path.fullPath + '__gisExtlMapObjectConfigs';
1020
+ for (let i = 0; i < input_gisExtlMapObjectConfigs.length; i++) {
1021
+ const input_gisExtlMapObjectConfigs_item = input_gisExtlMapObjectConfigs[i];
1022
+ let input_gisExtlMapObjectConfigs_item_id = input_gisExtlMapObjectConfigs_id + '__' + i;
1023
+ input_gisExtlMapObjectConfigs[i] = ingest$3(input_gisExtlMapObjectConfigs_item, {
1024
+ fullPath: input_gisExtlMapObjectConfigs_item_id,
1025
+ propertyName: i,
1026
+ parent: {
1027
+ data: input,
1028
+ key: path.fullPath,
1029
+ existing: existing,
1030
+ },
1031
+ ttl: path.ttl
1032
+ }, luvio, store, timestamp);
1033
+ }
1034
+ return input;
1035
+ }
1036
+ const select$4 = function GisExtlMapObjectConfigCollectionRepresentationSelect() {
1037
+ return {
1038
+ kind: 'Fragment',
1039
+ version: VERSION$2,
1040
+ private: [],
1041
+ selections: [
1042
+ {
1043
+ name: 'count',
1044
+ kind: 'Scalar'
1045
+ },
1046
+ {
1047
+ name: 'gisExtlMapObjectConfigs',
1048
+ kind: 'Link',
1049
+ plural: true,
1050
+ fragment: select$5()
1051
+ }
1052
+ ]
1053
+ };
1054
+ };
1055
+ function equals$2(existing, incoming) {
1056
+ const existing_count = existing.count;
1057
+ const incoming_count = incoming.count;
1058
+ if (!(existing_count === incoming_count)) {
1059
+ return false;
1060
+ }
1061
+ const existing_gisExtlMapObjectConfigs = existing.gisExtlMapObjectConfigs;
1062
+ const incoming_gisExtlMapObjectConfigs = incoming.gisExtlMapObjectConfigs;
1063
+ const equals_gisExtlMapObjectConfigs_items = equalsArray(existing_gisExtlMapObjectConfigs, incoming_gisExtlMapObjectConfigs, (existing_gisExtlMapObjectConfigs_item, incoming_gisExtlMapObjectConfigs_item) => {
1064
+ if (!(existing_gisExtlMapObjectConfigs_item.__ref === incoming_gisExtlMapObjectConfigs_item.__ref)) {
1065
+ return false;
1066
+ }
1067
+ });
1068
+ if (equals_gisExtlMapObjectConfigs_items === false) {
1069
+ return false;
1070
+ }
1071
+ return true;
1072
+ }
1073
+ const ingest$2 = function GisExtlMapObjectConfigCollectionRepresentationIngest(input, path, luvio, store, timestamp) {
1074
+ if (process.env.NODE_ENV !== 'production') {
1075
+ const validateError = validate$2(input);
1076
+ if (validateError !== null) {
1077
+ throw validateError;
1078
+ }
1079
+ }
1080
+ const key = path.fullPath;
1081
+ const ttlToUse = TTL$2;
1082
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$2, "gis", VERSION$2, RepresentationType$2, equals$2);
1083
+ return createLink(key);
1084
+ };
1085
+ function getTypeCacheKeys$2(rootKeySet, luvio, input, fullPathFactory) {
1086
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
1087
+ const rootKey = fullPathFactory();
1088
+ rootKeySet.set(rootKey, {
1089
+ namespace: keyPrefix,
1090
+ representationName: RepresentationType$2,
1091
+ mergeable: false
1092
+ });
1093
+ const input_gisExtlMapObjectConfigs_length = input.gisExtlMapObjectConfigs.length;
1094
+ for (let i = 0; i < input_gisExtlMapObjectConfigs_length; i++) {
1095
+ getTypeCacheKeys$3(rootKeySet, luvio, input.gisExtlMapObjectConfigs[i]);
1096
+ }
1097
+ }
1098
+
1099
+ function select$3(luvio, params) {
1100
+ return select$4();
1101
+ }
1102
+ function keyBuilder$4(luvio, params) {
1103
+ return keyPrefix + '::GisExtlMapObjectConfigCollectionRepresentation:(' + 'id:' + params.queryParams.id + ',' + 'objectName:' + params.queryParams.objectName + ')';
1104
+ }
1105
+ function getResponseCacheKeys$1(storeKeyMap, luvio, resourceParams, response) {
1106
+ getTypeCacheKeys$2(storeKeyMap, luvio, response, () => keyBuilder$4(luvio, resourceParams));
1107
+ }
1108
+ function ingestSuccess$1(luvio, resourceParams, response, snapshotRefresh) {
1109
+ const { body } = response;
1110
+ const key = keyBuilder$4(luvio, resourceParams);
1111
+ luvio.storeIngest(key, ingest$2, body);
1112
+ const snapshot = luvio.storeLookup({
1113
+ recordId: key,
1114
+ node: select$3(),
1115
+ variables: {},
1116
+ }, snapshotRefresh);
1117
+ if (process.env.NODE_ENV !== 'production') {
1118
+ if (snapshot.state !== 'Fulfilled') {
1119
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
1120
+ }
1121
+ }
1122
+ deepFreeze(snapshot.data);
1123
+ return snapshot;
1124
+ }
1125
+ function ingestError$1(luvio, params, error, snapshotRefresh) {
1126
+ const key = keyBuilder$4(luvio, params);
1127
+ const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
1128
+ const storeMetadataParams = {
1129
+ ttl: TTL$2,
1130
+ namespace: keyPrefix,
1131
+ version: VERSION$2,
1132
+ representationName: RepresentationType$2
1133
+ };
1134
+ luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
1135
+ return errorSnapshot;
1136
+ }
1137
+ function createResourceRequest$1(config) {
1138
+ const headers = {};
1139
+ return {
1140
+ baseUri: '/services/data/v65.0',
1141
+ basePath: '/gis/config/GisExtlMapObjectConfig',
1142
+ method: 'get',
1143
+ body: null,
1144
+ urlParams: {},
1145
+ queryParams: config.queryParams,
1146
+ headers,
1147
+ priority: 'normal',
1148
+ };
1149
+ }
1150
+
1151
+ const adapterName$1 = 'getGisExtlMapObjectConfig';
1152
+ const getGisExtlMapObjectConfig_ConfigPropertyMetadata = [
1153
+ generateParamConfigMetadata('id', false, 1 /* QueryParameter */, 0 /* String */),
1154
+ generateParamConfigMetadata('objectName', false, 1 /* QueryParameter */, 0 /* String */),
1155
+ ];
1156
+ const getGisExtlMapObjectConfig_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, getGisExtlMapObjectConfig_ConfigPropertyMetadata);
1157
+ const createResourceParams$1 = /*#__PURE__*/ createResourceParams$5(getGisExtlMapObjectConfig_ConfigPropertyMetadata);
1158
+ function keyBuilder$3(luvio, config) {
1159
+ const resourceParams = createResourceParams$1(config);
1160
+ return keyBuilder$4(luvio, resourceParams);
1161
+ }
1162
+ function typeCheckConfig$1(untrustedConfig) {
1163
+ const config = {};
1164
+ typeCheckConfig$5(untrustedConfig, config, getGisExtlMapObjectConfig_ConfigPropertyMetadata);
1165
+ return config;
1166
+ }
1167
+ function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
1168
+ if (!untrustedIsObject(untrustedConfig)) {
1169
+ return null;
1170
+ }
1171
+ if (process.env.NODE_ENV !== 'production') {
1172
+ validateConfig(untrustedConfig, configPropertyNames);
1173
+ }
1174
+ const config = typeCheckConfig$1(untrustedConfig);
1175
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
1176
+ return null;
1177
+ }
1178
+ return config;
1179
+ }
1180
+ function adapterFragment$1(luvio, config) {
1181
+ createResourceParams$1(config);
1182
+ return select$3();
1183
+ }
1184
+ function onFetchResponseSuccess$1(luvio, config, resourceParams, response) {
1185
+ const snapshot = ingestSuccess$1(luvio, resourceParams, response, {
1186
+ config,
1187
+ resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
1188
+ });
1189
+ return luvio.storeBroadcast().then(() => snapshot);
1190
+ }
1191
+ function onFetchResponseError$1(luvio, config, resourceParams, response) {
1192
+ const snapshot = ingestError$1(luvio, resourceParams, response, {
1193
+ config,
1194
+ resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
1195
+ });
1196
+ return luvio.storeBroadcast().then(() => snapshot);
1197
+ }
1198
+ function buildNetworkSnapshot$1(luvio, config, options) {
1199
+ const resourceParams = createResourceParams$1(config);
1200
+ const request = createResourceRequest$1(resourceParams);
1201
+ return luvio.dispatchResourceRequest(request, options)
1202
+ .then((response) => {
1203
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$1(luvio, config, resourceParams, response), () => {
1204
+ const cache = new StoreKeyMap();
1205
+ getResponseCacheKeys$1(cache, luvio, resourceParams, response.body);
1206
+ return cache;
1207
+ });
1208
+ }, (response) => {
1209
+ return luvio.handleErrorResponse(() => onFetchResponseError$1(luvio, config, resourceParams, response));
1210
+ });
1211
+ }
1212
+ function buildNetworkSnapshotCachePolicy$1(context, coercedAdapterRequestContext) {
1213
+ return buildNetworkSnapshotCachePolicy$4(context, coercedAdapterRequestContext, buildNetworkSnapshot$1, undefined, false);
1214
+ }
1215
+ function buildCachedSnapshotCachePolicy$1(context, storeLookup) {
1216
+ const { luvio, config } = context;
1217
+ const selector = {
1218
+ recordId: keyBuilder$3(luvio, config),
1219
+ node: adapterFragment$1(luvio, config),
1220
+ variables: {},
1221
+ };
1222
+ const cacheSnapshot = storeLookup(selector, {
1223
+ config,
1224
+ resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
1225
+ });
1226
+ return cacheSnapshot;
1227
+ }
1228
+ const getGisExtlMapObjectConfigAdapterFactory = (luvio) => function gis__getGisExtlMapObjectConfig(untrustedConfig, requestContext) {
1229
+ const config = validateAdapterConfig$1(untrustedConfig, getGisExtlMapObjectConfig_ConfigPropertyNames);
1230
+ // Invalid or incomplete config
1231
+ if (config === null) {
1232
+ return null;
1233
+ }
1234
+ return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
1235
+ buildCachedSnapshotCachePolicy$1, buildNetworkSnapshotCachePolicy$1);
1236
+ };
1237
+
1238
+ const TTL$1 = 300;
1239
+ const VERSION$1 = "7313d898b396963c9d42c06b6f84abd7";
1240
+ function validate$1(obj, path = 'GisRelatedObjectConfigOutputRepresentation') {
1241
+ const v_error = (() => {
1242
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1243
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
1244
+ }
1245
+ const obj_defaultColor = obj.defaultColor;
1246
+ const path_defaultColor = path + '.defaultColor';
1247
+ if (typeof obj_defaultColor !== 'string') {
1248
+ return new TypeError('Expected "string" but received "' + typeof obj_defaultColor + '" (at "' + path_defaultColor + '")');
1249
+ }
1250
+ const obj_defaultIcon = obj.defaultIcon;
1251
+ const path_defaultIcon = path + '.defaultIcon';
1252
+ if (typeof obj_defaultIcon !== 'string') {
1253
+ return new TypeError('Expected "string" but received "' + typeof obj_defaultIcon + '" (at "' + path_defaultIcon + '")');
1254
+ }
1255
+ const obj_fieldName = obj.fieldName;
1256
+ const path_fieldName = path + '.fieldName';
1257
+ if (typeof obj_fieldName !== 'string') {
1258
+ return new TypeError('Expected "string" but received "' + typeof obj_fieldName + '" (at "' + path_fieldName + '")');
1259
+ }
1260
+ const obj_fieldType = obj.fieldType;
1261
+ const path_fieldType = path + '.fieldType';
1262
+ if (typeof obj_fieldType !== 'string') {
1263
+ return new TypeError('Expected "string" but received "' + typeof obj_fieldType + '" (at "' + path_fieldType + '")');
1264
+ }
1265
+ const obj_id = obj.id;
1266
+ const path_id = path + '.id';
1267
+ if (typeof obj_id !== 'string') {
1268
+ return new TypeError('Expected "string" but received "' + typeof obj_id + '" (at "' + path_id + '")');
1269
+ }
1270
+ const obj_objectName = obj.objectName;
1271
+ const path_objectName = path + '.objectName';
1272
+ if (typeof obj_objectName !== 'string') {
1273
+ return new TypeError('Expected "string" but received "' + typeof obj_objectName + '" (at "' + path_objectName + '")');
1274
+ }
1275
+ const obj_recordType = obj.recordType;
1276
+ const path_recordType = path + '.recordType';
1277
+ if (typeof obj_recordType !== 'string') {
1278
+ return new TypeError('Expected "string" but received "' + typeof obj_recordType + '" (at "' + path_recordType + '")');
1279
+ }
1280
+ const obj_referenceObjectName = obj.referenceObjectName;
1281
+ const path_referenceObjectName = path + '.referenceObjectName';
1282
+ if (typeof obj_referenceObjectName !== 'string') {
1283
+ return new TypeError('Expected "string" but received "' + typeof obj_referenceObjectName + '" (at "' + path_referenceObjectName + '")');
1284
+ }
1285
+ })();
1286
+ return v_error === undefined ? null : v_error;
1287
+ }
1288
+ const RepresentationType$1 = 'GisRelatedObjectConfigOutputRepresentation';
1289
+ function keyBuilder$2(luvio, config) {
1290
+ return keyPrefix + '::' + RepresentationType$1 + ':' + config.id;
1291
+ }
1292
+ function keyBuilderFromType(luvio, object) {
1293
+ const keyParams = {
1294
+ id: object.id
1295
+ };
1296
+ return keyBuilder$2(luvio, keyParams);
1297
+ }
1298
+ function normalize$1(input, existing, path, luvio, store, timestamp) {
1299
+ return input;
1300
+ }
1301
+ const select$2 = function GisRelatedObjectConfigOutputRepresentationSelect() {
1302
+ return {
1303
+ kind: 'Fragment',
1304
+ version: VERSION$1,
1305
+ private: [],
1306
+ selections: [
1307
+ {
1308
+ name: 'defaultColor',
1309
+ kind: 'Scalar'
1310
+ },
1311
+ {
1312
+ name: 'defaultIcon',
1313
+ kind: 'Scalar'
1314
+ },
1315
+ {
1316
+ name: 'fieldName',
1317
+ kind: 'Scalar'
1318
+ },
1319
+ {
1320
+ name: 'fieldType',
1321
+ kind: 'Scalar'
1322
+ },
1323
+ {
1324
+ name: 'id',
1325
+ kind: 'Scalar'
1326
+ },
1327
+ {
1328
+ name: 'objectName',
1329
+ kind: 'Scalar'
1330
+ },
1331
+ {
1332
+ name: 'recordType',
1333
+ kind: 'Scalar'
1334
+ },
1335
+ {
1336
+ name: 'referenceObjectName',
1337
+ kind: 'Scalar'
1338
+ }
1339
+ ]
1340
+ };
1341
+ };
1342
+ function equals$1(existing, incoming) {
1343
+ const existing_defaultColor = existing.defaultColor;
1344
+ const incoming_defaultColor = incoming.defaultColor;
1345
+ if (!(existing_defaultColor === incoming_defaultColor)) {
1346
+ return false;
1347
+ }
1348
+ const existing_defaultIcon = existing.defaultIcon;
1349
+ const incoming_defaultIcon = incoming.defaultIcon;
1350
+ if (!(existing_defaultIcon === incoming_defaultIcon)) {
1351
+ return false;
1352
+ }
1353
+ const existing_fieldName = existing.fieldName;
1354
+ const incoming_fieldName = incoming.fieldName;
1355
+ if (!(existing_fieldName === incoming_fieldName)) {
1356
+ return false;
1357
+ }
1358
+ const existing_fieldType = existing.fieldType;
1359
+ const incoming_fieldType = incoming.fieldType;
1360
+ if (!(existing_fieldType === incoming_fieldType)) {
1361
+ return false;
1362
+ }
1363
+ const existing_id = existing.id;
1364
+ const incoming_id = incoming.id;
1365
+ if (!(existing_id === incoming_id)) {
1366
+ return false;
1367
+ }
1368
+ const existing_objectName = existing.objectName;
1369
+ const incoming_objectName = incoming.objectName;
1370
+ if (!(existing_objectName === incoming_objectName)) {
1371
+ return false;
1372
+ }
1373
+ const existing_recordType = existing.recordType;
1374
+ const incoming_recordType = incoming.recordType;
1375
+ if (!(existing_recordType === incoming_recordType)) {
1376
+ return false;
1377
+ }
1378
+ const existing_referenceObjectName = existing.referenceObjectName;
1379
+ const incoming_referenceObjectName = incoming.referenceObjectName;
1380
+ if (!(existing_referenceObjectName === incoming_referenceObjectName)) {
1381
+ return false;
1382
+ }
1383
+ return true;
1384
+ }
1385
+ const ingest$1 = function GisRelatedObjectConfigOutputRepresentationIngest(input, path, luvio, store, timestamp) {
1386
+ if (process.env.NODE_ENV !== 'production') {
1387
+ const validateError = validate$1(input);
1388
+ if (validateError !== null) {
1389
+ throw validateError;
1390
+ }
1391
+ }
1392
+ const key = keyBuilderFromType(luvio, input);
1393
+ const ttlToUse = TTL$1;
1394
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$1, "gis", VERSION$1, RepresentationType$1, equals$1);
1395
+ return createLink(key);
1396
+ };
1397
+ function getTypeCacheKeys$1(rootKeySet, luvio, input, fullPathFactory) {
1398
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
1399
+ const rootKey = keyBuilderFromType(luvio, input);
1400
+ rootKeySet.set(rootKey, {
1401
+ namespace: keyPrefix,
1402
+ representationName: RepresentationType$1,
1403
+ mergeable: false
1404
+ });
1405
+ }
1406
+
1407
+ const TTL = 300;
1408
+ const VERSION = "a58708a8e997c383af8c127b5e1e55b4";
1409
+ function validate(obj, path = 'GisRelatedObjectConfigCollectionRepresentation') {
1410
+ const v_error = (() => {
1411
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1412
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
1413
+ }
1414
+ const obj_count = obj.count;
1415
+ const path_count = path + '.count';
1416
+ if (typeof obj_count !== 'number' || (typeof obj_count === 'number' && Math.floor(obj_count) !== obj_count)) {
1417
+ return new TypeError('Expected "integer" but received "' + typeof obj_count + '" (at "' + path_count + '")');
1418
+ }
1419
+ const obj_gisRelatedObjectConfigOutputRepresentation = obj.gisRelatedObjectConfigOutputRepresentation;
1420
+ const path_gisRelatedObjectConfigOutputRepresentation = path + '.gisRelatedObjectConfigOutputRepresentation';
1421
+ if (!ArrayIsArray(obj_gisRelatedObjectConfigOutputRepresentation)) {
1422
+ return new TypeError('Expected "array" but received "' + typeof obj_gisRelatedObjectConfigOutputRepresentation + '" (at "' + path_gisRelatedObjectConfigOutputRepresentation + '")');
1423
+ }
1424
+ for (let i = 0; i < obj_gisRelatedObjectConfigOutputRepresentation.length; i++) {
1425
+ const obj_gisRelatedObjectConfigOutputRepresentation_item = obj_gisRelatedObjectConfigOutputRepresentation[i];
1426
+ const path_gisRelatedObjectConfigOutputRepresentation_item = path_gisRelatedObjectConfigOutputRepresentation + '[' + i + ']';
1427
+ if (typeof obj_gisRelatedObjectConfigOutputRepresentation_item !== 'object' || Array.isArray(obj_gisRelatedObjectConfigOutputRepresentation_item)) {
1428
+ return new TypeError('Expected "object" but received "' + typeof obj_gisRelatedObjectConfigOutputRepresentation_item + '" (at "' + path_gisRelatedObjectConfigOutputRepresentation_item + '")');
1429
+ }
1430
+ }
1431
+ })();
1432
+ return v_error === undefined ? null : v_error;
1433
+ }
1434
+ const RepresentationType = 'GisRelatedObjectConfigCollectionRepresentation';
1435
+ function normalize(input, existing, path, luvio, store, timestamp) {
1436
+ const input_gisRelatedObjectConfigOutputRepresentation = input.gisRelatedObjectConfigOutputRepresentation;
1437
+ const input_gisRelatedObjectConfigOutputRepresentation_id = path.fullPath + '__gisRelatedObjectConfigOutputRepresentation';
1438
+ for (let i = 0; i < input_gisRelatedObjectConfigOutputRepresentation.length; i++) {
1439
+ const input_gisRelatedObjectConfigOutputRepresentation_item = input_gisRelatedObjectConfigOutputRepresentation[i];
1440
+ let input_gisRelatedObjectConfigOutputRepresentation_item_id = input_gisRelatedObjectConfigOutputRepresentation_id + '__' + i;
1441
+ input_gisRelatedObjectConfigOutputRepresentation[i] = ingest$1(input_gisRelatedObjectConfigOutputRepresentation_item, {
1442
+ fullPath: input_gisRelatedObjectConfigOutputRepresentation_item_id,
1443
+ propertyName: i,
1444
+ parent: {
1445
+ data: input,
1446
+ key: path.fullPath,
1447
+ existing: existing,
1448
+ },
1449
+ ttl: path.ttl
1450
+ }, luvio, store, timestamp);
1451
+ }
1452
+ return input;
1453
+ }
1454
+ const select$1 = function GisRelatedObjectConfigCollectionRepresentationSelect() {
1455
+ return {
1456
+ kind: 'Fragment',
1457
+ version: VERSION,
1458
+ private: [],
1459
+ selections: [
1460
+ {
1461
+ name: 'count',
1462
+ kind: 'Scalar'
1463
+ },
1464
+ {
1465
+ name: 'gisRelatedObjectConfigOutputRepresentation',
1466
+ kind: 'Link',
1467
+ plural: true,
1468
+ fragment: select$2()
1469
+ }
1470
+ ]
1471
+ };
1472
+ };
1473
+ function equals(existing, incoming) {
1474
+ const existing_count = existing.count;
1475
+ const incoming_count = incoming.count;
1476
+ if (!(existing_count === incoming_count)) {
1477
+ return false;
1478
+ }
1479
+ const existing_gisRelatedObjectConfigOutputRepresentation = existing.gisRelatedObjectConfigOutputRepresentation;
1480
+ const incoming_gisRelatedObjectConfigOutputRepresentation = incoming.gisRelatedObjectConfigOutputRepresentation;
1481
+ const equals_gisRelatedObjectConfigOutputRepresentation_items = equalsArray(existing_gisRelatedObjectConfigOutputRepresentation, incoming_gisRelatedObjectConfigOutputRepresentation, (existing_gisRelatedObjectConfigOutputRepresentation_item, incoming_gisRelatedObjectConfigOutputRepresentation_item) => {
1482
+ if (!(existing_gisRelatedObjectConfigOutputRepresentation_item.__ref === incoming_gisRelatedObjectConfigOutputRepresentation_item.__ref)) {
1483
+ return false;
1484
+ }
1485
+ });
1486
+ if (equals_gisRelatedObjectConfigOutputRepresentation_items === false) {
1487
+ return false;
1488
+ }
1489
+ return true;
1490
+ }
1491
+ const ingest = function GisRelatedObjectConfigCollectionRepresentationIngest(input, path, luvio, store, timestamp) {
1492
+ if (process.env.NODE_ENV !== 'production') {
1493
+ const validateError = validate(input);
1494
+ if (validateError !== null) {
1495
+ throw validateError;
1496
+ }
1497
+ }
1498
+ const key = path.fullPath;
1499
+ const ttlToUse = TTL;
1500
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize, "gis", VERSION, RepresentationType, equals);
1501
+ return createLink(key);
1502
+ };
1503
+ function getTypeCacheKeys(rootKeySet, luvio, input, fullPathFactory) {
1504
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
1505
+ const rootKey = fullPathFactory();
1506
+ rootKeySet.set(rootKey, {
1507
+ namespace: keyPrefix,
1508
+ representationName: RepresentationType,
1509
+ mergeable: false
1510
+ });
1511
+ const input_gisRelatedObjectConfigOutputRepresentation_length = input.gisRelatedObjectConfigOutputRepresentation.length;
1512
+ for (let i = 0; i < input_gisRelatedObjectConfigOutputRepresentation_length; i++) {
1513
+ getTypeCacheKeys$1(rootKeySet, luvio, input.gisRelatedObjectConfigOutputRepresentation[i]);
1514
+ }
1515
+ }
1516
+
1517
+ function select(luvio, params) {
1518
+ return select$1();
1519
+ }
1520
+ function keyBuilder$1(luvio, params) {
1521
+ return keyPrefix + '::GisRelatedObjectConfigCollectionRepresentation:(' + 'id:' + params.queryParams.id + ',' + 'objectName:' + params.queryParams.objectName + ')';
1522
+ }
1523
+ function getResponseCacheKeys(storeKeyMap, luvio, resourceParams, response) {
1524
+ getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$1(luvio, resourceParams));
1525
+ }
1526
+ function ingestSuccess(luvio, resourceParams, response, snapshotRefresh) {
1527
+ const { body } = response;
1528
+ const key = keyBuilder$1(luvio, resourceParams);
1529
+ luvio.storeIngest(key, ingest, body);
1530
+ const snapshot = luvio.storeLookup({
1531
+ recordId: key,
1532
+ node: select(),
1533
+ variables: {},
1534
+ }, snapshotRefresh);
1535
+ if (process.env.NODE_ENV !== 'production') {
1536
+ if (snapshot.state !== 'Fulfilled') {
1537
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
1538
+ }
1539
+ }
1540
+ deepFreeze(snapshot.data);
1541
+ return snapshot;
1542
+ }
1543
+ function ingestError(luvio, params, error, snapshotRefresh) {
1544
+ const key = keyBuilder$1(luvio, params);
1545
+ const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
1546
+ const storeMetadataParams = {
1547
+ ttl: TTL,
1548
+ namespace: keyPrefix,
1549
+ version: VERSION,
1550
+ representationName: RepresentationType
1551
+ };
1552
+ luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
1553
+ return errorSnapshot;
1554
+ }
1555
+ function createResourceRequest(config) {
1556
+ const headers = {};
1557
+ return {
1558
+ baseUri: '/services/data/v65.0',
1559
+ basePath: '/gis/config/GisRelatedObjectConfig',
1560
+ method: 'get',
1561
+ body: null,
1562
+ urlParams: {},
1563
+ queryParams: config.queryParams,
1564
+ headers,
1565
+ priority: 'normal',
1566
+ };
1567
+ }
1568
+
1569
+ const adapterName = 'getGisRelatedObjectConfig';
1570
+ const getGisRelatedObjectConfig_ConfigPropertyMetadata = [
1571
+ generateParamConfigMetadata('id', false, 1 /* QueryParameter */, 0 /* String */),
1572
+ generateParamConfigMetadata('objectName', false, 1 /* QueryParameter */, 0 /* String */),
1573
+ ];
1574
+ const getGisRelatedObjectConfig_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, getGisRelatedObjectConfig_ConfigPropertyMetadata);
1575
+ const createResourceParams = /*#__PURE__*/ createResourceParams$5(getGisRelatedObjectConfig_ConfigPropertyMetadata);
1576
+ function keyBuilder(luvio, config) {
1577
+ const resourceParams = createResourceParams(config);
1578
+ return keyBuilder$1(luvio, resourceParams);
1579
+ }
1580
+ function typeCheckConfig(untrustedConfig) {
1581
+ const config = {};
1582
+ typeCheckConfig$5(untrustedConfig, config, getGisRelatedObjectConfig_ConfigPropertyMetadata);
1583
+ return config;
1584
+ }
1585
+ function validateAdapterConfig(untrustedConfig, configPropertyNames) {
1586
+ if (!untrustedIsObject(untrustedConfig)) {
1587
+ return null;
1588
+ }
1589
+ if (process.env.NODE_ENV !== 'production') {
1590
+ validateConfig(untrustedConfig, configPropertyNames);
1591
+ }
1592
+ const config = typeCheckConfig(untrustedConfig);
1593
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
1594
+ return null;
1595
+ }
1596
+ return config;
1597
+ }
1598
+ function adapterFragment(luvio, config) {
1599
+ createResourceParams(config);
1600
+ return select();
1601
+ }
1602
+ function onFetchResponseSuccess(luvio, config, resourceParams, response) {
1603
+ const snapshot = ingestSuccess(luvio, resourceParams, response, {
1604
+ config,
1605
+ resolve: () => buildNetworkSnapshot(luvio, config, snapshotRefreshOptions)
1606
+ });
1607
+ return luvio.storeBroadcast().then(() => snapshot);
1608
+ }
1609
+ function onFetchResponseError(luvio, config, resourceParams, response) {
1610
+ const snapshot = ingestError(luvio, resourceParams, response, {
1611
+ config,
1612
+ resolve: () => buildNetworkSnapshot(luvio, config, snapshotRefreshOptions)
1613
+ });
1614
+ return luvio.storeBroadcast().then(() => snapshot);
1615
+ }
1616
+ function buildNetworkSnapshot(luvio, config, options) {
1617
+ const resourceParams = createResourceParams(config);
1618
+ const request = createResourceRequest(resourceParams);
1619
+ return luvio.dispatchResourceRequest(request, options)
1620
+ .then((response) => {
1621
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess(luvio, config, resourceParams, response), () => {
1622
+ const cache = new StoreKeyMap();
1623
+ getResponseCacheKeys(cache, luvio, resourceParams, response.body);
1624
+ return cache;
1625
+ });
1626
+ }, (response) => {
1627
+ return luvio.handleErrorResponse(() => onFetchResponseError(luvio, config, resourceParams, response));
1628
+ });
1629
+ }
1630
+ function buildNetworkSnapshotCachePolicy(context, coercedAdapterRequestContext) {
1631
+ return buildNetworkSnapshotCachePolicy$4(context, coercedAdapterRequestContext, buildNetworkSnapshot, undefined, false);
1632
+ }
1633
+ function buildCachedSnapshotCachePolicy(context, storeLookup) {
1634
+ const { luvio, config } = context;
1635
+ const selector = {
1636
+ recordId: keyBuilder(luvio, config),
1637
+ node: adapterFragment(luvio, config),
1638
+ variables: {},
1639
+ };
1640
+ const cacheSnapshot = storeLookup(selector, {
1641
+ config,
1642
+ resolve: () => buildNetworkSnapshot(luvio, config, snapshotRefreshOptions)
1643
+ });
1644
+ return cacheSnapshot;
1645
+ }
1646
+ const getGisRelatedObjectConfigAdapterFactory = (luvio) => function gis__getGisRelatedObjectConfig(untrustedConfig, requestContext) {
1647
+ const config = validateAdapterConfig(untrustedConfig, getGisRelatedObjectConfig_ConfigPropertyNames);
584
1648
  // Invalid or incomplete config
585
1649
  if (config === null) {
586
1650
  return null;
@@ -589,4 +1653,4 @@ const getGisExternalAuthIdentityProvidersAdapterFactory = (luvio) => function gi
589
1653
  buildCachedSnapshotCachePolicy, buildNetworkSnapshotCachePolicy);
590
1654
  };
591
1655
 
592
- export { createGisExternalAuthIdentityProviderAdapterFactory, getGisExternalAuthIdentityProvidersAdapterFactory };
1656
+ export { createGisExternalAuthIdentityProviderAdapterFactory, getGisExternalAuthAccessTokenAdapterFactory, getGisExternalAuthIdentityProvidersAdapterFactory, getGisExtlMapObjectConfigAdapterFactory, getGisRelatedObjectConfigAdapterFactory };