@nutanix-scratch/objects-js-client 4.0.1 → 4.0.3

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 (174) hide show
  1. package/README.md +31 -18
  2. package/dist/Ntnx-Objects-js-client-prod.js +1 -1
  3. package/dist/Ntnx-Objects-js-client.js +289 -283
  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 +5 -69
  9. package/dist/es/apis/objectstores-endpoints.js +406 -479
  10. package/dist/es/apis/stats-endpoints.d.ts +3 -25
  11. package/dist/es/apis/stats-endpoints.js +75 -107
  12. package/dist/es/index.js +120 -120
  13. package/dist/es/models/common/v1/config/FQDN.d.ts +2 -7
  14. package/dist/es/models/common/v1/config/FQDN.js +141 -180
  15. package/dist/es/models/common/v1/config/Flag.d.ts +2 -8
  16. package/dist/es/models/common/v1/config/Flag.js +170 -211
  17. package/dist/es/models/common/v1/config/IPAddress.d.ts +2 -20
  18. package/dist/es/models/common/v1/config/IPAddress.js +170 -217
  19. package/dist/es/models/common/v1/config/IPv4Address.d.ts +2 -8
  20. package/dist/es/models/common/v1/config/IPv4Address.js +174 -215
  21. package/dist/es/models/common/v1/config/IPv6Address.d.ts +2 -8
  22. package/dist/es/models/common/v1/config/IPv6Address.js +174 -215
  23. package/dist/es/models/common/v1/config/KVPair.d.ts +2 -8
  24. package/dist/es/models/common/v1/config/KVPair.js +225 -270
  25. package/dist/es/models/common/v1/config/MapOfStringWrapper.d.ts +2 -7
  26. package/dist/es/models/common/v1/config/MapOfStringWrapper.js +139 -178
  27. package/dist/es/models/common/v1/config/Message.d.ts +2 -10
  28. package/dist/es/models/common/v1/config/Message.js +213 -258
  29. package/dist/es/models/common/v1/config/MessageSeverity.js +7 -9
  30. package/dist/es/models/common/v1/config/Metadata.d.ts +2 -11
  31. package/dist/es/models/common/v1/config/Metadata.js +261 -308
  32. package/dist/es/models/common/v1/config/TenantAwareModel.d.ts +5 -10
  33. package/dist/es/models/common/v1/config/TenantAwareModel.js +138 -178
  34. package/dist/es/models/common/v1/response/ApiLink.d.ts +2 -8
  35. package/dist/es/models/common/v1/response/ApiLink.js +165 -206
  36. package/dist/es/models/common/v1/response/ApiResponseMetadata.d.ts +2 -40
  37. package/dist/es/models/common/v1/response/ApiResponseMetadata.js +281 -344
  38. package/dist/es/models/common/v1/response/ExternalizableAbstractModel.d.ts +1 -15
  39. package/dist/es/models/common/v1/response/ExternalizableAbstractModel.js +155 -203
  40. package/dist/es/models/common/v1/stats/DownSamplingOperator.js +7 -9
  41. package/dist/es/models/common/v1/stats/TimeIntValuePair.d.ts +2 -8
  42. package/dist/es/models/common/v1/stats/TimeIntValuePair.js +165 -206
  43. package/dist/es/models/objects/v4/config/Certificate.d.ts +1 -58
  44. package/dist/es/models/objects/v4/config/Certificate.js +319 -381
  45. package/dist/es/models/objects/v4/config/CertificateProjection.d.ts +1 -1
  46. package/dist/es/models/objects/v4/config/CertificateProjection.js +73 -102
  47. package/dist/es/models/objects/v4/config/CreateCertificateApiResponse.d.ts +2 -45
  48. package/dist/es/models/objects/v4/config/CreateCertificateApiResponse.js +185 -240
  49. package/dist/es/models/objects/v4/config/CreateObjectstoreApiResponse.d.ts +2 -43
  50. package/dist/es/models/objects/v4/config/CreateObjectstoreApiResponse.js +185 -240
  51. package/dist/es/models/objects/v4/config/DeleteObjectstoreApiResponse.d.ts +2 -43
  52. package/dist/es/models/objects/v4/config/DeleteObjectstoreApiResponse.js +185 -240
  53. package/dist/es/models/objects/v4/config/GetCaApiResponse.d.ts +2 -43
  54. package/dist/es/models/objects/v4/config/GetCaApiResponse.js +185 -240
  55. package/dist/es/models/objects/v4/config/GetCertificateApiResponse.d.ts +2 -43
  56. package/dist/es/models/objects/v4/config/GetCertificateApiResponse.js +185 -240
  57. package/dist/es/models/objects/v4/config/GetObjectstoreApiResponse.d.ts +2 -45
  58. package/dist/es/models/objects/v4/config/GetObjectstoreApiResponse.js +185 -240
  59. package/dist/es/models/objects/v4/config/ListCertificatesApiResponse.d.ts +2 -43
  60. package/dist/es/models/objects/v4/config/ListCertificatesApiResponse.js +211 -266
  61. package/dist/es/models/objects/v4/config/ListObjectstoresApiResponse.d.ts +2 -43
  62. package/dist/es/models/objects/v4/config/ListObjectstoresApiResponse.js +211 -266
  63. package/dist/es/models/objects/v4/config/ObjectStore.d.ts +1 -96
  64. package/dist/es/models/objects/v4/config/ObjectStore.js +628 -711
  65. package/dist/es/models/objects/v4/config/ObjectStoreProjection.d.ts +1 -152
  66. package/dist/es/models/objects/v4/config/ObjectStoreProjection.js +221 -238
  67. package/dist/es/models/objects/v4/config/State.js +7 -9
  68. package/dist/es/models/objects/v4/config/UpdateObjectstoreApiResponse.d.ts +2 -43
  69. package/dist/es/models/objects/v4/config/UpdateObjectstoreApiResponse.js +185 -240
  70. package/dist/es/models/objects/v4/error/AppMessage.d.ts +5 -15
  71. package/dist/es/models/objects/v4/error/AppMessage.js +264 -313
  72. package/dist/es/models/objects/v4/error/ErrorResponse.d.ts +2 -7
  73. package/dist/es/models/objects/v4/error/ErrorResponse.js +174 -217
  74. package/dist/es/models/objects/v4/error/SchemaValidationError.d.ts +2 -18
  75. package/dist/es/models/objects/v4/error/SchemaValidationError.js +248 -299
  76. package/dist/es/models/objects/v4/error/SchemaValidationErrorMessage.d.ts +2 -9
  77. package/dist/es/models/objects/v4/error/SchemaValidationErrorMessage.js +190 -233
  78. package/dist/es/models/objects/v4/stats/GetObjectstoreStatsApiResponse.d.ts +2 -43
  79. package/dist/es/models/objects/v4/stats/GetObjectstoreStatsApiResponse.js +185 -240
  80. package/dist/es/models/objects/v4/stats/ObjectstoreStats.d.ts +1 -169
  81. package/dist/es/models/objects/v4/stats/ObjectstoreStats.js +957 -1129
  82. package/dist/es/models/objects/v4/stats/TimeFloatValuePair.d.ts +2 -8
  83. package/dist/es/models/objects/v4/stats/TimeFloatValuePair.js +165 -206
  84. package/dist/es/models/prism/v4/config/TaskReference.d.ts +5 -10
  85. package/dist/es/models/prism/v4/config/TaskReference.js +143 -182
  86. package/dist/es/models/validation/ValidationError.js +26 -42
  87. package/dist/es/models/validation/ValidationScopes.js +3 -3
  88. package/dist/es/utils/ValidationUtils.js +39 -69
  89. package/dist/lib/ApiClient.d.ts +35 -7
  90. package/dist/lib/ApiClient.js +862 -684
  91. package/dist/lib/Paginable.d.ts +1 -1
  92. package/dist/lib/Paginable.js +144 -183
  93. package/dist/lib/apis/objectstores-endpoints.d.ts +5 -69
  94. package/dist/lib/apis/objectstores-endpoints.js +406 -479
  95. package/dist/lib/apis/stats-endpoints.d.ts +3 -25
  96. package/dist/lib/apis/stats-endpoints.js +75 -107
  97. package/dist/lib/index.js +120 -120
  98. package/dist/lib/models/common/v1/config/FQDN.d.ts +2 -7
  99. package/dist/lib/models/common/v1/config/FQDN.js +141 -180
  100. package/dist/lib/models/common/v1/config/Flag.d.ts +2 -8
  101. package/dist/lib/models/common/v1/config/Flag.js +170 -211
  102. package/dist/lib/models/common/v1/config/IPAddress.d.ts +2 -20
  103. package/dist/lib/models/common/v1/config/IPAddress.js +170 -217
  104. package/dist/lib/models/common/v1/config/IPv4Address.d.ts +2 -8
  105. package/dist/lib/models/common/v1/config/IPv4Address.js +174 -215
  106. package/dist/lib/models/common/v1/config/IPv6Address.d.ts +2 -8
  107. package/dist/lib/models/common/v1/config/IPv6Address.js +174 -215
  108. package/dist/lib/models/common/v1/config/KVPair.d.ts +2 -8
  109. package/dist/lib/models/common/v1/config/KVPair.js +225 -270
  110. package/dist/lib/models/common/v1/config/MapOfStringWrapper.d.ts +2 -7
  111. package/dist/lib/models/common/v1/config/MapOfStringWrapper.js +139 -178
  112. package/dist/lib/models/common/v1/config/Message.d.ts +2 -10
  113. package/dist/lib/models/common/v1/config/Message.js +213 -258
  114. package/dist/lib/models/common/v1/config/MessageSeverity.js +7 -9
  115. package/dist/lib/models/common/v1/config/Metadata.d.ts +2 -11
  116. package/dist/lib/models/common/v1/config/Metadata.js +261 -308
  117. package/dist/lib/models/common/v1/config/TenantAwareModel.d.ts +5 -10
  118. package/dist/lib/models/common/v1/config/TenantAwareModel.js +138 -178
  119. package/dist/lib/models/common/v1/response/ApiLink.d.ts +2 -8
  120. package/dist/lib/models/common/v1/response/ApiLink.js +165 -206
  121. package/dist/lib/models/common/v1/response/ApiResponseMetadata.d.ts +2 -40
  122. package/dist/lib/models/common/v1/response/ApiResponseMetadata.js +281 -344
  123. package/dist/lib/models/common/v1/response/ExternalizableAbstractModel.d.ts +1 -15
  124. package/dist/lib/models/common/v1/response/ExternalizableAbstractModel.js +155 -203
  125. package/dist/lib/models/common/v1/stats/DownSamplingOperator.js +7 -9
  126. package/dist/lib/models/common/v1/stats/TimeIntValuePair.d.ts +2 -8
  127. package/dist/lib/models/common/v1/stats/TimeIntValuePair.js +165 -206
  128. package/dist/lib/models/objects/v4/config/Certificate.d.ts +1 -58
  129. package/dist/lib/models/objects/v4/config/Certificate.js +319 -381
  130. package/dist/lib/models/objects/v4/config/CertificateProjection.d.ts +1 -1
  131. package/dist/lib/models/objects/v4/config/CertificateProjection.js +73 -102
  132. package/dist/lib/models/objects/v4/config/CreateCertificateApiResponse.d.ts +2 -45
  133. package/dist/lib/models/objects/v4/config/CreateCertificateApiResponse.js +185 -240
  134. package/dist/lib/models/objects/v4/config/CreateObjectstoreApiResponse.d.ts +2 -43
  135. package/dist/lib/models/objects/v4/config/CreateObjectstoreApiResponse.js +185 -240
  136. package/dist/lib/models/objects/v4/config/DeleteObjectstoreApiResponse.d.ts +2 -43
  137. package/dist/lib/models/objects/v4/config/DeleteObjectstoreApiResponse.js +185 -240
  138. package/dist/lib/models/objects/v4/config/GetCaApiResponse.d.ts +2 -43
  139. package/dist/lib/models/objects/v4/config/GetCaApiResponse.js +185 -240
  140. package/dist/lib/models/objects/v4/config/GetCertificateApiResponse.d.ts +2 -43
  141. package/dist/lib/models/objects/v4/config/GetCertificateApiResponse.js +185 -240
  142. package/dist/lib/models/objects/v4/config/GetObjectstoreApiResponse.d.ts +2 -45
  143. package/dist/lib/models/objects/v4/config/GetObjectstoreApiResponse.js +185 -240
  144. package/dist/lib/models/objects/v4/config/ListCertificatesApiResponse.d.ts +2 -43
  145. package/dist/lib/models/objects/v4/config/ListCertificatesApiResponse.js +211 -266
  146. package/dist/lib/models/objects/v4/config/ListObjectstoresApiResponse.d.ts +2 -43
  147. package/dist/lib/models/objects/v4/config/ListObjectstoresApiResponse.js +211 -266
  148. package/dist/lib/models/objects/v4/config/ObjectStore.d.ts +1 -96
  149. package/dist/lib/models/objects/v4/config/ObjectStore.js +628 -711
  150. package/dist/lib/models/objects/v4/config/ObjectStoreProjection.d.ts +1 -152
  151. package/dist/lib/models/objects/v4/config/ObjectStoreProjection.js +221 -238
  152. package/dist/lib/models/objects/v4/config/State.js +7 -9
  153. package/dist/lib/models/objects/v4/config/UpdateObjectstoreApiResponse.d.ts +2 -43
  154. package/dist/lib/models/objects/v4/config/UpdateObjectstoreApiResponse.js +185 -240
  155. package/dist/lib/models/objects/v4/error/AppMessage.d.ts +5 -15
  156. package/dist/lib/models/objects/v4/error/AppMessage.js +264 -313
  157. package/dist/lib/models/objects/v4/error/ErrorResponse.d.ts +2 -7
  158. package/dist/lib/models/objects/v4/error/ErrorResponse.js +174 -217
  159. package/dist/lib/models/objects/v4/error/SchemaValidationError.d.ts +2 -18
  160. package/dist/lib/models/objects/v4/error/SchemaValidationError.js +248 -299
  161. package/dist/lib/models/objects/v4/error/SchemaValidationErrorMessage.d.ts +2 -9
  162. package/dist/lib/models/objects/v4/error/SchemaValidationErrorMessage.js +190 -233
  163. package/dist/lib/models/objects/v4/stats/GetObjectstoreStatsApiResponse.d.ts +2 -43
  164. package/dist/lib/models/objects/v4/stats/GetObjectstoreStatsApiResponse.js +185 -240
  165. package/dist/lib/models/objects/v4/stats/ObjectstoreStats.d.ts +1 -169
  166. package/dist/lib/models/objects/v4/stats/ObjectstoreStats.js +957 -1129
  167. package/dist/lib/models/objects/v4/stats/TimeFloatValuePair.d.ts +2 -8
  168. package/dist/lib/models/objects/v4/stats/TimeFloatValuePair.js +165 -206
  169. package/dist/lib/models/prism/v4/config/TaskReference.d.ts +5 -10
  170. package/dist/lib/models/prism/v4/config/TaskReference.js +143 -182
  171. package/dist/lib/models/validation/ValidationError.js +26 -42
  172. package/dist/lib/models/validation/ValidationScopes.js +3 -3
  173. package/dist/lib/utils/ValidationUtils.js +39 -69
  174. 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 _IPAddress = _interopRequireDefault(require("../../../common/v1/config/IPAddress"));
