@nutanix-scratch/objects-js-client 4.0.1-beta.1 → 4.0.2

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.
Files changed (178) hide show
  1. package/README.md +33 -20
  2. package/dist/Ntnx-Objects-js-client-prod.js +1 -1
  3. package/dist/Ntnx-Objects-js-client.js +331 -259
  4. package/dist/es/ApiClient.d.ts +35 -7
  5. package/dist/es/ApiClient.js +862 -684
  6. package/dist/es/Paginable.d.ts +1 -1
  7. package/dist/es/Paginable.js +144 -183
  8. package/dist/es/apis/objectstores-endpoints.d.ts +9 -70
  9. package/dist/es/apis/objectstores-endpoints.js +407 -477
  10. package/dist/es/apis/stats-endpoints.d.ts +46 -0
  11. package/dist/es/apis/stats-endpoints.js +122 -0
  12. package/dist/es/index.d.ts +13 -1
  13. package/dist/es/index.js +152 -104
  14. package/dist/es/models/common/v1/config/FQDN.d.ts +2 -7
  15. package/dist/es/models/common/v1/config/FQDN.js +141 -180
  16. package/dist/es/models/common/v1/config/Flag.d.ts +2 -8
  17. package/dist/es/models/common/v1/config/Flag.js +170 -211
  18. package/dist/es/models/common/v1/config/IPAddress.d.ts +2 -20
  19. package/dist/es/models/common/v1/config/IPAddress.js +170 -217
  20. package/dist/es/models/common/v1/config/IPv4Address.d.ts +2 -8
  21. package/dist/es/models/common/v1/config/IPv4Address.js +174 -215
  22. package/dist/es/models/common/v1/config/IPv6Address.d.ts +2 -8
  23. package/dist/es/models/common/v1/config/IPv6Address.js +174 -215
  24. package/dist/es/models/common/v1/config/KVPair.d.ts +2 -8
  25. package/dist/es/models/common/v1/config/KVPair.js +225 -270
  26. package/dist/es/models/common/v1/config/MapOfStringWrapper.d.ts +2 -7
  27. package/dist/es/models/common/v1/config/MapOfStringWrapper.js +139 -178
  28. package/dist/es/models/common/v1/config/Message.d.ts +2 -10
  29. package/dist/es/models/common/v1/config/Message.js +213 -258
  30. package/dist/es/models/common/v1/config/MessageSeverity.js +7 -9
  31. package/dist/es/models/common/v1/config/Metadata.d.ts +2 -11
  32. package/dist/es/models/common/v1/config/Metadata.js +261 -308
  33. package/dist/es/models/common/v1/config/TenantAwareModel.d.ts +5 -10
  34. package/dist/es/models/common/v1/config/TenantAwareModel.js +138 -178
  35. package/dist/es/models/common/v1/response/ApiLink.d.ts +2 -8
  36. package/dist/es/models/common/v1/response/ApiLink.js +165 -206
  37. package/dist/es/models/common/v1/response/ApiResponseMetadata.d.ts +2 -40
  38. package/dist/es/models/common/v1/response/ApiResponseMetadata.js +281 -344
  39. package/dist/es/models/common/v1/response/ExternalizableAbstractModel.d.ts +1 -15
  40. package/dist/es/models/common/v1/response/ExternalizableAbstractModel.js +155 -203
  41. package/dist/es/models/common/v1/stats/DownSamplingOperator.d.ts +19 -0
  42. package/dist/es/models/common/v1/stats/DownSamplingOperator.js +107 -0
  43. package/dist/es/models/common/v1/stats/TimeIntValuePair.d.ts +58 -0
  44. package/dist/es/models/common/v1/stats/TimeIntValuePair.js +272 -0
  45. package/dist/es/models/objects/v4/config/Certificate.d.ts +24 -34
  46. package/dist/es/models/objects/v4/config/Certificate.js +342 -310
  47. package/dist/es/models/objects/v4/config/CertificateProjection.d.ts +1 -1
  48. package/dist/es/models/objects/v4/config/CertificateProjection.js +75 -103
  49. package/dist/es/models/objects/v4/config/CreateCertificateApiResponse.d.ts +2 -43
  50. package/dist/es/models/objects/v4/config/CreateCertificateApiResponse.js +187 -242
  51. package/dist/es/models/objects/v4/config/CreateObjectstoreApiResponse.d.ts +2 -43
  52. package/dist/es/models/objects/v4/config/CreateObjectstoreApiResponse.js +187 -242
  53. package/dist/es/models/objects/v4/config/DeleteObjectstoreApiResponse.d.ts +2 -43
  54. package/dist/es/models/objects/v4/config/DeleteObjectstoreApiResponse.js +187 -242
  55. package/dist/es/models/objects/v4/config/GetCaApiResponse.d.ts +2 -45
  56. package/dist/es/models/objects/v4/config/GetCaApiResponse.js +187 -242
  57. package/dist/es/models/objects/v4/config/GetCertificateApiResponse.d.ts +2 -43
  58. package/dist/es/models/objects/v4/config/GetCertificateApiResponse.js +187 -242
  59. package/dist/es/models/objects/v4/config/GetObjectstoreApiResponse.d.ts +2 -43
  60. package/dist/es/models/objects/v4/config/GetObjectstoreApiResponse.js +187 -242
  61. package/dist/es/models/objects/v4/config/ListCertificatesApiResponse.d.ts +2 -43
  62. package/dist/es/models/objects/v4/config/ListCertificatesApiResponse.js +213 -268
  63. package/dist/es/models/objects/v4/config/ListObjectstoresApiResponse.d.ts +2 -43
  64. package/dist/es/models/objects/v4/config/ListObjectstoresApiResponse.js +213 -268
  65. package/dist/es/models/objects/v4/config/ObjectStore.d.ts +1 -96
  66. package/dist/es/models/objects/v4/config/ObjectStore.js +629 -712
  67. package/dist/es/models/objects/v4/config/ObjectStoreProjection.d.ts +1 -129
  68. package/dist/es/models/objects/v4/config/ObjectStoreProjection.js +222 -239
  69. package/dist/es/models/objects/v4/config/State.js +7 -9
  70. package/dist/es/models/objects/v4/config/UpdateObjectstoreApiResponse.d.ts +2 -43
  71. package/dist/es/models/objects/v4/config/UpdateObjectstoreApiResponse.js +187 -242
  72. package/dist/es/models/objects/v4/error/AppMessage.d.ts +5 -15
  73. package/dist/es/models/objects/v4/error/AppMessage.js +265 -314
  74. package/dist/es/models/objects/v4/error/ErrorResponse.d.ts +2 -7
  75. package/dist/es/models/objects/v4/error/ErrorResponse.js +177 -219
  76. package/dist/es/models/objects/v4/error/SchemaValidationError.d.ts +2 -18
  77. package/dist/es/models/objects/v4/error/SchemaValidationError.js +249 -300
  78. package/dist/es/models/objects/v4/error/SchemaValidationErrorMessage.d.ts +2 -9
  79. package/dist/es/models/objects/v4/error/SchemaValidationErrorMessage.js +191 -234
  80. package/dist/es/models/objects/v4/stats/GetObjectstoreStatsApiResponse.d.ts +58 -0
  81. package/dist/es/models/objects/v4/stats/GetObjectstoreStatsApiResponse.js +288 -0
  82. package/dist/es/models/objects/v4/stats/ObjectstoreStats.d.ts +255 -0
  83. package/dist/es/models/objects/v4/stats/ObjectstoreStats.js +1253 -0
  84. package/dist/es/models/objects/v4/stats/TimeFloatValuePair.d.ts +58 -0
  85. package/dist/es/models/objects/v4/stats/TimeFloatValuePair.js +272 -0
  86. package/dist/es/models/prism/v4/config/TaskReference.d.ts +2 -7
  87. package/dist/es/models/prism/v4/config/TaskReference.js +142 -181
  88. package/dist/es/models/validation/ValidationError.js +26 -42
  89. package/dist/es/models/validation/ValidationScopes.js +3 -3
  90. package/dist/es/utils/ValidationUtils.js +39 -69
  91. package/dist/lib/ApiClient.d.ts +35 -7
  92. package/dist/lib/ApiClient.js +862 -684
  93. package/dist/lib/Paginable.d.ts +1 -1
  94. package/dist/lib/Paginable.js +144 -183
  95. package/dist/lib/apis/objectstores-endpoints.d.ts +9 -70
  96. package/dist/lib/apis/objectstores-endpoints.js +407 -477
  97. package/dist/lib/apis/stats-endpoints.d.ts +46 -0
  98. package/dist/lib/apis/stats-endpoints.js +122 -0
  99. package/dist/lib/index.d.ts +13 -1
  100. package/dist/lib/index.js +152 -104
  101. package/dist/lib/models/common/v1/config/FQDN.d.ts +2 -7
  102. package/dist/lib/models/common/v1/config/FQDN.js +141 -180
  103. package/dist/lib/models/common/v1/config/Flag.d.ts +2 -8
  104. package/dist/lib/models/common/v1/config/Flag.js +170 -211
  105. package/dist/lib/models/common/v1/config/IPAddress.d.ts +2 -20
  106. package/dist/lib/models/common/v1/config/IPAddress.js +170 -217
  107. package/dist/lib/models/common/v1/config/IPv4Address.d.ts +2 -8
  108. package/dist/lib/models/common/v1/config/IPv4Address.js +174 -215
  109. package/dist/lib/models/common/v1/config/IPv6Address.d.ts +2 -8
  110. package/dist/lib/models/common/v1/config/IPv6Address.js +174 -215
  111. package/dist/lib/models/common/v1/config/KVPair.d.ts +2 -8
  112. package/dist/lib/models/common/v1/config/KVPair.js +225 -270
  113. package/dist/lib/models/common/v1/config/MapOfStringWrapper.d.ts +2 -7
  114. package/dist/lib/models/common/v1/config/MapOfStringWrapper.js +139 -178
  115. package/dist/lib/models/common/v1/config/Message.d.ts +2 -10
  116. package/dist/lib/models/common/v1/config/Message.js +213 -258
  117. package/dist/lib/models/common/v1/config/MessageSeverity.js +7 -9
  118. package/dist/lib/models/common/v1/config/Metadata.d.ts +2 -11
  119. package/dist/lib/models/common/v1/config/Metadata.js +261 -308
  120. package/dist/lib/models/common/v1/config/TenantAwareModel.d.ts +5 -10
  121. package/dist/lib/models/common/v1/config/TenantAwareModel.js +138 -178
  122. package/dist/lib/models/common/v1/response/ApiLink.d.ts +2 -8
  123. package/dist/lib/models/common/v1/response/ApiLink.js +165 -206
  124. package/dist/lib/models/common/v1/response/ApiResponseMetadata.d.ts +2 -40
  125. package/dist/lib/models/common/v1/response/ApiResponseMetadata.js +281 -344
  126. package/dist/lib/models/common/v1/response/ExternalizableAbstractModel.d.ts +1 -15
  127. package/dist/lib/models/common/v1/response/ExternalizableAbstractModel.js +155 -203
  128. package/dist/lib/models/common/v1/stats/DownSamplingOperator.d.ts +19 -0
  129. package/dist/lib/models/common/v1/stats/DownSamplingOperator.js +107 -0
  130. package/dist/lib/models/common/v1/stats/TimeIntValuePair.d.ts +58 -0
  131. package/dist/lib/models/common/v1/stats/TimeIntValuePair.js +272 -0
  132. package/dist/lib/models/objects/v4/config/Certificate.d.ts +24 -34
  133. package/dist/lib/models/objects/v4/config/Certificate.js +342 -310
  134. package/dist/lib/models/objects/v4/config/CertificateProjection.d.ts +1 -1
  135. package/dist/lib/models/objects/v4/config/CertificateProjection.js +75 -103
  136. package/dist/lib/models/objects/v4/config/CreateCertificateApiResponse.d.ts +2 -43
  137. package/dist/lib/models/objects/v4/config/CreateCertificateApiResponse.js +187 -242
  138. package/dist/lib/models/objects/v4/config/CreateObjectstoreApiResponse.d.ts +2 -43
  139. package/dist/lib/models/objects/v4/config/CreateObjectstoreApiResponse.js +187 -242
  140. package/dist/lib/models/objects/v4/config/DeleteObjectstoreApiResponse.d.ts +2 -43
  141. package/dist/lib/models/objects/v4/config/DeleteObjectstoreApiResponse.js +187 -242
  142. package/dist/lib/models/objects/v4/config/GetCaApiResponse.d.ts +2 -45
  143. package/dist/lib/models/objects/v4/config/GetCaApiResponse.js +187 -242
  144. package/dist/lib/models/objects/v4/config/GetCertificateApiResponse.d.ts +2 -43
  145. package/dist/lib/models/objects/v4/config/GetCertificateApiResponse.js +187 -242
  146. package/dist/lib/models/objects/v4/config/GetObjectstoreApiResponse.d.ts +2 -43
  147. package/dist/lib/models/objects/v4/config/GetObjectstoreApiResponse.js +187 -242
  148. package/dist/lib/models/objects/v4/config/ListCertificatesApiResponse.d.ts +2 -43
  149. package/dist/lib/models/objects/v4/config/ListCertificatesApiResponse.js +213 -268
  150. package/dist/lib/models/objects/v4/config/ListObjectstoresApiResponse.d.ts +2 -43
  151. package/dist/lib/models/objects/v4/config/ListObjectstoresApiResponse.js +213 -268
  152. package/dist/lib/models/objects/v4/config/ObjectStore.d.ts +1 -96
  153. package/dist/lib/models/objects/v4/config/ObjectStore.js +629 -712
  154. package/dist/lib/models/objects/v4/config/ObjectStoreProjection.d.ts +1 -129
  155. package/dist/lib/models/objects/v4/config/ObjectStoreProjection.js +222 -239
  156. package/dist/lib/models/objects/v4/config/State.js +7 -9
  157. package/dist/lib/models/objects/v4/config/UpdateObjectstoreApiResponse.d.ts +2 -43
  158. package/dist/lib/models/objects/v4/config/UpdateObjectstoreApiResponse.js +187 -242
  159. package/dist/lib/models/objects/v4/error/AppMessage.d.ts +5 -15
  160. package/dist/lib/models/objects/v4/error/AppMessage.js +265 -314
  161. package/dist/lib/models/objects/v4/error/ErrorResponse.d.ts +2 -7
  162. package/dist/lib/models/objects/v4/error/ErrorResponse.js +177 -219
  163. package/dist/lib/models/objects/v4/error/SchemaValidationError.d.ts +2 -18
  164. package/dist/lib/models/objects/v4/error/SchemaValidationError.js +249 -300
  165. package/dist/lib/models/objects/v4/error/SchemaValidationErrorMessage.d.ts +2 -9
  166. package/dist/lib/models/objects/v4/error/SchemaValidationErrorMessage.js +191 -234
  167. package/dist/lib/models/objects/v4/stats/GetObjectstoreStatsApiResponse.d.ts +58 -0
  168. package/dist/lib/models/objects/v4/stats/GetObjectstoreStatsApiResponse.js +288 -0
  169. package/dist/lib/models/objects/v4/stats/ObjectstoreStats.d.ts +255 -0
  170. package/dist/lib/models/objects/v4/stats/ObjectstoreStats.js +1253 -0
  171. package/dist/lib/models/objects/v4/stats/TimeFloatValuePair.d.ts +58 -0
  172. package/dist/lib/models/objects/v4/stats/TimeFloatValuePair.js +272 -0
  173. package/dist/lib/models/prism/v4/config/TaskReference.d.ts +2 -7
  174. package/dist/lib/models/prism/v4/config/TaskReference.js +142 -181
  175. package/dist/lib/models/validation/ValidationError.js +26 -42
  176. package/dist/lib/models/validation/ValidationScopes.js +3 -3
  177. package/dist/lib/utils/ValidationUtils.js +39 -69
  178. package/package.json +2 -2
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports["default"] = void 0;
6
+ exports.default = void 0;
7
7
  var _Flag = _interopRequireDefault(require("../config/Flag"));
