geoserver-node-client 1.0.0 → 1.2.1

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.
package/dist/src/layer.js CHANGED
@@ -269,6 +269,229 @@ var LayerClient = /*#__PURE__*/function () {
269
269
 
270
270
  return getAll;
271
271
  }()
272
+ /**
273
+ * Get all layers of a workspace.
274
+ *
275
+ * @param {String} workspace The workspace
276
+ *
277
+ * @throws Error if request fails
278
+ *
279
+ * @return {Object} An object with the information about the layers
280
+ */
281
+
282
+ }, {
283
+ key: "getLayers",
284
+ value: function () {
285
+ var _getLayers = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee4(workspace) {
286
+ var response, geoServerResponse;
287
+ return _regenerator["default"].wrap(function _callee4$(_context4) {
288
+ while (1) {
289
+ switch (_context4.prev = _context4.next) {
290
+ case 0:
291
+ _context4.next = 2;
292
+ return (0, _nodeFetch["default"])(this.url + 'workspaces/' + workspace + '/layers.json', {
293
+ credentials: 'include',
294
+ method: 'GET',
295
+ headers: {
296
+ Authorization: this.auth
297
+ }
298
+ });
299
+
300
+ case 2:
301
+ response = _context4.sent;
302
+
303
+ if (response.ok) {
304
+ _context4.next = 8;
305
+ break;
306
+ }
307
+
308
+ _context4.next = 6;
309
+ return (0, _geoserver.getGeoServerResponseText)(response);
310
+
311
+ case 6:
312
+ geoServerResponse = _context4.sent;
313
+ throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
314
+
315
+ case 8:
316
+ _context4.next = 10;
317
+ return response.json();
318
+
319
+ case 10:
320
+ return _context4.abrupt("return", _context4.sent);
321
+
322
+ case 11:
323
+ case "end":
324
+ return _context4.stop();
325
+ }
326
+ }
327
+ }, _callee4, this);
328
+ }));
329
+
330
+ function getLayers(_x7) {
331
+ return _getLayers.apply(this, arguments);
332
+ }
333
+
334
+ return getLayers;
335
+ }()
336
+ /**
337
+ * Returns information about a cascaded WMS layer.
338
+ *
339
+ * @param {String} workspace The workspace
340
+ * @param {String} datastore The datastore
341
+ * @param {String} layerName The WMS layer name
342
+ *
343
+ * @throws Error if request fails
344
+ *
345
+ * @returns {Object} An object with layer information or undefined if it cannot be found
346
+ */
347
+
348
+ }, {
349
+ key: "getWmsLayer",
350
+ value: function () {
351
+ var _getWmsLayer = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee5(workspace, datastore, layerName) {
352
+ var response, grc, geoServerResponse;
353
+ return _regenerator["default"].wrap(function _callee5$(_context5) {
354
+ while (1) {
355
+ switch (_context5.prev = _context5.next) {
356
+ case 0:
357
+ _context5.next = 2;
358
+ return (0, _nodeFetch["default"])(this.url + 'workspaces/' + workspace + '/wmsstores/' + datastore + '/wmslayers/' + layerName + '.json', {
359
+ credentials: 'include',
360
+ method: 'GET',
361
+ headers: {
362
+ Authorization: this.auth
363
+ }
364
+ });
365
+
366
+ case 2:
367
+ response = _context5.sent;
368
+
369
+ if (response.ok) {
370
+ _context5.next = 15;
371
+ break;
372
+ }
373
+
374
+ grc = new _about["default"](this.url, this.auth);
375
+ _context5.next = 7;
376
+ return grc.exists();
377
+
378
+ case 7:
379
+ if (!_context5.sent) {
380
+ _context5.next = 11;
381
+ break;
382
+ }
383
+
384
+ return _context5.abrupt("return");
385
+
386
+ case 11:
387
+ _context5.next = 13;
388
+ return (0, _geoserver.getGeoServerResponseText)(response);
389
+
390
+ case 13:
391
+ geoServerResponse = _context5.sent;
392
+ throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
393
+
394
+ case 15:
395
+ _context5.next = 17;
396
+ return response.json();
397
+
398
+ case 17:
399
+ return _context5.abrupt("return", _context5.sent);
400
+
401
+ case 18:
402
+ case "end":
403
+ return _context5.stop();
404
+ }
405
+ }
406
+ }, _callee5, this);
407
+ }));
408
+
409
+ function getWmsLayer(_x8, _x9, _x10) {
410
+ return _getWmsLayer.apply(this, arguments);
411
+ }
412
+
413
+ return getWmsLayer;
414
+ }() // TODO: automated test needed
415
+
416
+ /**
417
+ * Returns information about a cascaded WMTS layer.
418
+ *
419
+ * @param {String} workspace The workspace
420
+ * @param {String} datastore The datastore
421
+ * @param {String} layerName The WMTS layer name
422
+ *
423
+ * @throws Error if request fails
424
+ *
425
+ * @returns {Object} An object with layer information or undefined if it cannot be found
426
+ */
427
+
428
+ }, {
429
+ key: "getWmtsLayer",
430
+ value: function () {
431
+ var _getWmtsLayer = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee6(workspace, datastore, layerName) {
432
+ var response, grc, geoServerResponse;
433
+ return _regenerator["default"].wrap(function _callee6$(_context6) {
434
+ while (1) {
435
+ switch (_context6.prev = _context6.next) {
436
+ case 0:
437
+ _context6.next = 2;
438
+ return (0, _nodeFetch["default"])(this.url + 'workspaces/' + workspace + '/wmtsstores/' + datastore + '/layers/' + layerName + '.json', {
439
+ credentials: 'include',
440
+ method: 'GET',
441
+ headers: {
442
+ Authorization: this.auth
443
+ }
444
+ });
445
+
446
+ case 2:
447
+ response = _context6.sent;
448
+
449
+ if (response.ok) {
450
+ _context6.next = 15;
451
+ break;
452
+ }
453
+
454
+ grc = new _about["default"](this.url, this.auth);
455
+ _context6.next = 7;
456
+ return grc.exists();
457
+
458
+ case 7:
459
+ if (!_context6.sent) {
460
+ _context6.next = 11;
461
+ break;
462
+ }
463
+
464
+ return _context6.abrupt("return");
465
+
466
+ case 11:
467
+ _context6.next = 13;
468
+ return (0, _geoserver.getGeoServerResponseText)(response);
469
+
470
+ case 13:
471
+ geoServerResponse = _context6.sent;
472
+ throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
473
+
474
+ case 15:
475
+ _context6.next = 17;
476
+ return response.json();
477
+
478
+ case 17:
479
+ return _context6.abrupt("return", _context6.sent);
480
+
481
+ case 18:
482
+ case "end":
483
+ return _context6.stop();
484
+ }
485
+ }
486
+ }, _callee6, this);
487
+ }));
488
+
489
+ function getWmtsLayer(_x11, _x12, _x13) {
490
+ return _getWmtsLayer.apply(this, arguments);
491
+ }
492
+
493
+ return getWmtsLayer;
494
+ }()
272
495
  /**
273
496
  * Publishes a FeatureType in the default data store of the workspace.
274
497
  *
@@ -286,11 +509,11 @@ var LayerClient = /*#__PURE__*/function () {
286
509
  }, {
287
510
  key: "publishFeatureTypeDefaultDataStore",
288
511
  value: function () {
289
- var _publishFeatureTypeDefaultDataStore = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee4(workspace, nativeName, name, title, srs, enabled, _abstract) {
512
+ var _publishFeatureTypeDefaultDataStore = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee7(workspace, nativeName, name, title, srs, enabled, _abstract) {
290
513
  var body, response, geoServerResponse;
291
- return _regenerator["default"].wrap(function _callee4$(_context4) {
514
+ return _regenerator["default"].wrap(function _callee7$(_context7) {
292
515
  while (1) {
293
- switch (_context4.prev = _context4.next) {
516
+ switch (_context7.prev = _context7.next) {
294
517
  case 0:
295
518
  body = {
296
519
  featureType: {
@@ -302,7 +525,7 @@ var LayerClient = /*#__PURE__*/function () {
302
525
  "abstract": _abstract || ''
303
526
  }
304
527
  };
305
- _context4.next = 3;
528
+ _context7.next = 3;
306
529
  return (0, _nodeFetch["default"])(this.url + 'workspaces/' + workspace + '/featuretypes', {
307
530
  credentials: 'include',
308
531
  method: 'POST',
@@ -314,29 +537,29 @@ var LayerClient = /*#__PURE__*/function () {
314
537
  });
315
538
 
316
539
  case 3:
317
- response = _context4.sent;
540
+ response = _context7.sent;
318
541
 
319
542
  if (response.ok) {
320
- _context4.next = 9;
543
+ _context7.next = 9;
321
544
  break;
322
545
  }
323
546
 
324
- _context4.next = 7;
547
+ _context7.next = 7;
325
548
  return (0, _geoserver.getGeoServerResponseText)(response);
326
549
 
327
550
  case 7:
328
- geoServerResponse = _context4.sent;
551
+ geoServerResponse = _context7.sent;
329
552
  throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
330
553
 
331
554
  case 9:
332
555
  case "end":
333
- return _context4.stop();
556
+ return _context7.stop();
334
557
  }
335
558
  }
336
- }, _callee4, this);
559
+ }, _callee7, this);
337
560
  }));
338
561
 
339
- function publishFeatureTypeDefaultDataStore(_x7, _x8, _x9, _x10, _x11, _x12, _x13) {
562
+ function publishFeatureTypeDefaultDataStore(_x14, _x15, _x16, _x17, _x18, _x19, _x20) {
340
563
  return _publishFeatureTypeDefaultDataStore.apply(this, arguments);
341
564
  }
342
565
 
@@ -361,11 +584,11 @@ var LayerClient = /*#__PURE__*/function () {
361
584
  }, {
362
585
  key: "publishFeatureType",
363
586
  value: function () {
364
- var _publishFeatureType = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee5(workspace, dataStore, nativeName, name, title, srs, enabled, _abstract2, nativeBoundingBox) {
587
+ var _publishFeatureType = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee8(workspace, dataStore, nativeName, name, title, srs, enabled, _abstract2, nativeBoundingBox) {
365
588
  var body, response, geoServerResponse;
366
- return _regenerator["default"].wrap(function _callee5$(_context5) {
589
+ return _regenerator["default"].wrap(function _callee8$(_context8) {
367
590
  while (1) {
368
- switch (_context5.prev = _context5.next) {
591
+ switch (_context8.prev = _context8.next) {
369
592
  case 0:
370
593
  // apply CRS info for native BBOX if not provided
371
594
  if (nativeBoundingBox && !nativeBoundingBox.crs) {
@@ -386,7 +609,7 @@ var LayerClient = /*#__PURE__*/function () {
386
609
  nativeBoundingBox: nativeBoundingBox
387
610
  }
388
611
  };
389
- _context5.next = 4;
612
+ _context8.next = 4;
390
613
  return (0, _nodeFetch["default"])(this.url + 'workspaces/' + workspace + '/datastores/' + dataStore + '/featuretypes', {
391
614
  credentials: 'include',
392
615
  method: 'POST',
@@ -398,29 +621,29 @@ var LayerClient = /*#__PURE__*/function () {
398
621
  });
399
622
 
400
623
  case 4:
401
- response = _context5.sent;
624
+ response = _context8.sent;
402
625
 
403
626
  if (response.ok) {
404
- _context5.next = 10;
627
+ _context8.next = 10;
405
628
  break;
406
629
  }
407
630
 
408
- _context5.next = 8;
631
+ _context8.next = 8;
409
632
  return (0, _geoserver.getGeoServerResponseText)(response);
410
633
 
411
634
  case 8:
412
- geoServerResponse = _context5.sent;
635
+ geoServerResponse = _context8.sent;
413
636
  throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
414
637
 
415
638
  case 10:
416
639
  case "end":
417
- return _context5.stop();
640
+ return _context8.stop();
418
641
  }
419
642
  }
420
- }, _callee5, this);
643
+ }, _callee8, this);
421
644
  }));
422
645
 
423
- function publishFeatureType(_x14, _x15, _x16, _x17, _x18, _x19, _x20, _x21, _x22) {
646
+ function publishFeatureType(_x21, _x22, _x23, _x24, _x25, _x26, _x27, _x28, _x29) {
424
647
  return _publishFeatureType.apply(this, arguments);
425
648
  }
426
649
 
@@ -441,14 +664,14 @@ var LayerClient = /*#__PURE__*/function () {
441
664
  }, {
442
665
  key: "getFeatureType",
443
666
  value: function () {
444
- var _getFeatureType = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee6(workspace, datastore, name) {
667
+ var _getFeatureType = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee9(workspace, datastore, name) {
445
668
  var url, response, grc, geoServerResponse;
446
- return _regenerator["default"].wrap(function _callee6$(_context6) {
669
+ return _regenerator["default"].wrap(function _callee9$(_context9) {
447
670
  while (1) {
448
- switch (_context6.prev = _context6.next) {
671
+ switch (_context9.prev = _context9.next) {
449
672
  case 0:
450
673
  url = this.url + 'workspaces/' + workspace + '/datastores/' + datastore + '/featuretypes/' + name + '.json';
451
- _context6.next = 3;
674
+ _context9.next = 3;
452
675
  return (0, _nodeFetch["default"])(url, {
453
676
  credentials: 'include',
454
677
  method: 'GET',
@@ -458,45 +681,45 @@ var LayerClient = /*#__PURE__*/function () {
458
681
  });
459
682
 
460
683
  case 3:
461
- response = _context6.sent;
684
+ response = _context9.sent;
462
685
 
463
686
  if (response.ok) {
464
- _context6.next = 16;
687
+ _context9.next = 16;
465
688
  break;
466
689
  }
467
690
 
468
691
  grc = new _about["default"](this.url, this.auth);
469
- _context6.next = 8;
692
+ _context9.next = 8;
470
693
  return grc.exists();
471
694
 
472
695
  case 8:
473
- if (!_context6.sent) {
474
- _context6.next = 12;
696
+ if (!_context9.sent) {
697
+ _context9.next = 12;
475
698
  break;
476
699
  }
477
700
 
478
- return _context6.abrupt("return");
701
+ return _context9.abrupt("return");
479
702
 
480
703
  case 12:
481
- _context6.next = 14;
704
+ _context9.next = 14;
482
705
  return (0, _geoserver.getGeoServerResponseText)(response);
483
706
 
484
707
  case 14:
485
- geoServerResponse = _context6.sent;
708
+ geoServerResponse = _context9.sent;
486
709
  throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
487
710
 
488
711
  case 16:
489
- return _context6.abrupt("return", response.json());
712
+ return _context9.abrupt("return", response.json());
490
713
 
491
714
  case 17:
492
715
  case "end":
493
- return _context6.stop();
716
+ return _context9.stop();
494
717
  }
495
718
  }
496
- }, _callee6, this);
719
+ }, _callee9, this);
497
720
  }));
498
721
 
499
- function getFeatureType(_x23, _x24, _x25) {
722
+ function getFeatureType(_x30, _x31, _x32) {
500
723
  return _getFeatureType.apply(this, arguments);
501
724
  }
502
725
 
@@ -520,11 +743,11 @@ var LayerClient = /*#__PURE__*/function () {
520
743
  }, {
521
744
  key: "publishWmsLayer",
522
745
  value: function () {
523
- var _publishWmsLayer = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee7(workspace, dataStore, nativeName, name, title, srs, enabled, _abstract3) {
746
+ var _publishWmsLayer = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee10(workspace, dataStore, nativeName, name, title, srs, enabled, _abstract3) {
524
747
  var body, response, geoServerResponse;
525
- return _regenerator["default"].wrap(function _callee7$(_context7) {
748
+ return _regenerator["default"].wrap(function _callee10$(_context10) {
526
749
  while (1) {
527
- switch (_context7.prev = _context7.next) {
750
+ switch (_context10.prev = _context10.next) {
528
751
  case 0:
529
752
  body = {
530
753
  wmsLayer: {
@@ -536,7 +759,7 @@ var LayerClient = /*#__PURE__*/function () {
536
759
  "abstract": _abstract3 || ''
537
760
  }
538
761
  };
539
- _context7.next = 3;
762
+ _context10.next = 3;
540
763
  return (0, _nodeFetch["default"])(this.url + 'workspaces/' + workspace + '/wmsstores/' + dataStore + '/wmslayers', {
541
764
  credentials: 'include',
542
765
  method: 'POST',
@@ -548,29 +771,29 @@ var LayerClient = /*#__PURE__*/function () {
548
771
  });
549
772
 
550
773
  case 3:
551
- response = _context7.sent;
774
+ response = _context10.sent;
552
775
 
553
776
  if (response.ok) {
554
- _context7.next = 9;
777
+ _context10.next = 9;
555
778
  break;
556
779
  }
557
780
 
558
- _context7.next = 7;
781
+ _context10.next = 7;
559
782
  return (0, _geoserver.getGeoServerResponseText)(response);
560
783
 
561
784
  case 7:
562
- geoServerResponse = _context7.sent;
785
+ geoServerResponse = _context10.sent;
563
786
  throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
564
787
 
565
788
  case 9:
566
789
  case "end":
567
- return _context7.stop();
790
+ return _context10.stop();
568
791
  }
569
792
  }
570
- }, _callee7, this);
793
+ }, _callee10, this);
571
794
  }));
572
795
 
573
- function publishWmsLayer(_x26, _x27, _x28, _x29, _x30, _x31, _x32, _x33) {
796
+ function publishWmsLayer(_x33, _x34, _x35, _x36, _x37, _x38, _x39, _x40) {
574
797
  return _publishWmsLayer.apply(this, arguments);
575
798
  }
576
799
 
@@ -594,11 +817,11 @@ var LayerClient = /*#__PURE__*/function () {
594
817
  }, {
595
818
  key: "publishDbRaster",
596
819
  value: function () {
597
- var _publishDbRaster = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee8(workspace, coverageStore, nativeName, name, title, srs, enabled, _abstract4) {
820
+ var _publishDbRaster = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee11(workspace, coverageStore, nativeName, name, title, srs, enabled, _abstract4) {
598
821
  var body, response, geoServerResponse;
599
- return _regenerator["default"].wrap(function _callee8$(_context8) {
822
+ return _regenerator["default"].wrap(function _callee11$(_context11) {
600
823
  while (1) {
601
- switch (_context8.prev = _context8.next) {
824
+ switch (_context11.prev = _context11.next) {
602
825
  case 0:
603
826
  body = {
604
827
  coverage: {
@@ -610,7 +833,7 @@ var LayerClient = /*#__PURE__*/function () {
610
833
  "abstract": _abstract4 || ''
611
834
  }
612
835
  };
613
- _context8.next = 3;
836
+ _context11.next = 3;
614
837
  return (0, _nodeFetch["default"])(this.url + 'workspaces/' + workspace + '/coveragestores/' + coverageStore + '/coverages', {
615
838
  credentials: 'include',
616
839
  method: 'POST',
@@ -622,29 +845,29 @@ var LayerClient = /*#__PURE__*/function () {
622
845
  });
623
846
 
624
847
  case 3:
625
- response = _context8.sent;
848
+ response = _context11.sent;
626
849
 
627
850
  if (response.ok) {
628
- _context8.next = 9;
851
+ _context11.next = 9;
629
852
  break;
630
853
  }
631
854
 
632
- _context8.next = 7;
855
+ _context11.next = 7;
633
856
  return (0, _geoserver.getGeoServerResponseText)(response);
634
857
 
635
858
  case 7:
636
- geoServerResponse = _context8.sent;
859
+ geoServerResponse = _context11.sent;
637
860
  throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
638
861
 
639
862
  case 9:
640
863
  case "end":
641
- return _context8.stop();
864
+ return _context11.stop();
642
865
  }
643
866
  }
644
- }, _callee8, this);
867
+ }, _callee11, this);
645
868
  }));
646
869
 
647
- function publishDbRaster(_x34, _x35, _x36, _x37, _x38, _x39, _x40, _x41) {
870
+ function publishDbRaster(_x41, _x42, _x43, _x44, _x45, _x46, _x47, _x48) {
648
871
  return _publishDbRaster.apply(this, arguments);
649
872
  }
650
873
 
@@ -664,13 +887,13 @@ var LayerClient = /*#__PURE__*/function () {
664
887
  }, {
665
888
  key: "deleteFeatureType",
666
889
  value: function () {
667
- var _deleteFeatureType = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee9(workspace, datastore, name, recurse) {
890
+ var _deleteFeatureType = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee12(workspace, datastore, name, recurse) {
668
891
  var response, geoServerResponse;
669
- return _regenerator["default"].wrap(function _callee9$(_context9) {
892
+ return _regenerator["default"].wrap(function _callee12$(_context12) {
670
893
  while (1) {
671
- switch (_context9.prev = _context9.next) {
894
+ switch (_context12.prev = _context12.next) {
672
895
  case 0:
673
- _context9.next = 2;
896
+ _context12.next = 2;
674
897
  return (0, _nodeFetch["default"])(this.url + 'workspaces/' + workspace + '/datastores/' + datastore + '/featuretypes/' + name + '?recurse=' + recurse, {
675
898
  credentials: 'include',
676
899
  method: 'DELETE',
@@ -680,29 +903,29 @@ var LayerClient = /*#__PURE__*/function () {
680
903
  });
681
904
 
682
905
  case 2:
683
- response = _context9.sent;
906
+ response = _context12.sent;
684
907
 
685
908
  if (response.ok) {
686
- _context9.next = 8;
909
+ _context12.next = 8;
687
910
  break;
688
911
  }
689
912
 
690
- _context9.next = 6;
913
+ _context12.next = 6;
691
914
  return (0, _geoserver.getGeoServerResponseText)(response);
692
915
 
693
916
  case 6:
694
- geoServerResponse = _context9.sent;
917
+ geoServerResponse = _context12.sent;
695
918
  throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
696
919
 
697
920
  case 8:
698
921
  case "end":
699
- return _context9.stop();
922
+ return _context12.stop();
700
923
  }
701
924
  }
702
- }, _callee9, this);
925
+ }, _callee12, this);
703
926
  }));
704
927
 
705
- function deleteFeatureType(_x42, _x43, _x44, _x45) {
928
+ function deleteFeatureType(_x49, _x50, _x51, _x52) {
706
929
  return _deleteFeatureType.apply(this, arguments);
707
930
  }
708
931
 
@@ -727,11 +950,11 @@ var LayerClient = /*#__PURE__*/function () {
727
950
  }, {
728
951
  key: "enableTimeCoverage",
729
952
  value: function () {
730
- var _enableTimeCoverage = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee10(workspace, dataStore, name, presentation, resolution, defaultValue, nearestMatchEnabled, rawNearestMatchEnabled, acceptableInterval) {
953
+ var _enableTimeCoverage = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee13(workspace, dataStore, name, presentation, resolution, defaultValue, nearestMatchEnabled, rawNearestMatchEnabled, acceptableInterval) {
731
954
  var body, url, response, geoServerResponse;
732
- return _regenerator["default"].wrap(function _callee10$(_context10) {
955
+ return _regenerator["default"].wrap(function _callee13$(_context13) {
733
956
  while (1) {
734
- switch (_context10.prev = _context10.next) {
957
+ switch (_context13.prev = _context13.next) {
735
958
  case 0:
736
959
  body = {
737
960
  coverage: {
@@ -754,7 +977,7 @@ var LayerClient = /*#__PURE__*/function () {
754
977
  }
755
978
  };
756
979
  url = this.url + 'workspaces/' + workspace + '/coveragestores/' + dataStore + '/coverages/' + name + '.json';
757
- _context10.next = 4;
980
+ _context13.next = 4;
758
981
  return (0, _nodeFetch["default"])(url, {
759
982
  credentials: 'include',
760
983
  method: 'PUT',
@@ -766,29 +989,29 @@ var LayerClient = /*#__PURE__*/function () {
766
989
  });
767
990
 
768
991
  case 4:
769
- response = _context10.sent;
992
+ response = _context13.sent;
770
993
 
771
994
  if (response.ok) {
772
- _context10.next = 10;
995
+ _context13.next = 10;
773
996
  break;
774
997
  }
775
998
 
776
- _context10.next = 8;
999
+ _context13.next = 8;
777
1000
  return (0, _geoserver.getGeoServerResponseText)(response);
778
1001
 
779
1002
  case 8:
780
- geoServerResponse = _context10.sent;
1003
+ geoServerResponse = _context13.sent;
781
1004
  throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
782
1005
 
783
1006
  case 10:
784
1007
  case "end":
785
- return _context10.stop();
1008
+ return _context13.stop();
786
1009
  }
787
1010
  }
788
- }, _callee10, this);
1011
+ }, _callee13, this);
789
1012
  }));
790
1013
 
791
- function enableTimeCoverage(_x46, _x47, _x48, _x49, _x50, _x51, _x52, _x53, _x54) {
1014
+ function enableTimeCoverage(_x53, _x54, _x55, _x56, _x57, _x58, _x59, _x60, _x61) {
792
1015
  return _enableTimeCoverage.apply(this, arguments);
793
1016
  }
794
1017
 
@@ -813,11 +1036,11 @@ var LayerClient = /*#__PURE__*/function () {
813
1036
  }, {
814
1037
  key: "enableTimeFeatureType",
815
1038
  value: function () {
816
- var _enableTimeFeatureType = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee11(workspace, dataStore, name, attribute, presentation, resolution, defaultValue, nearestMatchEnabled, rawNearestMatchEnabled, acceptableInterval) {
1039
+ var _enableTimeFeatureType = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee14(workspace, dataStore, name, attribute, presentation, resolution, defaultValue, nearestMatchEnabled, rawNearestMatchEnabled, acceptableInterval) {
817
1040
  var body, url, response, geoServerResponse;
818
- return _regenerator["default"].wrap(function _callee11$(_context11) {
1041
+ return _regenerator["default"].wrap(function _callee14$(_context14) {
819
1042
  while (1) {
820
- switch (_context11.prev = _context11.next) {
1043
+ switch (_context14.prev = _context14.next) {
821
1044
  case 0:
822
1045
  body = {
823
1046
  featureType: {
@@ -841,7 +1064,7 @@ var LayerClient = /*#__PURE__*/function () {
841
1064
  }
842
1065
  };
843
1066
  url = this.url + 'workspaces/' + workspace + '/datastores/' + dataStore + '/featuretypes/' + name + '.json';
844
- _context11.next = 4;
1067
+ _context14.next = 4;
845
1068
  return (0, _nodeFetch["default"])(url, {
846
1069
  credentials: 'include',
847
1070
  method: 'PUT',
@@ -853,29 +1076,29 @@ var LayerClient = /*#__PURE__*/function () {
853
1076
  });
854
1077
 
855
1078
  case 4:
856
- response = _context11.sent;
1079
+ response = _context14.sent;
857
1080
 
858
1081
  if (response.ok) {
859
- _context11.next = 10;
1082
+ _context14.next = 10;
860
1083
  break;
861
1084
  }
862
1085
 
863
- _context11.next = 8;
1086
+ _context14.next = 8;
864
1087
  return (0, _geoserver.getGeoServerResponseText)(response);
865
1088
 
866
1089
  case 8:
867
- geoServerResponse = _context11.sent;
1090
+ geoServerResponse = _context14.sent;
868
1091
  throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
869
1092
 
870
1093
  case 10:
871
1094
  case "end":
872
- return _context11.stop();
1095
+ return _context14.stop();
873
1096
  }
874
1097
  }
875
- }, _callee11, this);
1098
+ }, _callee14, this);
876
1099
  }));
877
1100
 
878
- function enableTimeFeatureType(_x55, _x56, _x57, _x58, _x59, _x60, _x61, _x62, _x63, _x64) {
1101
+ function enableTimeFeatureType(_x62, _x63, _x64, _x65, _x66, _x67, _x68, _x69, _x70, _x71) {
879
1102
  return _enableTimeFeatureType.apply(this, arguments);
880
1103
  }
881
1104
 
@@ -896,14 +1119,14 @@ var LayerClient = /*#__PURE__*/function () {
896
1119
  }, {
897
1120
  key: "getCoverage",
898
1121
  value: function () {
899
- var _getCoverage = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee12(workspace, coverageStore, name) {
1122
+ var _getCoverage = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee15(workspace, coverageStore, name) {
900
1123
  var url, response, grc, geoServerResponse;
901
- return _regenerator["default"].wrap(function _callee12$(_context12) {
1124
+ return _regenerator["default"].wrap(function _callee15$(_context15) {
902
1125
  while (1) {
903
- switch (_context12.prev = _context12.next) {
1126
+ switch (_context15.prev = _context15.next) {
904
1127
  case 0:
905
1128
  url = this.url + 'workspaces/' + workspace + '/coveragestores/' + coverageStore + '/coverages/' + name + '.json';
906
- _context12.next = 3;
1129
+ _context15.next = 3;
907
1130
  return (0, _nodeFetch["default"])(url, {
908
1131
  credentials: 'include',
909
1132
  method: 'GET',
@@ -913,45 +1136,45 @@ var LayerClient = /*#__PURE__*/function () {
913
1136
  });
914
1137
 
915
1138
  case 3:
916
- response = _context12.sent;
1139
+ response = _context15.sent;
917
1140
 
918
1141
  if (response.ok) {
919
- _context12.next = 16;
1142
+ _context15.next = 16;
920
1143
  break;
921
1144
  }
922
1145
 
923
1146
  grc = new _about["default"](this.url, this.auth);
924
- _context12.next = 8;
1147
+ _context15.next = 8;
925
1148
  return grc.exists();
926
1149
 
927
1150
  case 8:
928
- if (!_context12.sent) {
929
- _context12.next = 12;
1151
+ if (!_context15.sent) {
1152
+ _context15.next = 12;
930
1153
  break;
931
1154
  }
932
1155
 
933
- return _context12.abrupt("return");
1156
+ return _context15.abrupt("return");
934
1157
 
935
1158
  case 12:
936
- _context12.next = 14;
1159
+ _context15.next = 14;
937
1160
  return (0, _geoserver.getGeoServerResponseText)(response);
938
1161
 
939
1162
  case 14:
940
- geoServerResponse = _context12.sent;
1163
+ geoServerResponse = _context15.sent;
941
1164
  throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
942
1165
 
943
1166
  case 16:
944
- return _context12.abrupt("return", response.json());
1167
+ return _context15.abrupt("return", response.json());
945
1168
 
946
1169
  case 17:
947
1170
  case "end":
948
- return _context12.stop();
1171
+ return _context15.stop();
949
1172
  }
950
1173
  }
951
- }, _callee12, this);
1174
+ }, _callee15, this);
952
1175
  }));
953
1176
 
954
- function getCoverage(_x65, _x66, _x67) {
1177
+ function getCoverage(_x72, _x73, _x74) {
955
1178
  return _getCoverage.apply(this, arguments);
956
1179
  }
957
1180
 
@@ -973,11 +1196,11 @@ var LayerClient = /*#__PURE__*/function () {
973
1196
  }, {
974
1197
  key: "renameCoverageBands",
975
1198
  value: function () {
976
- var _renameCoverageBands = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee13(workspace, dataStore, layername, bandNames) {
1199
+ var _renameCoverageBands = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee16(workspace, dataStore, layername, bandNames) {
977
1200
  var body, url, response, geoServerResponse;
978
- return _regenerator["default"].wrap(function _callee13$(_context13) {
1201
+ return _regenerator["default"].wrap(function _callee16$(_context16) {
979
1202
  while (1) {
980
- switch (_context13.prev = _context13.next) {
1203
+ switch (_context16.prev = _context16.next) {
981
1204
  case 0:
982
1205
  body = {
983
1206
  coverage: {
@@ -993,7 +1216,7 @@ var LayerClient = /*#__PURE__*/function () {
993
1216
  });
994
1217
  });
995
1218
  url = this.url + 'workspaces/' + workspace + '/coveragestores/' + dataStore + '/coverages/' + layername + '.json';
996
- _context13.next = 5;
1219
+ _context16.next = 5;
997
1220
  return (0, _nodeFetch["default"])(url, {
998
1221
  credentials: 'include',
999
1222
  method: 'PUT',
@@ -1005,29 +1228,29 @@ var LayerClient = /*#__PURE__*/function () {
1005
1228
  });
1006
1229
 
1007
1230
  case 5:
1008
- response = _context13.sent;
1231
+ response = _context16.sent;
1009
1232
 
1010
1233
  if (response.ok) {
1011
- _context13.next = 11;
1234
+ _context16.next = 11;
1012
1235
  break;
1013
1236
  }
1014
1237
 
1015
- _context13.next = 9;
1238
+ _context16.next = 9;
1016
1239
  return (0, _geoserver.getGeoServerResponseText)(response);
1017
1240
 
1018
1241
  case 9:
1019
- geoServerResponse = _context13.sent;
1242
+ geoServerResponse = _context16.sent;
1020
1243
  throw new _geoserver.GeoServerResponseError(null, geoServerResponse);
1021
1244
 
1022
1245
  case 11:
1023
1246
  case "end":
1024
- return _context13.stop();
1247
+ return _context16.stop();
1025
1248
  }
1026
1249
  }
1027
- }, _callee13, this);
1250
+ }, _callee16, this);
1028
1251
  }));
1029
1252
 
1030
- function renameCoverageBands(_x68, _x69, _x70, _x71) {
1253
+ function renameCoverageBands(_x75, _x76, _x77, _x78) {
1031
1254
  return _renameCoverageBands.apply(this, arguments);
1032
1255
  }
1033
1256