8
8
  var _Metadata = _interopRequireDefault(require("../../../common/v1/config/Metadata"));
9
9
  var _TenantAwareModel = _interopRequireDefault(require("../../../common/v1/config/TenantAwareModel"));
@@ -13,39 +13,17 @@ var _State = _interopRequireDefault(require("./State"));
13
13
  var _ValidationScopes = _interopRequireDefault(require("../../../validation/ValidationScopes"));
14
14
  var _ValidationUtils = _interopRequireDefault(require("../../../../utils/ValidationUtils"));
15
15
  var _ValidationError = _interopRequireDefault(require("../../../validation/ValidationError"));
16
- function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
17
- 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); }
18
- function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
19
- 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."); }
20
- 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; } }
21
- 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; }
22
- 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; } }
23
- function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
24
- 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; }
25
- 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; }
26
- 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; }
27
- function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
28
- 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); } }
29
- function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
30
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
31
- 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); }
32
- function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
33
- function _possibleConstructorReturn(t, e) { if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); return _assertThisInitialized(t); }
34
- function _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); return e; }
35
- function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
36
- function _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }
37
- function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
38
- function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
16
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
39
17
  function _classPrivateMethodInitSpec(e, a) { _checkPrivateRedeclaration(e, a), a.add(e); }
40
18
  function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); }
41
19
  function _assertClassBrand(e, t, n) { if ("function" == typeof e ? e === t : e.has(t)) return arguments.length < 3 ? t : n; throw new TypeError("Private element is not present on this object"); } /*
42
20
  * Nutanix Objects Storage Management APIs
43
21
  *
44
- * OpenAPI spec version: 4.0.1
22
+ * OpenAPI spec version: 4.0.3
45
23
  *
46
24
  * NOTE: This class is auto generated by the Open API Dev Platform.
47
25
  *
48
- * Open API Dev Platform Codegen version: 16.9.1.8738-RELEASE
26
+ * Open API Dev Platform Codegen version: 17.5.1.10573-RELEASE
49
27
  *
50
28
  * Do not edit the class manually.
51
29
  *
@@ -53,14 +31,14 @@ function _assertClassBrand(e, t, n) { if ("function" == typeof e ? e === t : e.h
53
31
  /**
54
32
  * The ObjectStore model module.
55
33
  * @module Ntnx/ObjectStore
56
- * @version 4.0.1
34
+ * @version 4.0.3
57
35
  * @class ObjectStore
58
36
  * @extends ExternalizableAbstractModel
59
37
  *
60
38
  * @param { string } name The name of the Object store.
61
39
  */
62
40
  var _ObjectStore_brand = /*#__PURE__*/new WeakSet();