8
8
  var _KVPair = _interopRequireDefault(require("../config/KVPair"));
9
9
  var _Message = _interopRequireDefault(require("../config/Message"));
@@ -11,31 +11,16 @@ var _ApiLink = _interopRequireDefault(require("./ApiLink"));
11
11
  var _ValidationScopes = _interopRequireDefault(require("../../../validation/ValidationScopes"));
12
12
  var _ValidationUtils = _interopRequireDefault(require("../../../../utils/ValidationUtils"));
13
13
  var _ValidationError = _interopRequireDefault(require("../../../validation/ValidationError"));
14
- function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
15
- function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
16
- function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
17
- function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
18
- function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
19
- function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
20
- function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
21
- function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
22
- function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
23
- function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
24
- function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
25
- function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
26
- function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
27
- function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
28
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
29
- function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
14
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
30
15
  function _classPrivateMethodInitSpec(e, a) { _checkPrivateRedeclaration(e, a), a.add(e); }
31
16
  function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); } /*
32
17
  * Nutanix Objects Storage Management APIs
33
18
  *
34
- * OpenAPI spec version: 4.0.1-beta-1
19
+ * OpenAPI spec version: 4.0.2
35
20
  *
36
21
  * NOTE: This class is auto generated by the Open API Dev Platform.
37
22
  *
38
- * Open API Dev Platform Codegen version: 16.9.0.8546-RELEASE
23
+ * Open API Dev Platform Codegen version: 17.5.0.10128-RELEASE
39
24
  *
40
25
  * Do not edit the class manually.
41
26
  *
@@ -43,18 +28,17 @@ function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("C
43
28
  /**
44
29
  * The ApiResponseMetadata model module.
45
30
  * @module Ntnx/ApiResponseMetadata
46
- * @version 4.0.1-beta-1
31
+ * @version 4.0.2
47
32
  * @class ApiResponseMetadata
48
33
  */
49
34
  var _ApiResponseMetadata_brand = /*#__PURE__*/new WeakSet();
50
- var ApiResponseMetadata = exports["default"] = /*#__PURE__*/function () {
35
+ class ApiResponseMetadata {
51
36
  /**
52
37
  * Constructs a new <code>ApiResponseMetadata</code>.
53
38
  * The metadata associated with an API response. This value is always present and minimally contains the self-link for the API request that produced this response. It also contains pagination data for the paginated requests.
54
39
  * @alias module:Ntnx/ApiResponseMetadata
55
40
  */
56
- function ApiResponseMetadata() {
57
- _classCallCheck(this, ApiResponseMetadata);
41
+ constructor() {
58
42
  /*
59
43
  * toJson method for a map type which supports map with primitive keys and values of object types
60
44
  * @param {Object} obj
@@ -79,362 +63,315 @@ var ApiResponseMetadata = exports["default"] = /*#__PURE__*/function () {
79
63
  * @param callFromChild {Boolean} Flag to recognise calling instance
80
64
  * @return {module:Ntnx/ApiResponseMetadata} The populated <code>ApiResponseMetadata</code> instance.
81
65
  */
82
- return _createClass(ApiResponseMetadata, [{
83
- key: "getFlags",
84
- value:
85
- /**
86
- * Returns An array of flags that may indicate the status of the response. For example, a flag with the name 'isPaginated' and value 'false', indicates that the response is not paginated.
87
- * @return {Flag[]}
88
- */
89
- function getFlags() {
90
- return this.flags;
66
+ static constructFromObject(data, obj = null, callFromChild = false) {
67
+ let items, item, i, itemArr, discriminator;
68
+ if (data) {
69
+ obj = obj || new ApiResponseMetadata();
70
+ if (data.hasOwnProperty('flags') && data.flags !== null && data.flags !== undefined) {
71
+ itemArr = [];
72
+ items = data.flags;
73
+ for (i = 0; i < items.length; i++) {
74
+ item = _Flag.default.constructFromObject(items[i], undefined);
75
+ itemArr.push(item);
76
+ }
77
+ obj.setFlags(itemArr);
78
+ }
79
+ if (data.hasOwnProperty('links') && data.links !== null && data.links !== undefined) {
80
+ itemArr = [];
81
+ items = data.links;
82
+ for (i = 0; i < items.length; i++) {
83
+ item = _ApiLink.default.constructFromObject(items[i], undefined);
84
+ itemArr.push(item);
85
+ }
86
+ obj.setLinks(itemArr);
87
+ }
88
+ if (data.hasOwnProperty('totalAvailableResults') && data.totalAvailableResults !== null && data.totalAvailableResults !== undefined) {
89
+ obj.setTotalAvailableResults(data['totalAvailableResults']);
90
+ }
91
+ if (data.hasOwnProperty('messages') && data.messages !== null && data.messages !== undefined) {
92
+ itemArr = [];
93
+ items = data.messages;
94
+ for (i = 0; i < items.length; i++) {
95
+ item = _Message.default.constructFromObject(items[i], undefined);
96
+ itemArr.push(item);
97
+ }
98
+ obj.setMessages(itemArr);
99
+ }
100
+ if (data.hasOwnProperty('extraInfo') && data.extraInfo !== null && data.extraInfo !== undefined) {
101
+ itemArr = [];
102
+ items = data.extraInfo;
103
+ for (i = 0; i < items.length; i++) {
104
+ item = _KVPair.default.constructFromObject(items[i], undefined);
105
+ itemArr.push(item);
106
+ }
107
+ obj.setExtraInfo(itemArr);
108
+ }
109
+ if (data.hasOwnProperty('$reserved')) {
110
+ obj.$reserved = data['$reserved'];
111
+ }
112
+ if (data.hasOwnProperty('$objectType')) {
113
+ obj.$objectType = data['$objectType'];
114
+ }
115
+ if (data.hasOwnProperty('$unknownFields')) {
116
+ obj.$unknownFields = data['$unknownFields'];
117
+ }
118
+ if (!callFromChild) {
119
+ obj.$unknownFields = {
120
+ ...data.$unknownFields
121
+ };
122
+ for (const property in data) {
123
+ // Check if the `property` is not already present in `obj` keys, either in snake_case or camelCase,
124
+ // as the model's fields are generated in camelCase, but the server might return snake_case (e.g., due to standards like OIDC).
125
+ // Also, ensure the `property` does not start with '$' and end with 'ItemDiscriminator'.
126
+ // If all conditions are true, add the `property` from `data` to `obj.$unknownFields` as an unknown field.
127
+ if (!Object.keys(obj).includes(property) && !Object.keys(obj).includes(this.snakeToCamel(property)) && !(property[0] === "$" && property.endsWith("ItemDiscriminator"))) {
128
+ obj.$unknownFields[property] = data[property];
129
+ }
130
+ }
131
+ }
91
132
  }
133
+ return obj;
134
+ }
92
135
 
93
- /**
94
- * Sets An array of flags that may indicate the status of the response. For example, a flag with the name 'isPaginated' and value 'false', indicates that the response is not paginated.
95
- * @param {Flag[]} flags An array of flags that may indicate the status of the response. For example, a flag with the name 'isPaginated' and value 'false', indicates that the response is not paginated.
96
- */
97
- }, {
98
- key: "setFlags",
99
- value: function setFlags(flags) {
100
- this.flags = flags;
101
- }
136
+ /**
137
+ * Converts a given snake_case string to camelCase.
138
+ * @param {string} snakeStr - The input string in snake_case format.
139
+ * @returns {string} - The converted string in camelCase format.
140
+ */
141
+ static snakeToCamel(snakeStr) {
142
+ return snakeStr.replace(/(_\w)/g, match => match[1].toUpperCase());
143
+ }
102
144
 
103
- /**
104
- * Returns An array of HATEOAS style links for the response that may also include pagination links for list operations.
105
- * @return {ApiLink[]}
106
- */
107
- }, {
108
- key: "getLinks",
109
- value: function getLinks() {
110
- return this.links;
111
- }
145
+ /**
146
+ * Returns An array of flags that may indicate the status of the response. For example, a flag with the name 'isPaginated' and value 'false', indicates that the response is not paginated.
147
+ * @return {Flag[]}
148
+ */
149
+ getFlags() {
150
+ return this.flags;
151
+ }
112
152
 
113
- /**
114
- * Sets An array of HATEOAS style links for the response that may also include pagination links for list operations.
115
- * @param {ApiLink[]} links An array of HATEOAS style links for the response that may also include pagination links for list operations.
116
- */
117
- }, {
118
- key: "setLinks",
119
- value: function setLinks(links) {
120
- this.links = links;
121
- }
153
+ /**
154
+ * Sets An array of flags that may indicate the status of the response. For example, a flag with the name 'isPaginated' and value 'false', indicates that the response is not paginated.
155
+ * @param {Flag[]} flags An array of flags that may indicate the status of the response. For example, a flag with the name 'isPaginated' and value 'false', indicates that the response is not paginated.
156
+ */
157
+ setFlags(flags) {
158
+ this.flags = flags;
159
+ }
122
160
 
123
- /**
124
- * Returns The total number of entities that are available on the server for this type.
125
- * @return {Number}
126
- */
127
- }, {
128
- key: "getTotalAvailableResults",
129
- value: function getTotalAvailableResults() {
130
- return this.totalAvailableResults;
131
- }
161
+ /**
162
+ * Returns An array of HATEOAS style links for the response that may also include pagination links for list operations.
163
+ * @return {ApiLink[]}
164
+ */
165
+ getLinks() {
166
+ return this.links;
167
+ }
132
168
 
133
- /**
134
- * Sets The total number of entities that are available on the server for this type.
135
- * @param {Number} totalAvailableResults The total number of entities that are available on the server for this type.
136
- */
137
- }, {
138
- key: "setTotalAvailableResults",
139
- value: function setTotalAvailableResults(totalAvailableResults) {
140
- this.totalAvailableResults = totalAvailableResults;
141
- }
169
+ /**
170
+ * Sets An array of HATEOAS style links for the response that may also include pagination links for list operations.
171
+ * @param {ApiLink[]} links An array of HATEOAS style links for the response that may also include pagination links for list operations.
172
+ */
173
+ setLinks(links) {
174
+ this.links = links;
175
+ }
142
176
 
143
- /**
144
- * Returns Information, Warning or Error messages that might provide additional contextual information related to the operation.
145
- * @return {Message[]}
146
- */
147
- }, {
148
- key: "getMessages",
149
- value: function getMessages() {
150
- return this.messages;
151
- }
177
+ /**
178
+ * Returns The total number of entities that are available on the server for this type.
179
+ * @return {Number}
180
+ */
181
+ getTotalAvailableResults() {
182
+ return this.totalAvailableResults;
183
+ }
152
184
 
153
- /**
154
- * Sets Information, Warning or Error messages that might provide additional contextual information related to the operation.
155
- * @param {Message[]} messages Information, Warning or Error messages that might provide additional contextual information related to the operation.
156
- */
157
- }, {
158
- key: "setMessages",
159
- value: function setMessages(messages) {
160
- this.messages = messages;
161
- }
185
+ /**
186
+ * Sets The total number of entities that are available on the server for this type.
187
+ * @param {Number} totalAvailableResults The total number of entities that are available on the server for this type.
188
+ */
189
+ setTotalAvailableResults(totalAvailableResults) {
190
+ this.totalAvailableResults = totalAvailableResults;
191
+ }
162
192
 
163
- /**
164
- * Returns An array of entity-specific metadata
165
- * @return {KVPair[]}
166
- */
167
- }, {
168
- key: "getExtraInfo",
169
- value: function getExtraInfo() {
170
- return this.extraInfo;
171
- }
193
+ /**
194
+ * Returns Information, Warning or Error messages that might provide additional contextual information related to the operation.
195
+ * @return {Message[]}
196
+ */
197
+ getMessages() {
198
+ return this.messages;
199
+ }
172
200
 
173
- /**
174
- * Sets An array of entity-specific metadata
175
- * @param {KVPair[]} extraInfo An array of entity-specific metadata
176
- */
177
- }, {
178
- key: "setExtraInfo",
179
- value: function setExtraInfo(extraInfo) {
180
- this.extraInfo = extraInfo;
181
- }
182
- }, {
183
- key: "get$Reserved",
184
- value: function get$Reserved() {
185
- return this.$reserved;
186
- }
187
- }, {
188
- key: "get$ObjectType",
189
- value: function get$ObjectType() {
190
- return this.$objectType;
191
- }
192
- }, {
193
- key: "get$UnknownFields",
194
- value: function get$UnknownFields() {
195
- return this.$unknownFields;
196
- }
197
- }, {
198
- key: "toJson",
199
- value: function toJson(forMutation) {
200
- if (forMutation === false) {
201
- return _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({}, typeof this.getFlags() !== 'undefined' && this.getFlags() !== null ? {
202
- 'flags': this.getFlags().map(function (item) {
203
- return item.toJson(false);
204
- })
205
- } : {}), typeof this.getLinks() !== 'undefined' && this.getLinks() !== null ? {
206
- 'links': this.getLinks().map(function (item) {
207
- return item.toJson(false);
208
- })
209
- } : {}), typeof this.getTotalAvailableResults() !== 'undefined' && this.getTotalAvailableResults() !== null ? {
201
+ /**
202
+ * Sets Information, Warning or Error messages that might provide additional contextual information related to the operation.
203
+ * @param {Message[]} messages Information, Warning or Error messages that might provide additional contextual information related to the operation.
204
+ */
205
+ setMessages(messages) {
206
+ this.messages = messages;
207
+ }
208
+
209
+ /**
210
+ * Returns An array of entity-specific metadata
211
+ * @return {KVPair[]}
212
+ */
213
+ getExtraInfo() {
214
+ return this.extraInfo;
215
+ }
216
+
217
+ /**
218
+ * Sets An array of entity-specific metadata
219
+ * @param {KVPair[]} extraInfo An array of entity-specific metadata
220
+ */
221
+ setExtraInfo(extraInfo) {
222
+ this.extraInfo = extraInfo;
223
+ }
224
+ get$Reserved() {
225
+ return this.$reserved;
226
+ }
227
+ get$ObjectType() {
228
+ return this.$objectType;
229
+ }
230
+ get$UnknownFields() {
231
+ return this.$unknownFields;
232
+ }
233
+ toJson(forMutation) {
234
+ if (forMutation === false) {
235
+ return {
236
+ ...(typeof this.getFlags() !== 'undefined' && this.getFlags() !== null ? {
237
+ 'flags': this.getFlags().map(item => item.toJson(false))
238
+ } : {}),
239
+ ...(typeof this.getLinks() !== 'undefined' && this.getLinks() !== null ? {
240
+ 'links': this.getLinks().map(item => item.toJson(false))
241
+ } : {}),
242
+ ...(typeof this.getTotalAvailableResults() !== 'undefined' && this.getTotalAvailableResults() !== null ? {
210
243
  'totalAvailableResults': this.getTotalAvailableResults()
211
- } : {}), typeof this.getMessages() !== 'undefined' && this.getMessages() !== null ? {
212
- 'messages': this.getMessages().map(function (item) {
213
- return item.toJson(false);
214
- })
215
- } : {}), typeof this.getExtraInfo() !== 'undefined' && this.getExtraInfo() !== null ? {
216
- 'extraInfo': this.getExtraInfo().map(function (item) {
217
- return item.toJson(false);
218
- })
219
- } : {}), {}, {
220
- '$reserved': this.get$Reserved(),
221
- '$objectType': this.get$ObjectType(),
222
- '$unknownFields': this.get$UnknownFields()
223
- });
224
- }
225
- return _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({}, typeof this.getFlags() !== 'undefined' && this.getFlags() !== null ? {
226
- 'flags': this.getFlags().map(function (item) {
227
- return item.toJson(false);
228
- })
229
- } : {}), typeof this.getLinks() !== 'undefined' && this.getLinks() !== null ? {
230
- 'links': this.getLinks().map(function (item) {
231
- return item.toJson(false);
232
- })
233
- } : {}), typeof this.getTotalAvailableResults() !== 'undefined' && this.getTotalAvailableResults() !== null ? {
234
- 'totalAvailableResults': this.getTotalAvailableResults()
235
- } : {}), typeof this.getMessages() !== 'undefined' && this.getMessages() !== null ? {
236
- 'messages': this.getMessages().map(function (item) {
237
- return item.toJson(false);
238
- })
239
- } : {}), typeof this.getExtraInfo() !== 'undefined' && this.getExtraInfo() !== null ? {
240
- 'extraInfo': this.getExtraInfo().map(function (item) {
241
- return item.toJson(false);
242
- })
243
- } : {}), {}, {
244
+ } : {}),
245
+ ...(typeof this.getMessages() !== 'undefined' && this.getMessages() !== null ? {
246
+ 'messages': this.getMessages().map(item => item.toJson(false))
247
+ } : {}),
248
+ ...(typeof this.getExtraInfo() !== 'undefined' && this.getExtraInfo() !== null ? {
249
+ 'extraInfo': this.getExtraInfo().map(item => item.toJson(false))
250
+ } : {}),
244
251
  '$reserved': this.get$Reserved(),
245
252
  '$objectType': this.get$ObjectType(),
246
- '$unknownFields': this.get$UnknownFields()
247
- });
253
+ ...(typeof this.get$UnknownFields() !== 'undefined' && this.get$UnknownFields() !== null ? this.get$UnknownFields() : {}),
254
+ '$unknownFields': {}
255
+ };
248
256
  }
249
- }, {
250
- key: "validate",
251
- value: function validate(scope, properties) {
252
- var _this = this;
253
- var propList = [];
254
- if (arguments.length === 0 || arguments.length === 1 && arguments[0] instanceof _ValidationScopes["default"]) {
255
- //cases validate() and validate(scope)
256
- propList = [];
257
- } else if (arguments.length === 1) {
258
- //case validate(properties)
259
- propList = arguments[0];
260
- scope = null;
257
+ return {
258
+ ...(typeof this.getFlags() !== 'undefined' && this.getFlags() !== null ? {
259
+ 'flags': this.getFlags().map(item => item.toJson(false))
260
+ } : {}),
261
+ ...(typeof this.getLinks() !== 'undefined' && this.getLinks() !== null ? {
262
+ 'links': this.getLinks().map(item => item.toJson(false))
263
+ } : {}),
264
+ ...(typeof this.getTotalAvailableResults() !== 'undefined' && this.getTotalAvailableResults() !== null ? {
265
+ 'totalAvailableResults': this.getTotalAvailableResults()
266
+ } : {}),
267
+ ...(typeof this.getMessages() !== 'undefined' && this.getMessages() !== null ? {
268
+ 'messages': this.getMessages().map(item => item.toJson(false))
269
+ } : {}),
270
+ ...(typeof this.getExtraInfo() !== 'undefined' && this.getExtraInfo() !== null ? {
271
+ 'extraInfo': this.getExtraInfo().map(item => item.toJson(false))
272
+ } : {}),
273
+ '$reserved': this.get$Reserved(),
274
+ '$objectType': this.get$ObjectType(),
275
+ ...(typeof this.get$UnknownFields() !== 'undefined' && this.get$UnknownFields() !== null ? this.get$UnknownFields() : {}),
276
+ '$unknownFields': {}
277
+ };
278
+ }
279
+ validate(scope, properties) {
280
+ let propList = [];
281
+ if (arguments.length === 0 || arguments.length === 1 && arguments[0] instanceof _ValidationScopes.default) {
282
+ //cases validate() and validate(scope)
283
+ propList = [];
284
+ } else if (arguments.length === 1) {
285
+ //case validate(properties)
286
+ propList = arguments[0];
287
+ scope = null;
288
+ } else {
289
+ //case validate(scope, properties)
290
+ propList = arguments[1];
291
+ }
292
+ let res = [];
293
+ let err = null;
294
+ propList.forEach(property => {
295
+ err = this.validateProperty(property, scope);
296
+ if (err) {
297
+ res.push(err);
298
+ }
299
+ });
300
+ return new Promise(function (resolve, reject) {
301
+ if (res.length !== 0) {
302
+ reject(err);
261
303
  } else {
262
- //case validate(scope, properties)
263
- propList = arguments[1];
304
+ resolve();
305
+ }
306
+ });
307
+ }
308
+ validateProperty(scope, property) {
309
+ if (property === "flags") {
310
+ if (typeof this.flags === 'undefined' || this.flags === null) {
311
+ return new _ValidationError.default("flags", "undefined or null");
312
+ }
313
+ if (!_ValidationUtils.default.validateMaxItems(this.flags, 20)) {
314
+ return new _ValidationError.default("flags", "does not satisfy required maxItems constraint: 20");
264
315
  }
265
- var res = [];
266
- var err = null;
267
- propList.forEach(function (property) {
268
- err = _this.validateProperty(property, scope);
269
- if (err) {
270
- res.push(err);
271
- }
272
- });
273
- return new Promise(function (resolve, reject) {
274
- if (res.length !== 0) {
275
- reject(err);
276
- } else {
277
- resolve();
278
- }
279
- });
280
316
  }
281
- }, {
282
- key: "validateProperty",
283
- value: function validateProperty(scope, property) {
284
- if (property === "flags") {
285
- if (typeof this.flags === 'undefined' || this.flags === null) {
286
- return new _ValidationError["default"]("flags", "undefined or null");
287
- }
288
- if (!_ValidationUtils["default"].validateMaxItems(this.flags, 20)) {
289
- return new _ValidationError["default"]("flags", "does not satisfy required maxItems constraint: 20");
290
- }
317
+ if (property === "links") {
318
+ if (typeof this.links === 'undefined' || this.links === null) {
319
+ return new _ValidationError.default("links", "undefined or null");
291
320
  }
292
- if (property === "links") {
293
- if (typeof this.links === 'undefined' || this.links === null) {
294
- return new _ValidationError["default"]("links", "undefined or null");
295
- }
296
- if (!_ValidationUtils["default"].validateMaxItems(this.links, 20)) {
297
- return new _ValidationError["default"]("links", "does not satisfy required maxItems constraint: 20");
298
- }
321
+ if (!_ValidationUtils.default.validateMaxItems(this.links, 20)) {
322
+ return new _ValidationError.default("links", "does not satisfy required maxItems constraint: 20");
299
323
  }
300
- if (property === "totalAvailableResults") {
301
- if (typeof this.totalAvailableResults === 'undefined' || this.totalAvailableResults === null) {
302
- return new _ValidationError["default"]("totalAvailableResults", "undefined or null");
303
- }
324
+ }
325
+ if (property === "totalAvailableResults") {
326
+ if (typeof this.totalAvailableResults === 'undefined' || this.totalAvailableResults === null) {
327
+ return new _ValidationError.default("totalAvailableResults", "undefined or null");
304
328
  }
305
- if (property === "messages") {
306
- if (typeof this.messages === 'undefined' || this.messages === null) {
307
- return new _ValidationError["default"]("messages", "undefined or null");
308
- }
309
- if (!_ValidationUtils["default"].validateMaxItems(this.messages, 20)) {
310
- return new _ValidationError["default"]("messages", "does not satisfy required maxItems constraint: 20");
311
- }
329
+ }
330
+ if (property === "messages") {
331
+ if (typeof this.messages === 'undefined' || this.messages === null) {
332
+ return new _ValidationError.default("messages", "undefined or null");
312
333
  }
313
- if (property === "extraInfo") {
314
- if (typeof this.extraInfo === 'undefined' || this.extraInfo === null) {
315
- return new _ValidationError["default"]("extraInfo", "undefined or null");
316
- }
317
- if (!_ValidationUtils["default"].validateMaxItems(this.extraInfo, 20)) {
318
- return new _ValidationError["default"]("extraInfo", "does not satisfy required maxItems constraint: 20");
319
- }
334
+ if (!_ValidationUtils.default.validateMaxItems(this.messages, 20)) {
335
+ return new _ValidationError.default("messages", "does not satisfy required maxItems constraint: 20");
320
336
  }
321
- if (property === "$reserved") {
322
- if (typeof this.$reserved === 'undefined' || this.$reserved === null) {
323
- return new _ValidationError["default"]("$reserved", "undefined or null");
324
- }
337
+ }
338
+ if (property === "extraInfo") {
339
+ if (typeof this.extraInfo === 'undefined' || this.extraInfo === null) {
340
+ return new _ValidationError.default("extraInfo", "undefined or null");
325
341
  }
326
- if (property === "$objectType") {
327
- if (typeof this.$objectType === 'undefined' || this.$objectType === null) {
328
- return new _ValidationError["default"]("$objectType", "undefined or null");
329
- }
342
+ if (!_ValidationUtils.default.validateMaxItems(this.extraInfo, 20)) {
343
+ return new _ValidationError.default("extraInfo", "does not satisfy required maxItems constraint: 20");
330
344
  }
331
- if (property === "$unknownFields") {
332
- if (typeof this.$unknownFields === 'undefined' || this.$unknownFields === null) {
333
- return new _ValidationError["default"]("$unknownFields", "undefined or null");
334
- }
345
+ }
346
+ if (property === "$reserved") {
347
+ if (typeof this.$reserved === 'undefined' || this.$reserved === null) {
348
+ return new _ValidationError.default("$reserved", "undefined or null");
335
349
  }
336
- return new _ValidationError["default"](property, "no such property exists");
337
350
  }
338
- }], [{
339
- key: "constructFromObject",
340
- value: function constructFromObject(data) {
341
- var obj = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
342
- var callFromChild = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
343
- var items, item, i, itemArr, discriminator;
344
- if (data) {
345
- obj = obj || new ApiResponseMetadata();
346
- if (data.hasOwnProperty('flags') && data.flags !== null && data.flags !== undefined) {
347
- itemArr = [];
348
- items = data.flags;
349
- for (i = 0; i < items.length; i++) {
350
- item = _Flag["default"].constructFromObject(items[i], undefined);
351
- itemArr.push(item);
352
- }
353
- obj.setFlags(itemArr);
354
- }
355
- if (data.hasOwnProperty('links') && data.links !== null && data.links !== undefined) {
356
- itemArr = [];
357
- items = data.links;
358
- for (i = 0; i < items.length; i++) {
359
- item = _ApiLink["default"].constructFromObject(items[i], undefined);
360
- itemArr.push(item);
361
- }
362
- obj.setLinks(itemArr);
363
- }
364
- if (data.hasOwnProperty('totalAvailableResults') && data.totalAvailableResults !== null && data.totalAvailableResults !== undefined) {
365
- obj.setTotalAvailableResults(data['totalAvailableResults']);
366
- }
367
- if (data.hasOwnProperty('messages') && data.messages !== null && data.messages !== undefined) {
368
- itemArr = [];
369
- items = data.messages;
370
- for (i = 0; i < items.length; i++) {
371
- item = _Message["default"].constructFromObject(items[i], undefined);
372
- itemArr.push(item);
373
- }
374
- obj.setMessages(itemArr);
375
- }
376
- if (data.hasOwnProperty('extraInfo') && data.extraInfo !== null && data.extraInfo !== undefined) {
377
- itemArr = [];
378
- items = data.extraInfo;
379
- for (i = 0; i < items.length; i++) {
380
- item = _KVPair["default"].constructFromObject(items[i], undefined);
381
- itemArr.push(item);
382
- }
383
- obj.setExtraInfo(itemArr);
384
- }
385
- if (data.hasOwnProperty('$reserved')) {
386
- obj.$reserved = data['$reserved'];
387
- }
388
- if (data.hasOwnProperty('$objectType')) {
389
- obj.$objectType = data['$objectType'];
390
- }
391
- if (data.hasOwnProperty('$unknownFields')) {
392
- obj.$unknownFields = data['$unknownFields'];
393
- }
394
- if (!callFromChild) {
395
- obj.$unknownFields = _objectSpread({}, data.$unknownFields);
396
- for (var property in data) {
397
- // Check if the `property` is not already present in `obj` keys, either in snake_case or camelCase,
398
- // as the model's fields are generated in camelCase, but the server might return snake_case (e.g., due to standards like OIDC).
399
- // Also, ensure the `property` does not start with '$' and end with 'ItemDiscriminator'.
400
- // If all conditions are true, add the `property` from `data` to `obj.$unknownFields` as an unknown field.
401
- if (!Object.keys(obj).includes(property) && !Object.keys(obj).includes(this.snakeToCamel(property)) && !(property[0] === "$" && property.endsWith("ItemDiscriminator"))) {
402
- obj.$unknownFields[property] = data[property];
403
- }
404
- }
405
- }
351
+ if (property === "$objectType") {
352
+ if (typeof this.$objectType === 'undefined' || this.$objectType === null) {
353
+ return new _ValidationError.default("$objectType", "undefined or null");
406
354
  }
407
- return obj;
408
355
  }
409
-
410
- /**
411
- * Converts a given snake_case string to camelCase.
412
- * @param {string} snakeStr - The input string in snake_case format.
413
- * @returns {string} - The converted string in camelCase format.
414
- */
415
- }, {
416
- key: "snakeToCamel",
417
- value: function snakeToCamel(snakeStr) {
418
- return snakeStr.replace(/(_\w)/g, function (match) {
419
- return match[1].toUpperCase();
420
- });
356
+ if (property === "$unknownFields") {
357
+ if (typeof this.$unknownFields === 'undefined' || this.$unknownFields === null) {
358
+ return new _ValidationError.default("$unknownFields", "undefined or null");
359
+ }
421
360
  }
422
- }]);
423
- }();
361
+ return new _ValidationError.default(property, "no such property exists");
362
+ }
363
+ }
364
+
424
365
  /**
425
366
  * An array of flags that may indicate the status of the response. For example, a flag with the name 'isPaginated' and value 'false', indicates that the response is not paginated.
426
367
  * @memberof ApiResponseMetadata
427
368
  */
369
+ exports.default = ApiResponseMetadata;
428
370
  function _toJsonMapType(obj, forMutation) {
429
371
  if (obj instanceof Map) {
430
- return Object.fromEntries(Array.from(obj, function (_ref) {
431
- var _ref2 = _slicedToArray(_ref, 2),
432
- k = _ref2[0],
433
- v = _ref2[1];
434
- return [k, typeof v.toJson !== "undefined" ? v.toJson(forMutation) : v];
435
- }));
436
- } else if (_typeof(obj) === 'object' && obj != null && obj.constructor === Object) {
437
- return Object.fromEntries(Array.from(Object.entries(obj), function (entry) {
372
+ return Object.fromEntries(Array.from(obj, ([k, v]) => [k, typeof v.toJson !== "undefined" ? v.toJson(forMutation) : v]));
373
+ } else if (typeof obj === 'object' && obj != null && obj.constructor === Object) {
374
+ return Object.fromEntries(Array.from(Object.entries(obj), entry => {
438
375
  return [entry[0], typeof entry[1].toJson !== "undefined" ? entry[1].toJson(forMutation) : entry[1]];
439
376
  }));
440
377
  }