63
- var ObjectStore = exports["default"] = /*#__PURE__*/function (_ExternalizableAbstra) {
41
+ class ObjectStore extends _ExternalizableAbstractModel.default {
64
42
  /**
65
43
  * Constructs a new <code>ObjectStore</code>.
66
44
  * @alias module:Ntnx/ObjectStore
@@ -68,26 +46,23 @@ var ObjectStore = exports["default"] = /*#__PURE__*/function (_ExternalizableAbs
68
46
  *
69
47
  * @param { string } name The name of the Object store.
70
48
  */
71
- function ObjectStore(name) {
72
- var _this;
73
- _classCallCheck(this, ObjectStore);
74
- _this = _callSuper(this, ObjectStore);
49
+ constructor(name) {
50
+ super();
75
51
  /*
76
52
  * toJson method for a map type which supports map with primitive keys and values of object types
77
53
  * @param {Object} obj
78
54
  * @returns {Object|Map} Returns a new transofrmed Map by calling toJson on the values if applicable.
79
55
  * Otherwise, just returns the input object.
80
56
  */
81
- _classPrivateMethodInitSpec(_this, _ObjectStore_brand);
82
- _this.name = name;
83
- _this.$objectType = "objects.v4.config.ObjectStore";
57
+ _classPrivateMethodInitSpec(this, _ObjectStore_brand);
58
+ this.name = name;
59
+ this.$objectType = "objects.v4.config.ObjectStore";
84
60
  /** @type {object<string, any>} */
85
- _this.$reserved = {
61
+ this.$reserved = {
86
62
  '$fv': "v4.r0"
87
63
  };
88
64
  /** @type {object<string, any>} */
89
- _this.$unknownFields = {};
90
- return _this;
65
+ this.$unknownFields = {};
91
66
  }
92
67
 
93
68
  /**
@@ -98,773 +73,715 @@ var ObjectStore = exports["default"] = /*#__PURE__*/function (_ExternalizableAbs
98
73
  * @param callFromChild {Boolean} Flag to recognise calling instance
99
74
  * @return {module:Ntnx/ObjectStore} The populated <code>ObjectStore</code> instance.
100
75
  */
101
- _inherits(ObjectStore, _ExternalizableAbstra);
102
- return _createClass(ObjectStore, [{
103
- key: "getMetadata",
104
- value:
105
- /**
106
- * @return {Metadata}
107
- */
108
- function getMetadata() {
109
- return this.metadata;
76
+ static constructFromObject(data, obj = null, callFromChild = false) {
77
+ let items, item, i, itemArr, discriminator;
78
+ if (data) {
79
+ obj = obj || new ObjectStore();
80
+ _ExternalizableAbstractModel.default.constructFromObject(data, obj, true);
81
+ if (data.hasOwnProperty('metadata') && data.metadata !== null && data.metadata !== undefined) {
82
+ obj.setMetadata(_Metadata.default.constructFromObject(data['metadata']));
83
+ }
84
+ if (data.hasOwnProperty('name') && data.name !== null && data.name !== undefined) {
85
+ obj.setName(data['name']);
86
+ }
87
+ if (data.hasOwnProperty('creationTime') && data.creationTime !== null && data.creationTime !== undefined) {
88
+ obj.setCreationTime(data['creationTime']);
89
+ }
90
+ if (data.hasOwnProperty('lastUpdateTime') && data.lastUpdateTime !== null && data.lastUpdateTime !== undefined) {
91
+ obj.setLastUpdateTime(data['lastUpdateTime']);
92
+ }
93
+ if (data.hasOwnProperty('description') && data.description !== null && data.description !== undefined) {
94
+ obj.setDescription(data['description']);
95
+ }
96
+ if (data.hasOwnProperty('deploymentVersion') && data.deploymentVersion !== null && data.deploymentVersion !== undefined) {
97
+ obj.setDeploymentVersion(data['deploymentVersion']);
98
+ }
99
+ if (data.hasOwnProperty('domain') && data.domain !== null && data.domain !== undefined) {
100
+ obj.setDomain(data['domain']);
101
+ }
102
+ if (data.hasOwnProperty('region') && data.region !== null && data.region !== undefined) {
103
+ obj.setRegion(data['region']);
104
+ }
105
+ if (data.hasOwnProperty('numWorkerNodes') && data.numWorkerNodes !== null && data.numWorkerNodes !== undefined) {
106
+ obj.setNumWorkerNodes(data['numWorkerNodes']);
107
+ }
108
+ if (data.hasOwnProperty('clusterExtId') && data.clusterExtId !== null && data.clusterExtId !== undefined) {
109
+ obj.setClusterExtId(data['clusterExtId']);
110
+ }
111
+ if (data.hasOwnProperty('storageNetworkReference') && data.storageNetworkReference !== null && data.storageNetworkReference !== undefined) {
112
+ obj.setStorageNetworkReference(data['storageNetworkReference']);
113
+ }
114
+ if (data.hasOwnProperty('storageNetworkVip') && data.storageNetworkVip !== null && data.storageNetworkVip !== undefined) {
115
+ obj.setStorageNetworkVip(_IPAddress.default.constructFromObject(data['storageNetworkVip']));
116
+ }
117
+ if (data.hasOwnProperty('storageNetworkDnsIp') && data.storageNetworkDnsIp !== null && data.storageNetworkDnsIp !== undefined) {
118
+ obj.setStorageNetworkDnsIp(_IPAddress.default.constructFromObject(data['storageNetworkDnsIp']));
119
+ }
120
+ if (data.hasOwnProperty('publicNetworkReference') && data.publicNetworkReference !== null && data.publicNetworkReference !== undefined) {
121
+ obj.setPublicNetworkReference(data['publicNetworkReference']);
122
+ }
123
+ if (data.hasOwnProperty('publicNetworkIps') && data.publicNetworkIps !== null && data.publicNetworkIps !== undefined) {
124
+ itemArr = [];
125
+ items = data.publicNetworkIps;
126
+ for (i = 0; i < items.length; i++) {
127
+ item = _IPAddress.default.constructFromObject(items[i], undefined);
128
+ itemArr.push(item);
129
+ }
130
+ obj.setPublicNetworkIps(itemArr);
131
+ }
132
+ if (data.hasOwnProperty('totalCapacityGiB') && data.totalCapacityGiB !== null && data.totalCapacityGiB !== undefined) {
133
+ obj.setTotalCapacityGiB(data['totalCapacityGiB']);
134
+ }
135
+ if (data.hasOwnProperty('state') && data.state !== null && data.state !== undefined) {
136
+ obj.setState(_State.default.constructFromObject(data['state']));
137
+ }
138
+ if (data.hasOwnProperty('certificateExtIds') && data.certificateExtIds !== null && data.certificateExtIds !== undefined) {
139
+ itemArr = [];
140
+ items = data.certificateExtIds;
141
+ for (i = 0; i < items.length; i++) {
142
+ itemArr.push(items[i]);
143
+ }
144
+ obj.setCertificateExtIds(itemArr);
145
+ }
146
+ if (!callFromChild) {
147
+ obj.$unknownFields = {
148
+ ...data.$unknownFields
149
+ };
150
+ for (const property in data) {
151
+ // Check if the `property` is not already present in `obj` keys, either in snake_case or camelCase,
152
+ // as the model's fields are generated in camelCase, but the server might return snake_case (e.g., due to standards like OIDC).
153
+ // Also, ensure the `property` does not start with '$' and end with 'ItemDiscriminator'.
154
+ // If all conditions are true, add the `property` from `data` to `obj.$unknownFields` as an unknown field.
155
+ if (!Object.keys(obj).includes(property) && !Object.keys(obj).includes(this.snakeToCamel(property)) && !(property[0] === "$" && property.endsWith("ItemDiscriminator"))) {
156
+ obj.$unknownFields[property] = data[property];
157
+ }
158
+ }
159
+ }
110
160
  }
161
+ return obj;
162
+ }
111
163
 
112
- /**
113
- * @param {Metadata} metadata
114
- */
115
- }, {
116
- key: "setMetadata",
117
- value: function setMetadata(metadata) {
118
- this.metadata = metadata;
119
- }
164
+ /**
165
+ * Converts a given snake_case string to camelCase.
166
+ * @param {string} snakeStr - The input string in snake_case format.
167
+ * @returns {string} - The converted string in camelCase format.
168
+ */
169
+ static snakeToCamel(snakeStr) {
170
+ return snakeStr.replace(/(_\w)/g, match => match[1].toUpperCase());
171
+ }
120
172
 
121
- /**
122
- * Returns The name of the Object store.
123
- * @return {string}
124
- */
125
- }, {
126
- key: "getName",
127
- value: function getName() {
128
- return this.name;
129
- }
173
+ /**
174
+ * @return {Metadata}
175
+ */
176
+ getMetadata() {
177
+ return this.metadata;
178
+ }
130
179
 
131
- /**
132
- * Sets The name of the Object store.
133
- * @param {string} name The name of the Object store.
134
- */
135
- }, {
136
- key: "setName",
137
- value: function setName(name) {
138
- this.name = name;
139
- }
180
+ /**
181
+ * @param {Metadata} metadata
182
+ */
183
+ setMetadata(metadata) {
184
+ this.metadata = metadata;
185
+ }
140
186
 
141
- /**
142
- * Returns The time when the Object store was created.
143
- * @return {Date}
144
- */
145
- }, {
146
- key: "getCreationTime",
147
- value: function getCreationTime() {
148
- return this.creationTime;
149
- }
187
+ /**
188
+ * Returns The name of the Object store.
189
+ * @return {string}
190
+ */
191
+ getName() {
192
+ return this.name;
193
+ }
150
194
 
151
- /**
152
- * Sets The time when the Object store was created.
153
- * @param {Date} creationTime The time when the Object store was created.
154
- */
155
- }, {
156
- key: "setCreationTime",
157
- value: function setCreationTime(creationTime) {
158
- this.creationTime = creationTime;
159
- }
195
+ /**
196
+ * Sets The name of the Object store.
197
+ * @param {string} name The name of the Object store.
198
+ */
199
+ setName(name) {
200
+ this.name = name;
201
+ }
160
202
 
161
- /**
162
- * Returns The time when the Object store was last updated.
163
- * @return {Date}
164
- */
165
- }, {
166
- key: "getLastUpdateTime",
167
- value: function getLastUpdateTime() {
168
- return this.lastUpdateTime;
169
- }
203
+ /**
204
+ * Returns The time when the Object store was created.
205
+ * @return {Date}
206
+ */
207
+ getCreationTime() {
208
+ return this.creationTime;
209
+ }
170
210
 
171
- /**
172
- * Sets The time when the Object store was last updated.
173
- * @param {Date} lastUpdateTime The time when the Object store was last updated.
174
- */
175
- }, {
176
- key: "setLastUpdateTime",
177
- value: function setLastUpdateTime(lastUpdateTime) {
178
- this.lastUpdateTime = lastUpdateTime;
179
- }
211
+ /**
212
+ * Sets The time when the Object store was created.
213
+ * @param {Date} creationTime The time when the Object store was created.
214
+ */
215
+ setCreationTime(creationTime) {
216
+ this.creationTime = creationTime;
217
+ }
180
218
 
181
- /**
182
- * Returns A brief description of the Object store.
183
- * @return {string}
184
- */
185
- }, {
186
- key: "getDescription",
187
- value: function getDescription() {
188
- return this.description;
189
- }
219
+ /**
220
+ * Returns The time when the Object store was last updated.
221
+ * @return {Date}
222
+ */
223
+ getLastUpdateTime() {
224
+ return this.lastUpdateTime;
225
+ }
190
226
 
191
- /**
192
- * Sets A brief description of the Object store.
193
- * @param {string} description A brief description of the Object store.
194
- */
195
- }, {
196
- key: "setDescription",
197
- value: function setDescription(description) {
198
- this.description = description;
199
- }
227
+ /**
228
+ * Sets The time when the Object store was last updated.
229
+ * @param {Date} lastUpdateTime The time when the Object store was last updated.
230
+ */
231
+ setLastUpdateTime(lastUpdateTime) {
232
+ this.lastUpdateTime = lastUpdateTime;
233
+ }
200
234
 
201
- /**
202
- * Returns Object store deployment version.
203
- * @return {string}
204
- */
205
- }, {
206
- key: "getDeploymentVersion",
207
- value: function getDeploymentVersion() {
208
- return this.deploymentVersion;
209
- }
235
+ /**
236
+ * Returns A brief description of the Object store.
237
+ * @return {string}
238
+ */
239
+ getDescription() {
240
+ return this.description;
241
+ }
210
242
 
211
- /**
212
- * Sets Object store deployment version.
213
- * @param {string} deploymentVersion Object store deployment version.
214
- */
215
- }, {
216
- key: "setDeploymentVersion",
217
- value: function setDeploymentVersion(deploymentVersion) {
218
- this.deploymentVersion = deploymentVersion;
219
- }
243
+ /**
244
+ * Sets A brief description of the Object store.
245
+ * @param {string} description A brief description of the Object store.
246
+ */
247
+ setDescription(description) {
248
+ this.description = description;
249
+ }
220
250
 
221
- /**
222
- * Returns The DNS domain/subdomain the Object store belongs to. All the Object stores under one Prism Central must have the same domain name. The domain name must consist of at least 2 parts separated by a '.'. Each part can contain upper and lower case letters, digits, hyphens, or underscores. Each part can be up to 63 characters long. The domain must begin and end with an alphanumeric character. For example - 'objects-0.pc_nutanix.com'.
223
- * @return {string}
224
- */
225
- }, {
226
- key: "getDomain",
227
- value: function getDomain() {
228
- return this.domain;
229
- }
251
+ /**
252
+ * Returns Object store deployment version.
253
+ * @return {string}
254
+ */
255
+ getDeploymentVersion() {
256
+ return this.deploymentVersion;
257
+ }
230
258
 
231
- /**
232
- * Sets The DNS domain/subdomain the Object store belongs to. All the Object stores under one Prism Central must have the same domain name. The domain name must consist of at least 2 parts separated by a '.'. Each part can contain upper and lower case letters, digits, hyphens, or underscores. Each part can be up to 63 characters long. The domain must begin and end with an alphanumeric character. For example - 'objects-0.pc_nutanix.com'.
233
- * @param {string} domain The DNS domain/subdomain the Object store belongs to. All the Object stores under one Prism Central must have the same domain name. The domain name must consist of at least 2 parts separated by a '.'. Each part can contain upper and lower case letters, digits, hyphens, or underscores. Each part can be up to 63 characters long. The domain must begin and end with an alphanumeric character. For example - 'objects-0.pc_nutanix.com'.
234
- */
235
- }, {
236
- key: "setDomain",
237
- value: function setDomain(domain) {
238
- this.domain = domain;
239
- }
259
+ /**
260
+ * Sets Object store deployment version.
261
+ * @param {string} deploymentVersion Object store deployment version.
262
+ */
263
+ setDeploymentVersion(deploymentVersion) {
264
+ this.deploymentVersion = deploymentVersion;
265
+ }
240
266
 
241
- /**
242
- * Returns The region in which the Object store is deployed.
243
- * @return {string}
244
- */
245
- }, {
246
- key: "getRegion",
247
- value: function getRegion() {
248
- return this.region;
249
- }
267
+ /**
268
+ * Returns The DNS domain/subdomain the Object store belongs to. All the Object stores under one Prism Central must have the same domain name. The domain name must consist of at least 2 parts separated by a '.'. Each part can contain upper and lower case letters, digits, hyphens, or underscores. Each part can be up to 63 characters long. The domain must begin and end with an alphanumeric character. For example - 'objects-0.pc_nutanix.com'.
269
+ * @return {string}
270
+ */
271
+ getDomain() {
272
+ return this.domain;
273
+ }
250
274
 
251
- /**
252
- * Sets The region in which the Object store is deployed.
253
- * @param {string} region The region in which the Object store is deployed.
254
- */
255
- }, {
256
- key: "setRegion",
257
- value: function setRegion(region) {
258
- this.region = region;
259
- }
275
+ /**
276
+ * Sets The DNS domain/subdomain the Object store belongs to. All the Object stores under one Prism Central must have the same domain name. The domain name must consist of at least 2 parts separated by a '.'. Each part can contain upper and lower case letters, digits, hyphens, or underscores. Each part can be up to 63 characters long. The domain must begin and end with an alphanumeric character. For example - 'objects-0.pc_nutanix.com'.
277
+ * @param {string} domain The DNS domain/subdomain the Object store belongs to. All the Object stores under one Prism Central must have the same domain name. The domain name must consist of at least 2 parts separated by a '.'. Each part can contain upper and lower case letters, digits, hyphens, or underscores. Each part can be up to 63 characters long. The domain must begin and end with an alphanumeric character. For example - 'objects-0.pc_nutanix.com'.
278
+ */
279
+ setDomain(domain) {
280
+ this.domain = domain;
281
+ }
260
282
 
261
- /**
262
- * Returns The number of worker nodes (VMs) to be created for the Object store. Each worker node requires 10 vCPUs and 32 GiB of memory.
263
- * minimum: 1
264
- * maximum: 1000
265
- * @return {Number}
266
- */
267
- }, {
268
- key: "getNumWorkerNodes",
269
- value: function getNumWorkerNodes() {
270
- return this.numWorkerNodes;
271
- }
283
+ /**
284
+ * Returns The region in which the Object store is deployed.
285
+ * @return {string}
286
+ */
287
+ getRegion() {
288
+ return this.region;
289
+ }
272
290
 
273
- /**
274
- * Sets The number of worker nodes (VMs) to be created for the Object store. Each worker node requires 10 vCPUs and 32 GiB of memory.
275
- * @param {Number} numWorkerNodes The number of worker nodes (VMs) to be created for the Object store. Each worker node requires 10 vCPUs and 32 GiB of memory.
276
- */
277
- }, {
278
- key: "setNumWorkerNodes",
279
- value: function setNumWorkerNodes(numWorkerNodes) {
280
- this.numWorkerNodes = numWorkerNodes;
281
- }
291
+ /**
292
+ * Sets The region in which the Object store is deployed.
293
+ * @param {string} region The region in which the Object store is deployed.
294
+ */
295
+ setRegion(region) {
296
+ this.region = region;
297
+ }
282
298
 
283
- /**
284
- * Returns UUID of the AHV or ESXi cluster.
285
- * @return {string}
286
- */
287
- }, {
288
- key: "getClusterExtId",
289
- value: function getClusterExtId() {
290
- return this.clusterExtId;
291
- }
299
+ /**
300
+ * Returns The number of worker nodes (VMs) to be created for the Object store. Each worker node requires 10 vCPUs and 32 GiB of memory.
301
+ * minimum: 1
302
+ * maximum: 1000
303
+ * @return {Number}
304
+ */
305
+ getNumWorkerNodes() {
306
+ return this.numWorkerNodes;
307
+ }
292
308
 
293
- /**
294
- * Sets UUID of the AHV or ESXi cluster.
295
- * @param {string} clusterExtId UUID of the AHV or ESXi cluster.
296
- */
297
- }, {
298
- key: "setClusterExtId",
299
- value: function setClusterExtId(clusterExtId) {
300
- this.clusterExtId = clusterExtId;
301
- }
309
+ /**
310
+ * Sets The number of worker nodes (VMs) to be created for the Object store. Each worker node requires 10 vCPUs and 32 GiB of memory.
311
+ * @param {Number} numWorkerNodes The number of worker nodes (VMs) to be created for the Object store. Each worker node requires 10 vCPUs and 32 GiB of memory.
312
+ */
313
+ setNumWorkerNodes(numWorkerNodes) {
314
+ this.numWorkerNodes = numWorkerNodes;
315
+ }
302
316
 
303
- /**
304
- * Returns Reference to the Storage Network of the Object store. This is the subnet UUID for an AHV cluster or the IPAM name for an ESXi cluster.
305
- * @return {string}
306
- */
307
- }, {
308
- key: "getStorageNetworkReference",
309
- value: function getStorageNetworkReference() {
310
- return this.storageNetworkReference;
311
- }
317
+ /**
318
+ * Returns UUID of the AHV or ESXi cluster.
319
+ * @return {string}
320
+ */
321
+ getClusterExtId() {
322
+ return this.clusterExtId;
323
+ }
312
324
 
313
- /**
314
- * Sets Reference to the Storage Network of the Object store. This is the subnet UUID for an AHV cluster or the IPAM name for an ESXi cluster.
315
- * @param {string} storageNetworkReference Reference to the Storage Network of the Object store. This is the subnet UUID for an AHV cluster or the IPAM name for an ESXi cluster.
316
- */
317
- }, {
318
- key: "setStorageNetworkReference",
319
- value: function setStorageNetworkReference(storageNetworkReference) {
320
- this.storageNetworkReference = storageNetworkReference;
321
- }
325
+ /**
326
+ * Sets UUID of the AHV or ESXi cluster.
327
+ * @param {string} clusterExtId UUID of the AHV or ESXi cluster.
328
+ */
329
+ setClusterExtId(clusterExtId) {
330
+ this.clusterExtId = clusterExtId;
331
+ }
322
332
 
323
- /**
324
- * @return {IPAddress}
325
- */
326
- }, {
327
- key: "getStorageNetworkVip",
328
- value: function getStorageNetworkVip() {
329
- return this.storageNetworkVip;
330
- }
333
+ /**
334
+ * Returns Reference to the Storage Network of the Object store. This is the subnet UUID for an AHV cluster or the IPAM name for an ESXi cluster.
335
+ * @return {string}
336
+ */
337
+ getStorageNetworkReference() {
338
+ return this.storageNetworkReference;
339
+ }
331
340
 
332
- /**
333
- * @param {IPAddress} storageNetworkVip
334
- */
335
- }, {
336
- key: "setStorageNetworkVip",
337
- value: function setStorageNetworkVip(storageNetworkVip) {
338
- this.storageNetworkVip = storageNetworkVip;
339
- }
341
+ /**
342
+ * Sets Reference to the Storage Network of the Object store. This is the subnet UUID for an AHV cluster or the IPAM name for an ESXi cluster.
343
+ * @param {string} storageNetworkReference Reference to the Storage Network of the Object store. This is the subnet UUID for an AHV cluster or the IPAM name for an ESXi cluster.
344
+ */
345
+ setStorageNetworkReference(storageNetworkReference) {
346
+ this.storageNetworkReference = storageNetworkReference;
347
+ }
340
348
 
341
- /**
342
- * @return {IPAddress}
343
- */
344
- }, {
345
- key: "getStorageNetworkDnsIp",
346
- value: function getStorageNetworkDnsIp() {
347
- return this.storageNetworkDnsIp;
348
- }
349
+ /**
350
+ * @return {IPAddress}
351
+ */
352
+ getStorageNetworkVip() {
353
+ return this.storageNetworkVip;
354
+ }
349
355
 
350
- /**
351
- * @param {IPAddress} storageNetworkDnsIp
352
- */
353
- }, {
354
- key: "setStorageNetworkDnsIp",
355
- value: function setStorageNetworkDnsIp(storageNetworkDnsIp) {
356
- this.storageNetworkDnsIp = storageNetworkDnsIp;
357
- }
356
+ /**
357
+ * @param {IPAddress} storageNetworkVip
358
+ */
359
+ setStorageNetworkVip(storageNetworkVip) {
360
+ this.storageNetworkVip = storageNetworkVip;
361
+ }
358
362
 
359
- /**
360
- * Returns Public network reference of the Object store. This is the subnet UUID for an AHV cluster or the IPAM name for an ESXi cluster.
361
- * @return {string}
362
- */
363
- }, {
364
- key: "getPublicNetworkReference",
365
- value: function getPublicNetworkReference() {
366
- return this.publicNetworkReference;
367
- }
363
+ /**
364
+ * @return {IPAddress}
365
+ */
366
+ getStorageNetworkDnsIp() {
367
+ return this.storageNetworkDnsIp;
368
+ }
368
369
 
369
- /**
370
- * Sets Public network reference of the Object store. This is the subnet UUID for an AHV cluster or the IPAM name for an ESXi cluster.
371
- * @param {string} publicNetworkReference Public network reference of the Object store. This is the subnet UUID for an AHV cluster or the IPAM name for an ESXi cluster.
372
- */
373
- }, {
374
- key: "setPublicNetworkReference",
375
- value: function setPublicNetworkReference(publicNetworkReference) {
376
- this.publicNetworkReference = publicNetworkReference;
377
- }
370
+ /**
371
+ * @param {IPAddress} storageNetworkDnsIp
372
+ */
373
+ setStorageNetworkDnsIp(storageNetworkDnsIp) {
374
+ this.storageNetworkDnsIp = storageNetworkDnsIp;
375
+ }
378
376
 
379
- /**
380
- * Returns A list of static IP addresses used as public IPs to access the Object store.
381
- * @return {IPAddress[]}
382
- */
383
- }, {
384
- key: "getPublicNetworkIps",
385
- value: function getPublicNetworkIps() {
386
- return this.publicNetworkIps;
387
- }
377
+ /**
378
+ * Returns Public network reference of the Object store. This is the subnet UUID for an AHV cluster or the IPAM name for an ESXi cluster.
379
+ * @return {string}
380
+ */
381
+ getPublicNetworkReference() {
382
+ return this.publicNetworkReference;
383
+ }
388
384
 
389
- /**
390
- * Sets A list of static IP addresses used as public IPs to access the Object store.
391
- * @param {IPAddress[]} publicNetworkIps A list of static IP addresses used as public IPs to access the Object store.
392
- */
393
- }, {
394
- key: "setPublicNetworkIps",
395
- value: function setPublicNetworkIps(publicNetworkIps) {
396
- this.publicNetworkIps = publicNetworkIps;
397
- }
385
+ /**
386
+ * Sets Public network reference of the Object store. This is the subnet UUID for an AHV cluster or the IPAM name for an ESXi cluster.
387
+ * @param {string} publicNetworkReference Public network reference of the Object store. This is the subnet UUID for an AHV cluster or the IPAM name for an ESXi cluster.
388
+ */
389
+ setPublicNetworkReference(publicNetworkReference) {
390
+ this.publicNetworkReference = publicNetworkReference;
391
+ }
398
392
 
399
- /**
400
- * Returns Size of the Object store in GiB.
401
- * minimum: 1
402
- * maximum: 178814713856
403
- * @return {Number}
404
- */
405
- }, {
406
- key: "getTotalCapacityGiB",
407
- value: function getTotalCapacityGiB() {
408
- return this.totalCapacityGiB;
409
- }
393
+ /**
394
+ * Returns A list of static IP addresses used as public IPs to access the Object store.
395
+ * @return {IPAddress[]}
396
+ */
397
+ getPublicNetworkIps() {
398
+ return this.publicNetworkIps;
399
+ }
410
400
 
411
- /**
412
- * Sets Size of the Object store in GiB.
413
- * @param {Number} totalCapacityGiB Size of the Object store in GiB.
414
- */
415
- }, {
416
- key: "setTotalCapacityGiB",
417
- value: function setTotalCapacityGiB(totalCapacityGiB) {
418
- this.totalCapacityGiB = totalCapacityGiB;
419
- }
401
+ /**
402
+ * Sets A list of static IP addresses used as public IPs to access the Object store.
403
+ * @param {IPAddress[]} publicNetworkIps A list of static IP addresses used as public IPs to access the Object store.
404
+ */
405
+ setPublicNetworkIps(publicNetworkIps) {
406
+ this.publicNetworkIps = publicNetworkIps;
407
+ }
420
408
 
421
- /**
422
- * @return {State}
423
- */
424
- }, {
425
- key: "getState",
426
- value: function getState() {
427
- return this.state;
428
- }
409
+ /**
410
+ * Returns Size of the Object store in GiB.
411
+ * minimum: 1
412
+ * maximum: 178814713856
413
+ * @return {Number}
414
+ */
415
+ getTotalCapacityGiB() {
416
+ return this.totalCapacityGiB;
417
+ }
429
418
 
430
- /**
431
- * @param {State} state
432
- */
433
- }, {
434
- key: "setState",
435
- value: function setState(state) {
436
- this.state = state;
437
- }
419
+ /**
420
+ * Sets Size of the Object store in GiB.
421
+ * @param {Number} totalCapacityGiB Size of the Object store in GiB.
422
+ */
423
+ setTotalCapacityGiB(totalCapacityGiB) {
424
+ this.totalCapacityGiB = totalCapacityGiB;
425
+ }
438
426
 
439
- /**
440
- * Returns A list of the UUIDs of the certificates of an Object store.
441
- * @return {string[]}
442
- */
443
- }, {
444
- key: "getCertificateExtIds",
445
- value: function getCertificateExtIds() {
446
- return this.certificateExtIds;
447
- }
427
+ /**
428
+ * @return {State}
429
+ */
430
+ getState() {
431
+ return this.state;
432
+ }
448
433
 
449
- /**
450
- * Sets A list of the UUIDs of the certificates of an Object store.
451
- * @param {string[]} certificateExtIds A list of the UUIDs of the certificates of an Object store.
452
- */
453
- }, {
454
- key: "setCertificateExtIds",
455
- value: function setCertificateExtIds(certificateExtIds) {
456
- this.certificateExtIds = certificateExtIds;
457
- }
458
- }, {
459
- key: "toJson",
460
- value: function toJson(forMutation) {
461
- if (forMutation === false) {
462
- return _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({}, typeof this.getMetadata() !== 'undefined' && this.getMetadata() !== null ? {
434
+ /**
435
+ * @param {State} state
436
+ */
437
+ setState(state) {
438
+ this.state = state;
439
+ }
440
+
441
+ /**
442
+ * Returns A list of the UUIDs of the certificates of an Object store.
443
+ * @return {string[]}
444
+ */
445
+ getCertificateExtIds() {
446
+ return this.certificateExtIds;
447
+ }
448
+
449
+ /**
450
+ * Sets A list of the UUIDs of the certificates of an Object store.
451
+ * @param {string[]} certificateExtIds A list of the UUIDs of the certificates of an Object store.
452
+ */
453
+ setCertificateExtIds(certificateExtIds) {
454
+ this.certificateExtIds = certificateExtIds;
455
+ }
456
+ toJson(forMutation) {
457
+ if (forMutation === false) {
458
+ return {
459
+ ...(typeof this.getMetadata() !== 'undefined' && this.getMetadata() !== null ? {
463
460
  'metadata': this.getMetadata().toJson(false)
464
- } : {}), typeof this.getName() !== 'undefined' && this.getName() !== null ? {
461
+ } : {}),
462
+ ...(typeof this.getName() !== 'undefined' && this.getName() !== null ? {
465
463
  'name': this.getName()
466
- } : {}), typeof this.getCreationTime() !== 'undefined' && this.getCreationTime() !== null ? {
464
+ } : {}),
465
+ ...(typeof this.getCreationTime() !== 'undefined' && this.getCreationTime() !== null ? {
467
466
  'creationTime': _assertClassBrand(_ObjectStore_brand, this, _handleDateType).call(this, this.getCreationTime(), false)
468
- } : {}), typeof this.getLastUpdateTime() !== 'undefined' && this.getLastUpdateTime() !== null ? {
467
+ } : {}),
468
+ ...(typeof this.getLastUpdateTime() !== 'undefined' && this.getLastUpdateTime() !== null ? {
469
469
  'lastUpdateTime': _assertClassBrand(_ObjectStore_brand, this, _handleDateType).call(this, this.getLastUpdateTime(), false)
470
- } : {}), typeof this.getDescription() !== 'undefined' && this.getDescription() !== null ? {
470
+ } : {}),
471
+ ...(typeof this.getDescription() !== 'undefined' && this.getDescription() !== null ? {
471
472
  'description': this.getDescription()
472
- } : {}), typeof this.getDeploymentVersion() !== 'undefined' && this.getDeploymentVersion() !== null ? {
473
+ } : {}),
474
+ ...(typeof this.getDeploymentVersion() !== 'undefined' && this.getDeploymentVersion() !== null ? {
473
475
  'deploymentVersion': this.getDeploymentVersion()
474
- } : {}), typeof this.getDomain() !== 'undefined' && this.getDomain() !== null ? {
476
+ } : {}),
477
+ ...(typeof this.getDomain() !== 'undefined' && this.getDomain() !== null ? {
475
478
  'domain': this.getDomain()
476
- } : {}), typeof this.getRegion() !== 'undefined' && this.getRegion() !== null ? {
479
+ } : {}),
480
+ ...(typeof this.getRegion() !== 'undefined' && this.getRegion() !== null ? {
477
481
  'region': this.getRegion()
478
- } : {}), typeof this.getNumWorkerNodes() !== 'undefined' && this.getNumWorkerNodes() !== null ? {
482
+ } : {}),
483
+ ...(typeof this.getNumWorkerNodes() !== 'undefined' && this.getNumWorkerNodes() !== null ? {
479
484
  'numWorkerNodes': this.getNumWorkerNodes()
480
- } : {}), typeof this.getClusterExtId() !== 'undefined' && this.getClusterExtId() !== null ? {
485
+ } : {}),
486
+ ...(typeof this.getClusterExtId() !== 'undefined' && this.getClusterExtId() !== null ? {
481
487
  'clusterExtId': this.getClusterExtId()
482
- } : {}), typeof this.getStorageNetworkReference() !== 'undefined' && this.getStorageNetworkReference() !== null ? {
488
+ } : {}),
489
+ ...(typeof this.getStorageNetworkReference() !== 'undefined' && this.getStorageNetworkReference() !== null ? {
483
490
  'storageNetworkReference': this.getStorageNetworkReference()
484
- } : {}), typeof this.getStorageNetworkVip() !== 'undefined' && this.getStorageNetworkVip() !== null ? {
491
+ } : {}),
492
+ ...(typeof this.getStorageNetworkVip() !== 'undefined' && this.getStorageNetworkVip() !== null ? {
485
493
  'storageNetworkVip': this.getStorageNetworkVip().toJson(false)
486
- } : {}), typeof this.getStorageNetworkDnsIp() !== 'undefined' && this.getStorageNetworkDnsIp() !== null ? {
494
+ } : {}),
495
+ ...(typeof this.getStorageNetworkDnsIp() !== 'undefined' && this.getStorageNetworkDnsIp() !== null ? {
487
496
  'storageNetworkDnsIp': this.getStorageNetworkDnsIp().toJson(false)
488
- } : {}), typeof this.getPublicNetworkReference() !== 'undefined' && this.getPublicNetworkReference() !== null ? {
497
+ } : {}),
498
+ ...(typeof this.getPublicNetworkReference() !== 'undefined' && this.getPublicNetworkReference() !== null ? {
489
499
  'publicNetworkReference': this.getPublicNetworkReference()
490
- } : {}), typeof this.getPublicNetworkIps() !== 'undefined' && this.getPublicNetworkIps() !== null ? {
491
- 'publicNetworkIps': this.getPublicNetworkIps().map(function (item) {
492
- return item.toJson(false);
493
- })
494
- } : {}), typeof this.getTotalCapacityGiB() !== 'undefined' && this.getTotalCapacityGiB() !== null ? {
500
+ } : {}),
501
+ ...(typeof this.getPublicNetworkIps() !== 'undefined' && this.getPublicNetworkIps() !== null ? {
502
+ 'publicNetworkIps': this.getPublicNetworkIps().map(item => item.toJson(false))
503
+ } : {}),
504
+ ...(typeof this.getTotalCapacityGiB() !== 'undefined' && this.getTotalCapacityGiB() !== null ? {
495
505
  'totalCapacityGiB': this.getTotalCapacityGiB()
496
- } : {}), typeof this.getState() !== 'undefined' && this.getState() !== null ? {
506
+ } : {}),
507
+ ...(typeof this.getState() !== 'undefined' && this.getState() !== null ? {
497
508
  'state': this.getState()
498
- } : {}), typeof this.getCertificateExtIds() !== 'undefined' && this.getCertificateExtIds() !== null ? {
509
+ } : {}),
510
+ ...(typeof this.getCertificateExtIds() !== 'undefined' && this.getCertificateExtIds() !== null ? {
499
511
  'certificateExtIds': this.getCertificateExtIds()
500
- } : {}), typeof this.getExtId() !== 'undefined' && this.getExtId() !== null ? {
512
+ } : {}),
513
+ ...(typeof this.getExtId() !== 'undefined' && this.getExtId() !== null ? {
501
514
  'extId': this.getExtId()
502
- } : {}), typeof this.getLinks() !== 'undefined' && this.getLinks() !== null ? {
503
- 'links': this.getLinks().map(function (item) {
504
- return item.toJson(false);
505
- })
506
- } : {}), typeof this.getTenantId() !== 'undefined' && this.getTenantId() !== null ? {
515
+ } : {}),
516
+ ...(typeof this.getLinks() !== 'undefined' && this.getLinks() !== null ? {
517
+ 'links': this.getLinks().map(item => item.toJson(false))
518
+ } : {}),
519
+ ...(typeof this.getTenantId() !== 'undefined' && this.getTenantId() !== null ? {
507
520
  'tenantId': this.getTenantId()
508
- } : {}), {}, {
509
- '$reserved': this.get$Reserved(),
510
- '$objectType': this.get$ObjectType(),
511
- '$unknownFields': this.get$UnknownFields()
512
- });
513
- }
514
- return _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({}, typeof this.getMetadata() !== 'undefined' && this.getMetadata() !== null ? {
521
+ } : {}),
522
+ '$reserved': this.get$Reserved(),
523
+ '$objectType': this.get$ObjectType(),
524
+ ...(typeof this.get$UnknownFields() !== 'undefined' && this.get$UnknownFields() !== null ? this.get$UnknownFields() : {}),
525
+ '$unknownFields': {}
526
+ };
527
+ }
528
+ return {
529
+ ...(typeof this.getMetadata() !== 'undefined' && this.getMetadata() !== null ? {
515
530
  'metadata': this.getMetadata().toJson(false)
516
- } : {}), typeof this.getName() !== 'undefined' && this.getName() !== null ? {
531
+ } : {}),
532
+ ...(typeof this.getName() !== 'undefined' && this.getName() !== null ? {
517
533
  'name': this.getName()
518
- } : {}), typeof this.getDescription() !== 'undefined' && this.getDescription() !== null ? {
534
+ } : {}),
535
+ ...(typeof this.getDescription() !== 'undefined' && this.getDescription() !== null ? {
519
536
  'description': this.getDescription()
520
- } : {}), typeof this.getDeploymentVersion() !== 'undefined' && this.getDeploymentVersion() !== null ? {
537
+ } : {}),
538
+ ...(typeof this.getDeploymentVersion() !== 'undefined' && this.getDeploymentVersion() !== null ? {
521
539
  'deploymentVersion': this.getDeploymentVersion()
522
- } : {}), typeof this.getDomain() !== 'undefined' && this.getDomain() !== null ? {
540
+ } : {}),
541
+ ...(typeof this.getDomain() !== 'undefined' && this.getDomain() !== null ? {
523
542
  'domain': this.getDomain()
524
- } : {}), typeof this.getRegion() !== 'undefined' && this.getRegion() !== null ? {
543
+ } : {}),
544
+ ...(typeof this.getRegion() !== 'undefined' && this.getRegion() !== null ? {
525
545
  'region': this.getRegion()
526
- } : {}), typeof this.getNumWorkerNodes() !== 'undefined' && this.getNumWorkerNodes() !== null ? {
546
+ } : {}),
547
+ ...(typeof this.getNumWorkerNodes() !== 'undefined' && this.getNumWorkerNodes() !== null ? {
527
548
  'numWorkerNodes': this.getNumWorkerNodes()
528
- } : {}), typeof this.getClusterExtId() !== 'undefined' && this.getClusterExtId() !== null ? {
549
+ } : {}),
550
+ ...(typeof this.getClusterExtId() !== 'undefined' && this.getClusterExtId() !== null ? {
529
551
  'clusterExtId': this.getClusterExtId()
530
- } : {}), typeof this.getStorageNetworkReference() !== 'undefined' && this.getStorageNetworkReference() !== null ? {
552
+ } : {}),
553
+ ...(typeof this.getStorageNetworkReference() !== 'undefined' && this.getStorageNetworkReference() !== null ? {
531
554
  'storageNetworkReference': this.getStorageNetworkReference()
532
- } : {}), typeof this.getStorageNetworkVip() !== 'undefined' && this.getStorageNetworkVip() !== null ? {
555
+ } : {}),
556
+ ...(typeof this.getStorageNetworkVip() !== 'undefined' && this.getStorageNetworkVip() !== null ? {
533
557
  'storageNetworkVip': this.getStorageNetworkVip().toJson(false)
534
- } : {}), typeof this.getStorageNetworkDnsIp() !== 'undefined' && this.getStorageNetworkDnsIp() !== null ? {
558
+ } : {}),
559
+ ...(typeof this.getStorageNetworkDnsIp() !== 'undefined' && this.getStorageNetworkDnsIp() !== null ? {
535
560
  'storageNetworkDnsIp': this.getStorageNetworkDnsIp().toJson(false)
536
- } : {}), typeof this.getPublicNetworkReference() !== 'undefined' && this.getPublicNetworkReference() !== null ? {
561
+ } : {}),
562
+ ...(typeof this.getPublicNetworkReference() !== 'undefined' && this.getPublicNetworkReference() !== null ? {
537
563
  'publicNetworkReference': this.getPublicNetworkReference()
538
- } : {}), typeof this.getPublicNetworkIps() !== 'undefined' && this.getPublicNetworkIps() !== null ? {
539
- 'publicNetworkIps': this.getPublicNetworkIps().map(function (item) {
540
- return item.toJson(false);
541
- })
542
- } : {}), typeof this.getTotalCapacityGiB() !== 'undefined' && this.getTotalCapacityGiB() !== null ? {
564
+ } : {}),
565
+ ...(typeof this.getPublicNetworkIps() !== 'undefined' && this.getPublicNetworkIps() !== null ? {
566
+ 'publicNetworkIps': this.getPublicNetworkIps().map(item => item.toJson(false))
567
+ } : {}),
568
+ ...(typeof this.getTotalCapacityGiB() !== 'undefined' && this.getTotalCapacityGiB() !== null ? {
543
569
  'totalCapacityGiB': this.getTotalCapacityGiB()
544
- } : {}), typeof this.getState() !== 'undefined' && this.getState() !== null ? {
570
+ } : {}),
571
+ ...(typeof this.getState() !== 'undefined' && this.getState() !== null ? {
545
572
  'state': this.getState()
546
- } : {}), {}, {
547
- '$reserved': this.get$Reserved(),
548
- '$objectType': this.get$ObjectType(),
549
- '$unknownFields': this.get$UnknownFields()
550
- });
551
- }
552
- }, {
553
- key: "validate",
554
- value: function validate(scope, properties) {
555
- var _this2 = this;
556
- var propList = [];
557
- if (arguments.length === 0 || arguments.length === 1 && arguments[0] instanceof _ValidationScopes["default"]) {
558
- //cases validate() and validate(scope)
559
- propList = ["name"];
560
- } else if (arguments.length === 1) {
561
- //case validate(properties)
562
- propList = arguments[0];
563
- scope = null;
573
+ } : {}),
574
+ '$reserved': this.get$Reserved(),
575
+ '$objectType': this.get$ObjectType(),
576
+ ...(typeof this.get$UnknownFields() !== 'undefined' && this.get$UnknownFields() !== null ? this.get$UnknownFields() : {}),
577
+ '$unknownFields': {}
578
+ };
579
+ }
580
+ validate(scope, properties) {
581
+ let propList = [];
582
+ if (arguments.length === 0 || arguments.length === 1 && arguments[0] instanceof _ValidationScopes.default) {
583
+ //cases validate() and validate(scope)
584
+ propList = ["name"];
585
+ } else if (arguments.length === 1) {
586
+ //case validate(properties)
587
+ propList = arguments[0];
588
+ scope = null;
589
+ } else {
590
+ //case validate(scope, properties)
591
+ propList = arguments[1];
592
+ }
593
+ let res = [];
594
+ let err = null;
595
+ propList.forEach(property => {
596
+ err = this.validateProperty(property, scope);
597
+ if (err) {
598
+ res.push(err);
599
+ }
600
+ });
601
+ return new Promise(function (resolve, reject) {
602
+ if (res.length !== 0) {
603
+ reject(err);
564
604
  } else {
565
- //case validate(scope, properties)
566
- propList = arguments[1];
567
- }
568
- var res = [];
569
- var err = null;
570
- propList.forEach(function (property) {
571
- err = _this2.validateProperty(property, scope);
572
- if (err) {
573
- res.push(err);
574
- }
575
- });
576
- return new Promise(function (resolve, reject) {
577
- if (res.length !== 0) {
578
- reject(err);
579
- } else {
580
- resolve();
581
- }
582
- });
605
+ resolve();
606
+ }
607
+ });
608
+ }
609
+ validateProperty(scope, property) {
610
+ if (property === "metadata") {
611
+ if (typeof this.metadata === 'undefined' || this.metadata === null) {
612
+ return new _ValidationError.default("metadata", "undefined or null");
613
+ }
583
614
  }
584
- }, {
585
- key: "validateProperty",
586
- value: function validateProperty(scope, property) {
587
- if (property === "metadata") {
588
- if (typeof this.metadata === 'undefined' || this.metadata === null) {
589
- return new _ValidationError["default"]("metadata", "undefined or null");
590
- }
615
+ if (property === "name") {
616
+ if (typeof this.name === 'undefined' || this.name === null) {
617
+ return new _ValidationError.default("name", "undefined or null");
591
618
  }
592
- if (property === "name") {
593
- if (typeof this.name === 'undefined' || this.name === null) {
594
- return new _ValidationError["default"]("name", "undefined or null");
595
- }
596
- if (!_ValidationUtils["default"].validateMaxLength(this.name, 50)) {
597
- return new _ValidationError["default"]("name", "does not satisfy required maxLength constraint: 50");
598
- }
599
- if (!_ValidationUtils["default"].validateMinLength(this.name, 1)) {
600
- return new _ValidationError["default"]("name", "does not satisfy required minLength constraint: 1");
601
- }
602
- if (!_ValidationUtils["default"].validatePattern(this.name, /^(([a-zA-Z]|[a-zA-Z][a-zA-Z0-9-]*[a-zA-Z0-9]))*([A-Za-z]|[A-Za-z][A-Za-z0-9-]*[A-Za-z0-9])$/)) {
603
- return new _ValidationError["default"]("name", "does not satisfy required pattern: /^(([a-zA-Z]|[a-zA-Z][a-zA-Z0-9-]*[a-zA-Z0-9]))*([A-Za-z]|[A-Za-z][A-Za-z0-9-]*[A-Za-z0-9])$/");
604
- }
619
+ if (!_ValidationUtils.default.validateMaxLength(this.name, 50)) {
620
+ return new _ValidationError.default("name", "does not satisfy required maxLength constraint: 50");
605
621
  }
606
- if (property === "creationTime") {
607
- if (typeof this.creationTime === 'undefined' || this.creationTime === null) {
608
- return new _ValidationError["default"]("creationTime", "undefined or null");
609
- }
622
+ if (!_ValidationUtils.default.validateMinLength(this.name, 1)) {
623
+ return new _ValidationError.default("name", "does not satisfy required minLength constraint: 1");
610
624
  }
611
- if (property === "lastUpdateTime") {
612
- if (typeof this.lastUpdateTime === 'undefined' || this.lastUpdateTime === null) {
613
- return new _ValidationError["default"]("lastUpdateTime", "undefined or null");
614
- }
625
+ if (!_ValidationUtils.default.validatePattern(this.name, /^(([a-zA-Z]|[a-zA-Z][a-zA-Z0-9-]*[a-zA-Z0-9]))*([A-Za-z]|[A-Za-z][A-Za-z0-9-]*[A-Za-z0-9])$/)) {
626
+ return new _ValidationError.default("name", "does not satisfy required pattern: /^(([a-zA-Z]|[a-zA-Z][a-zA-Z0-9-]*[a-zA-Z0-9]))*([A-Za-z]|[A-Za-z][A-Za-z0-9-]*[A-Za-z0-9])$/");
615
627
  }
616
- if (property === "description") {
617
- if (typeof this.description === 'undefined' || this.description === null) {
618
- return new _ValidationError["default"]("description", "undefined or null");
619
- }
620
- if (!_ValidationUtils["default"].validateMaxLength(this.description, 1000)) {
621
- return new _ValidationError["default"]("description", "does not satisfy required maxLength constraint: 1000");
622
- }
628
+ }
629
+ if (property === "creationTime") {
630
+ if (typeof this.creationTime === 'undefined' || this.creationTime === null) {
631
+ return new _ValidationError.default("creationTime", "undefined or null");
623
632
  }
624
- if (property === "deploymentVersion") {
625
- if (typeof this.deploymentVersion === 'undefined' || this.deploymentVersion === null) {
626
- return new _ValidationError["default"]("deploymentVersion", "undefined or null");
627
- }
628
- if (!_ValidationUtils["default"].validateMaxLength(this.deploymentVersion, 50)) {
629
- return new _ValidationError["default"]("deploymentVersion", "does not satisfy required maxLength constraint: 50");
630
- }
631
- if (!_ValidationUtils["default"].validateMinLength(this.deploymentVersion, 1)) {
632
- return new _ValidationError["default"]("deploymentVersion", "does not satisfy required minLength constraint: 1");
633
- }
634
- if (!_ValidationUtils["default"].validatePattern(this.deploymentVersion, /^[a-zA-z0-9][a-zA-z0-9\\.]*[a-zA-Z0-9]?$/)) {
635
- return new _ValidationError["default"]("deploymentVersion", "does not satisfy required pattern: /^[a-zA-z0-9][a-zA-z0-9\\.]*[a-zA-Z0-9]?$/");
636
- }
633
+ }
634
+ if (property === "lastUpdateTime") {
635
+ if (typeof this.lastUpdateTime === 'undefined' || this.lastUpdateTime === null) {
636
+ return new _ValidationError.default("lastUpdateTime", "undefined or null");
637
637
  }
638
- if (property === "domain") {
639
- if (typeof this.domain === 'undefined' || this.domain === null) {
640
- return new _ValidationError["default"]("domain", "undefined or null");
641
- }
642
- if (!_ValidationUtils["default"].validateMaxLength(this.domain, 1000)) {
643
- return new _ValidationError["default"]("domain", "does not satisfy required maxLength constraint: 1000");
644
- }
645
- if (!_ValidationUtils["default"].validateMinLength(this.domain, 1)) {
646
- return new _ValidationError["default"]("domain", "does not satisfy required minLength constraint: 1");
647
- }
648
- if (!_ValidationUtils["default"].validatePattern(this.domain, /^(([a-zA-Z0-9_\\-]{1,63})\\.)+([a-zA-Z0-9_\\-]{1,63})$/)) {
649
- return new _ValidationError["default"]("domain", "does not satisfy required pattern: /^(([a-zA-Z0-9_\\-]{1,63})\\.)+([a-zA-Z0-9_\\-]{1,63})$/");
650
- }
638
+ }
639
+ if (property === "description") {
640
+ if (typeof this.description === 'undefined' || this.description === null) {
641
+ return new _ValidationError.default("description", "undefined or null");
651
642
  }
652
- if (property === "region") {
653
- if (typeof this.region === 'undefined' || this.region === null) {
654
- return new _ValidationError["default"]("region", "undefined or null");
655
- }
656
- if (!_ValidationUtils["default"].validateMaxLength(this.region, 50)) {
657
- return new _ValidationError["default"]("region", "does not satisfy required maxLength constraint: 50");
658
- }
659
- if (!_ValidationUtils["default"].validateMinLength(this.region, 1)) {
660
- return new _ValidationError["default"]("region", "does not satisfy required minLength constraint: 1");
661
- }
662
- if (!_ValidationUtils["default"].validatePattern(this.region, /^[a-z]+\\-[a-z]+\\-[0-9]$/)) {
663
- return new _ValidationError["default"]("region", "does not satisfy required pattern: /^[a-z]+\\-[a-z]+\\-[0-9]$/");
664
- }
643
+ if (!_ValidationUtils.default.validateMaxLength(this.description, 1000)) {
644
+ return new _ValidationError.default("description", "does not satisfy required maxLength constraint: 1000");
665
645
  }
666
- if (property === "numWorkerNodes") {
667
- if (typeof this.numWorkerNodes === 'undefined' || this.numWorkerNodes === null) {
668
- return new _ValidationError["default"]("numWorkerNodes", "undefined or null");
669
- }
670
- if (!_ValidationUtils["default"].validateMaximum(this.numWorkerNodes, 1000)) {
671
- return new _ValidationError["default"]("numWorkerNodes", "does not satisfy required maximum constraint: 1000");
672
- }
673
- if (!_ValidationUtils["default"].validateMinimum(this.numWorkerNodes, 1)) {
674
- return new _ValidationError["default"]("numWorkerNodes", "does not satisfy required minimum constraint: 1");
675
- }
646
+ }
647
+ if (property === "deploymentVersion") {
648
+ if (typeof this.deploymentVersion === 'undefined' || this.deploymentVersion === null) {
649
+ return new _ValidationError.default("deploymentVersion", "undefined or null");
676
650
  }
677
- if (property === "clusterExtId") {
678
- if (typeof this.clusterExtId === 'undefined' || this.clusterExtId === null) {
679
- return new _ValidationError["default"]("clusterExtId", "undefined or null");
680
- }
681
- if (!_ValidationUtils["default"].validatePattern(this.clusterExtId, /^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)) {
682
- return new _ValidationError["default"]("clusterExtId", "does not satisfy required pattern: /^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/");
683
- }
651
+ if (!_ValidationUtils.default.validateMaxLength(this.deploymentVersion, 50)) {
652
+ return new _ValidationError.default("deploymentVersion", "does not satisfy required maxLength constraint: 50");
684
653
  }
685
- if (property === "storageNetworkReference") {
686
- if (typeof this.storageNetworkReference === 'undefined' || this.storageNetworkReference === null) {
687
- return new _ValidationError["default"]("storageNetworkReference", "undefined or null");
688
- }
689
- if (!_ValidationUtils["default"].validateMaxLength(this.storageNetworkReference, 1000)) {
690
- return new _ValidationError["default"]("storageNetworkReference", "does not satisfy required maxLength constraint: 1000");
691
- }
654
+ if (!_ValidationUtils.default.validateMinLength(this.deploymentVersion, 1)) {
655
+ return new _ValidationError.default("deploymentVersion", "does not satisfy required minLength constraint: 1");
692
656
  }
693
- if (property === "storageNetworkVip") {
694
- if (typeof this.storageNetworkVip === 'undefined' || this.storageNetworkVip === null) {
695
- return new _ValidationError["default"]("storageNetworkVip", "undefined or null");
696
- }
657
+ if (!_ValidationUtils.default.validatePattern(this.deploymentVersion, /^[a-zA-z0-9][a-zA-z0-9\\.]*[a-zA-Z0-9]?$/)) {
658
+ return new _ValidationError.default("deploymentVersion", "does not satisfy required pattern: /^[a-zA-z0-9][a-zA-z0-9\\.]*[a-zA-Z0-9]?$/");
697
659
  }
698
- if (property === "storageNetworkDnsIp") {
699
- if (typeof this.storageNetworkDnsIp === 'undefined' || this.storageNetworkDnsIp === null) {
700
- return new _ValidationError["default"]("storageNetworkDnsIp", "undefined or null");
701
- }
660
+ }
661
+ if (property === "domain") {
662
+ if (typeof this.domain === 'undefined' || this.domain === null) {
663
+ return new _ValidationError.default("domain", "undefined or null");
702
664
  }
703
- if (property === "publicNetworkReference") {
704
- if (typeof this.publicNetworkReference === 'undefined' || this.publicNetworkReference === null) {
705
- return new _ValidationError["default"]("publicNetworkReference", "undefined or null");
706
- }
707
- if (!_ValidationUtils["default"].validateMaxLength(this.publicNetworkReference, 1000)) {
708
- return new _ValidationError["default"]("publicNetworkReference", "does not satisfy required maxLength constraint: 1000");
709
- }
665
+ if (!_ValidationUtils.default.validateMaxLength(this.domain, 1000)) {
666
+ return new _ValidationError.default("domain", "does not satisfy required maxLength constraint: 1000");
710
667
  }
711
- if (property === "publicNetworkIps") {
712
- if (typeof this.publicNetworkIps === 'undefined' || this.publicNetworkIps === null) {
713
- return new _ValidationError["default"]("publicNetworkIps", "undefined or null");
714
- }
715
- if (!_ValidationUtils["default"].validateMaxItems(this.publicNetworkIps, 1000)) {
716
- return new _ValidationError["default"]("publicNetworkIps", "does not satisfy required maxItems constraint: 1000");
717
- }
718
- if (!_ValidationUtils["default"].validateMinItems(this.publicNetworkIps, 1)) {
719
- return new _ValidationError["default"]("publicNetworkIps", "does not satisfy required minItems constraint: 1");
720
- }
668
+ if (!_ValidationUtils.default.validateMinLength(this.domain, 1)) {
669
+ return new _ValidationError.default("domain", "does not satisfy required minLength constraint: 1");
721
670
  }
722
- if (property === "totalCapacityGiB") {
723
- if (typeof this.totalCapacityGiB === 'undefined' || this.totalCapacityGiB === null) {
724
- return new _ValidationError["default"]("totalCapacityGiB", "undefined or null");
725
- }
726
- if (!_ValidationUtils["default"].validateMaximum(this.totalCapacityGiB, 178814713856)) {
727
- return new _ValidationError["default"]("totalCapacityGiB", "does not satisfy required maximum constraint: 178814713856");
728
- }
729
- if (!_ValidationUtils["default"].validateMinimum(this.totalCapacityGiB, 1)) {
730
- return new _ValidationError["default"]("totalCapacityGiB", "does not satisfy required minimum constraint: 1");
731
- }
671
+ if (!_ValidationUtils.default.validatePattern(this.domain, /^(([a-zA-Z0-9_\\-]{1,63})\\.)+([a-zA-Z0-9_\\-]{1,63})$/)) {
672
+ return new _ValidationError.default("domain", "does not satisfy required pattern: /^(([a-zA-Z0-9_\\-]{1,63})\\.)+([a-zA-Z0-9_\\-]{1,63})$/");
732
673
  }
733
- if (property === "state") {
734
- if (typeof this.state === 'undefined' || this.state === null) {
735
- return new _ValidationError["default"]("state", "undefined or null");
736
- }
674
+ }
675
+ if (property === "region") {
676
+ if (typeof this.region === 'undefined' || this.region === null) {
677
+ return new _ValidationError.default("region", "undefined or null");
737
678
  }
738
- if (property === "certificateExtIds") {
739
- if (typeof this.certificateExtIds === 'undefined' || this.certificateExtIds === null) {
740
- return new _ValidationError["default"]("certificateExtIds", "undefined or null");
741
- }
742
- if (!_ValidationUtils["default"].validateMaxItems(this.certificateExtIds, 100)) {
743
- return new _ValidationError["default"]("certificateExtIds", "does not satisfy required maxItems constraint: 100");
744
- }
745
- if (!_ValidationUtils["default"].validateMinItems(this.certificateExtIds, 1)) {
746
- return new _ValidationError["default"]("certificateExtIds", "does not satisfy required minItems constraint: 1");
747
- }
679
+ if (!_ValidationUtils.default.validateMaxLength(this.region, 50)) {
680
+ return new _ValidationError.default("region", "does not satisfy required maxLength constraint: 50");
681
+ }
682
+ if (!_ValidationUtils.default.validateMinLength(this.region, 1)) {
683
+ return new _ValidationError.default("region", "does not satisfy required minLength constraint: 1");
684
+ }
685
+ if (!_ValidationUtils.default.validatePattern(this.region, /^[a-z]+\\-[a-z]+\\-[0-9]$/)) {
686
+ return new _ValidationError.default("region", "does not satisfy required pattern: /^[a-z]+\\-[a-z]+\\-[0-9]$/");
748
687
  }
749
- return new _ValidationError["default"](property, "no such property exists");
750
688
  }
751
- }], [{
752
- key: "constructFromObject",
753
- value: function constructFromObject(data) {
754
- var obj = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
755
- var callFromChild = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
756
- var items, item, i, itemArr, discriminator;
757
- if (data) {
758
- obj = obj || new ObjectStore();
759
- _ExternalizableAbstractModel["default"].constructFromObject(data, obj, true);
760
- if (data.hasOwnProperty('metadata') && data.metadata !== null && data.metadata !== undefined) {
761
- obj.setMetadata(_Metadata["default"].constructFromObject(data['metadata']));
762
- }
763
- if (data.hasOwnProperty('name') && data.name !== null && data.name !== undefined) {
764
- obj.setName(data['name']);
765
- }
766
- if (data.hasOwnProperty('creationTime') && data.creationTime !== null && data.creationTime !== undefined) {
767
- obj.setCreationTime(data['creationTime']);
768
- }
769
- if (data.hasOwnProperty('lastUpdateTime') && data.lastUpdateTime !== null && data.lastUpdateTime !== undefined) {
770
- obj.setLastUpdateTime(data['lastUpdateTime']);
771
- }
772
- if (data.hasOwnProperty('description') && data.description !== null && data.description !== undefined) {
773
- obj.setDescription(data['description']);
774
- }
775
- if (data.hasOwnProperty('deploymentVersion') && data.deploymentVersion !== null && data.deploymentVersion !== undefined) {
776
- obj.setDeploymentVersion(data['deploymentVersion']);
777
- }
778
- if (data.hasOwnProperty('domain') && data.domain !== null && data.domain !== undefined) {
779
- obj.setDomain(data['domain']);
780
- }
781
- if (data.hasOwnProperty('region') && data.region !== null && data.region !== undefined) {
782
- obj.setRegion(data['region']);
783
- }
784
- if (data.hasOwnProperty('numWorkerNodes') && data.numWorkerNodes !== null && data.numWorkerNodes !== undefined) {
785
- obj.setNumWorkerNodes(data['numWorkerNodes']);
786
- }
787
- if (data.hasOwnProperty('clusterExtId') && data.clusterExtId !== null && data.clusterExtId !== undefined) {
788
- obj.setClusterExtId(data['clusterExtId']);
789
- }
790
- if (data.hasOwnProperty('storageNetworkReference') && data.storageNetworkReference !== null && data.storageNetworkReference !== undefined) {
791
- obj.setStorageNetworkReference(data['storageNetworkReference']);
792
- }
793
- if (data.hasOwnProperty('storageNetworkVip') && data.storageNetworkVip !== null && data.storageNetworkVip !== undefined) {
794
- obj.setStorageNetworkVip(_IPAddress["default"].constructFromObject(data['storageNetworkVip']));
795
- }
796
- if (data.hasOwnProperty('storageNetworkDnsIp') && data.storageNetworkDnsIp !== null && data.storageNetworkDnsIp !== undefined) {
797
- obj.setStorageNetworkDnsIp(_IPAddress["default"].constructFromObject(data['storageNetworkDnsIp']));
798
- }
799
- if (data.hasOwnProperty('publicNetworkReference') && data.publicNetworkReference !== null && data.publicNetworkReference !== undefined) {
800
- obj.setPublicNetworkReference(data['publicNetworkReference']);
801
- }
802
- if (data.hasOwnProperty('publicNetworkIps') && data.publicNetworkIps !== null && data.publicNetworkIps !== undefined) {
803
- itemArr = [];
804
- items = data.publicNetworkIps;
805
- for (i = 0; i < items.length; i++) {
806
- item = _IPAddress["default"].constructFromObject(items[i], undefined);
807
- itemArr.push(item);
808
- }
809
- obj.setPublicNetworkIps(itemArr);
810
- }
811
- if (data.hasOwnProperty('totalCapacityGiB') && data.totalCapacityGiB !== null && data.totalCapacityGiB !== undefined) {
812
- obj.setTotalCapacityGiB(data['totalCapacityGiB']);
813
- }
814
- if (data.hasOwnProperty('state') && data.state !== null && data.state !== undefined) {
815
- obj.setState(_State["default"].constructFromObject(data['state']));
816
- }
817
- if (data.hasOwnProperty('certificateExtIds') && data.certificateExtIds !== null && data.certificateExtIds !== undefined) {
818
- itemArr = [];
819
- items = data.certificateExtIds;
820
- for (i = 0; i < items.length; i++) {
821
- itemArr.push(items[i]);
822
- }
823
- obj.setCertificateExtIds(itemArr);
824
- }
825
- if (!callFromChild) {
826
- obj.$unknownFields = _objectSpread({}, data.$unknownFields);
827
- for (var property in data) {
828
- // Check if the `property` is not already present in `obj` keys, either in snake_case or camelCase,
829
- // as the model's fields are generated in camelCase, but the server might return snake_case (e.g., due to standards like OIDC).
830
- // Also, ensure the `property` does not start with '$' and end with 'ItemDiscriminator'.
831
- // If all conditions are true, add the `property` from `data` to `obj.$unknownFields` as an unknown field.
832
- if (!Object.keys(obj).includes(property) && !Object.keys(obj).includes(this.snakeToCamel(property)) && !(property[0] === "$" && property.endsWith("ItemDiscriminator"))) {
833
- obj.$unknownFields[property] = data[property];
834
- }
835
- }
836
- }
689
+ if (property === "numWorkerNodes") {
690
+ if (typeof this.numWorkerNodes === 'undefined' || this.numWorkerNodes === null) {
691
+ return new _ValidationError.default("numWorkerNodes", "undefined or null");
692
+ }
693
+ if (!_ValidationUtils.default.validateMaximum(this.numWorkerNodes, 1000)) {
694
+ return new _ValidationError.default("numWorkerNodes", "does not satisfy required maximum constraint: 1000");
695
+ }
696
+ if (!_ValidationUtils.default.validateMinimum(this.numWorkerNodes, 1)) {
697
+ return new _ValidationError.default("numWorkerNodes", "does not satisfy required minimum constraint: 1");
837
698
  }
838
- return obj;
839
699
  }
840
-
841
- /**
842
- * Converts a given snake_case string to camelCase.
843
- * @param {string} snakeStr - The input string in snake_case format.
844
- * @returns {string} - The converted string in camelCase format.
845
- */
846
- }, {
847
- key: "snakeToCamel",
848
- value: function snakeToCamel(snakeStr) {
849
- return snakeStr.replace(/(_\w)/g, function (match) {
850
- return match[1].toUpperCase();
851
- });
700
+ if (property === "clusterExtId") {
701
+ if (typeof this.clusterExtId === 'undefined' || this.clusterExtId === null) {
702
+ return new _ValidationError.default("clusterExtId", "undefined or null");
703
+ }
704
+ if (!_ValidationUtils.default.validatePattern(this.clusterExtId, /^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)) {
705
+ return new _ValidationError.default("clusterExtId", "does not satisfy required pattern: /^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/");
706
+ }
707
+ }
708
+ if (property === "storageNetworkReference") {
709
+ if (typeof this.storageNetworkReference === 'undefined' || this.storageNetworkReference === null) {
710
+ return new _ValidationError.default("storageNetworkReference", "undefined or null");
711
+ }
712
+ if (!_ValidationUtils.default.validateMaxLength(this.storageNetworkReference, 1000)) {
713
+ return new _ValidationError.default("storageNetworkReference", "does not satisfy required maxLength constraint: 1000");
714
+ }
715
+ }
716
+ if (property === "storageNetworkVip") {
717
+ if (typeof this.storageNetworkVip === 'undefined' || this.storageNetworkVip === null) {
718
+ return new _ValidationError.default("storageNetworkVip", "undefined or null");
719
+ }
720
+ }
721
+ if (property === "storageNetworkDnsIp") {
722
+ if (typeof this.storageNetworkDnsIp === 'undefined' || this.storageNetworkDnsIp === null) {
723
+ return new _ValidationError.default("storageNetworkDnsIp", "undefined or null");
724
+ }
725
+ }
726
+ if (property === "publicNetworkReference") {
727
+ if (typeof this.publicNetworkReference === 'undefined' || this.publicNetworkReference === null) {
728
+ return new _ValidationError.default("publicNetworkReference", "undefined or null");
729
+ }
730
+ if (!_ValidationUtils.default.validateMaxLength(this.publicNetworkReference, 1000)) {
731
+ return new _ValidationError.default("publicNetworkReference", "does not satisfy required maxLength constraint: 1000");
732
+ }
852
733
  }
853
- }]);
854
- }(_ExternalizableAbstractModel["default"]);
734
+ if (property === "publicNetworkIps") {
735
+ if (typeof this.publicNetworkIps === 'undefined' || this.publicNetworkIps === null) {
736
+ return new _ValidationError.default("publicNetworkIps", "undefined or null");
737
+ }
738
+ if (!_ValidationUtils.default.validateMaxItems(this.publicNetworkIps, 1000)) {
739
+ return new _ValidationError.default("publicNetworkIps", "does not satisfy required maxItems constraint: 1000");
740
+ }
741
+ if (!_ValidationUtils.default.validateMinItems(this.publicNetworkIps, 1)) {
742
+ return new _ValidationError.default("publicNetworkIps", "does not satisfy required minItems constraint: 1");
743
+ }
744
+ }
745
+ if (property === "totalCapacityGiB") {
746
+ if (typeof this.totalCapacityGiB === 'undefined' || this.totalCapacityGiB === null) {
747
+ return new _ValidationError.default("totalCapacityGiB", "undefined or null");
748
+ }
749
+ if (!_ValidationUtils.default.validateMaximum(this.totalCapacityGiB, 178814713856)) {
750
+ return new _ValidationError.default("totalCapacityGiB", "does not satisfy required maximum constraint: 178814713856");
751
+ }
752
+ if (!_ValidationUtils.default.validateMinimum(this.totalCapacityGiB, 1)) {
753
+ return new _ValidationError.default("totalCapacityGiB", "does not satisfy required minimum constraint: 1");
754
+ }
755
+ }
756
+ if (property === "state") {
757
+ if (typeof this.state === 'undefined' || this.state === null) {
758
+ return new _ValidationError.default("state", "undefined or null");
759
+ }
760
+ }
761
+ if (property === "certificateExtIds") {
762
+ if (typeof this.certificateExtIds === 'undefined' || this.certificateExtIds === null) {
763
+ return new _ValidationError.default("certificateExtIds", "undefined or null");
764
+ }
765
+ if (!_ValidationUtils.default.validateMaxItems(this.certificateExtIds, 100)) {
766
+ return new _ValidationError.default("certificateExtIds", "does not satisfy required maxItems constraint: 100");
767
+ }
768
+ if (!_ValidationUtils.default.validateMinItems(this.certificateExtIds, 1)) {
769
+ return new _ValidationError.default("certificateExtIds", "does not satisfy required minItems constraint: 1");
770
+ }
771
+ }
772
+ return new _ValidationError.default(property, "no such property exists");
773
+ }
774
+ }
775
+
855
776
  /**
856
777
  * @memberof ObjectStore
857
778
  */
779
+ exports.default = ObjectStore;
858
780
  function _toJsonMapType(obj, forMutation) {
859
781
  if (obj instanceof Map) {
860
- return Object.fromEntries(Array.from(obj, function (_ref) {
861
- var _ref2 = _slicedToArray(_ref, 2),
862
- k = _ref2[0],
863
- v = _ref2[1];
864
- return [k, typeof v.toJson !== "undefined" ? v.toJson(forMutation) : v];
865
- }));
866
- } else if (_typeof(obj) === 'object' && obj != null && obj.constructor === Object) {
867
- return Object.fromEntries(Array.from(Object.entries(obj), function (entry) {
782
+ return Object.fromEntries(Array.from(obj, ([k, v]) => [k, typeof v.toJson !== "undefined" ? v.toJson(forMutation) : v]));
783
+ } else if (typeof obj === 'object' && obj != null && obj.constructor === Object) {
784
+ return Object.fromEntries(Array.from(Object.entries(obj), entry => {
868
785
  return [entry[0], typeof entry[1].toJson !== "undefined" ? entry[1].toJson(forMutation) : entry[1]];
869
786
  }));
870
787
  }
@@ -987,15 +904,15 @@ ObjectStore.prototype.certificateExtIds = undefined;
987
904
  * A globally unique identifier of an instance that is suitable for external consumption.
988
905
  * @memberof ObjectStore
989
906
  */
990
- _ExternalizableAbstractModel["default"].prototype.extId = undefined;
907
+ _ExternalizableAbstractModel.default.prototype.extId = undefined;
991
908
  /**
992
909
  * A HATEOAS style link for the response. Each link contains a user-friendly name identifying the link and an address for retrieving the particular resource.
993
910
  * @memberof ObjectStore
994
911
  */
995
- _ExternalizableAbstractModel["default"].prototype.links = undefined;
912
+ _ExternalizableAbstractModel.default.prototype.links = undefined;
996
913
  /**
997
- * A globally unique identifier that represents the tenant that owns this entity. The system automatically assigns it, and it and is immutable from an API consumer perspective (some use cases may cause this Id to change - For instance, a use case may require the transfer of ownership of the entity, but these cases are handled automatically on the server).
914
+ * A globally unique identifier that represents the tenant that owns this entity. The system automatically assigns it, and it and is immutable from an API consumer perspective (some use cases may cause this ID to change - For instance, a use case may require the transfer of ownership of the entity, but these cases are handled automatically on the server).
998
915
  * @memberof ObjectStore
999
916
  */
1000
- _TenantAwareModel["default"].prototype.tenantId = undefined;
917
+ _TenantAwareModel.default.prototype.tenantId = undefined;
1001
918
  // Implement OneOfobjects.v4.config.GetObjectstoreApiResponsedata interface: