@nutanix-scratch/objects-js-client 4.0.1-alpha.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 (145) hide show
  1. package/LICENSE.txt +49 -0
  2. package/README.md +200 -0
  3. package/dist/Ntnx-Objects-js-client-prod.js +1 -0
  4. package/dist/Ntnx-Objects-js-client.js +729 -0
  5. package/dist/es/ApiClient.d.ts +159 -0
  6. package/dist/es/ApiClient.js +1211 -0
  7. package/dist/es/Paginable.d.ts +95 -0
  8. package/dist/es/Paginable.js +287 -0
  9. package/dist/es/apis/objectstores-endpoints.d.ts +231 -0
  10. package/dist/es/apis/objectstores-endpoints.js +522 -0
  11. package/dist/es/index.d.ts +64 -0
  12. package/dist/es/index.js +252 -0
  13. package/dist/es/models/common/v1/config/FQDN.d.ts +48 -0
  14. package/dist/es/models/common/v1/config/FQDN.js +242 -0
  15. package/dist/es/models/common/v1/config/Flag.d.ts +58 -0
  16. package/dist/es/models/common/v1/config/Flag.js +275 -0
  17. package/dist/es/models/common/v1/config/IPAddress.d.ts +61 -0
  18. package/dist/es/models/common/v1/config/IPAddress.js +291 -0
  19. package/dist/es/models/common/v1/config/IPv4Address.d.ts +62 -0
  20. package/dist/es/models/common/v1/config/IPv4Address.js +288 -0
  21. package/dist/es/models/common/v1/config/IPv6Address.d.ts +62 -0
  22. package/dist/es/models/common/v1/config/IPv6Address.js +288 -0
  23. package/dist/es/models/common/v1/config/KVPair.d.ts +62 -0
  24. package/dist/es/models/common/v1/config/KVPair.js +332 -0
  25. package/dist/es/models/common/v1/config/Message.d.ts +84 -0
  26. package/dist/es/models/common/v1/config/Message.js +354 -0
  27. package/dist/es/models/common/v1/config/MessageSeverity.d.ts +19 -0
  28. package/dist/es/models/common/v1/config/MessageSeverity.js +91 -0
  29. package/dist/es/models/common/v1/config/Metadata.d.ts +98 -0
  30. package/dist/es/models/common/v1/config/Metadata.js +411 -0
  31. package/dist/es/models/common/v1/config/TenantAwareModel.d.ts +50 -0
  32. package/dist/es/models/common/v1/config/TenantAwareModel.js +243 -0
  33. package/dist/es/models/common/v1/response/ApiLink.d.ts +62 -0
  34. package/dist/es/models/common/v1/response/ApiLink.js +280 -0
  35. package/dist/es/models/common/v1/response/ApiResponseMetadata.d.ts +98 -0
  36. package/dist/es/models/common/v1/response/ApiResponseMetadata.js +438 -0
  37. package/dist/es/models/common/v1/response/ExternalizableAbstractModel.d.ts +42 -0
  38. package/dist/es/models/common/v1/response/ExternalizableAbstractModel.js +270 -0
  39. package/dist/es/models/objects/v4/error/AppMessage.d.ts +108 -0
  40. package/dist/es/models/objects/v4/error/AppMessage.js +432 -0
  41. package/dist/es/models/objects/v4/error/ErrorResponse.d.ts +48 -0
  42. package/dist/es/models/objects/v4/error/ErrorResponse.js +288 -0
  43. package/dist/es/models/objects/v4/error/SchemaValidationError.d.ts +98 -0
  44. package/dist/es/models/objects/v4/error/SchemaValidationError.js +407 -0
  45. package/dist/es/models/objects/v4/error/SchemaValidationErrorMessage.d.ts +74 -0
  46. package/dist/es/models/objects/v4/error/SchemaValidationErrorMessage.js +318 -0
  47. package/dist/es/models/objects/v4/operations/Certificate.d.ts +78 -0
  48. package/dist/es/models/objects/v4/operations/Certificate.js +411 -0
  49. package/dist/es/models/objects/v4/operations/CertificateApiResponse.d.ts +59 -0
  50. package/dist/es/models/objects/v4/operations/CertificateApiResponse.js +311 -0
  51. package/dist/es/models/objects/v4/operations/CertificateListApiResponse.d.ts +59 -0
  52. package/dist/es/models/objects/v4/operations/CertificateListApiResponse.js +338 -0
  53. package/dist/es/models/objects/v4/operations/CertificateProjection.d.ts +9 -0
  54. package/dist/es/models/objects/v4/operations/CertificateProjection.js +131 -0
  55. package/dist/es/models/objects/v4/operations/Objectstore.d.ts +242 -0
  56. package/dist/es/models/objects/v4/operations/Objectstore.js +945 -0
  57. package/dist/es/models/objects/v4/operations/ObjectstoreApiResponse.d.ts +59 -0
  58. package/dist/es/models/objects/v4/operations/ObjectstoreApiResponse.js +311 -0
  59. package/dist/es/models/objects/v4/operations/ObjectstoreListApiResponse.d.ts +59 -0
  60. package/dist/es/models/objects/v4/operations/ObjectstoreListApiResponse.js +338 -0
  61. package/dist/es/models/objects/v4/operations/ObjectstoreProjection.d.ts +50 -0
  62. package/dist/es/models/objects/v4/operations/ObjectstoreProjection.js +298 -0
  63. package/dist/es/models/objects/v4/operations/StateEnum.d.ts +19 -0
  64. package/dist/es/models/objects/v4/operations/StateEnum.js +145 -0
  65. package/dist/es/models/objects/v4/operations/TaskReferenceApiResponse.d.ts +59 -0
  66. package/dist/es/models/objects/v4/operations/TaskReferenceApiResponse.js +311 -0
  67. package/dist/es/models/prism/v4/config/TaskReference.d.ts +50 -0
  68. package/dist/es/models/prism/v4/config/TaskReference.js +247 -0
  69. package/dist/es/models/validation/ValidationError.d.ts +13 -0
  70. package/dist/es/models/validation/ValidationError.js +60 -0
  71. package/dist/es/models/validation/ValidationScopes.d.ts +9 -0
  72. package/dist/es/models/validation/ValidationScopes.js +38 -0
  73. package/dist/es/utils/ValidationUtils.d.ts +13 -0
  74. package/dist/es/utils/ValidationUtils.js +85 -0
  75. package/dist/lib/ApiClient.d.ts +159 -0
  76. package/dist/lib/ApiClient.js +1211 -0
  77. package/dist/lib/Paginable.d.ts +95 -0
  78. package/dist/lib/Paginable.js +287 -0
  79. package/dist/lib/apis/objectstores-endpoints.d.ts +231 -0
  80. package/dist/lib/apis/objectstores-endpoints.js +522 -0
  81. package/dist/lib/index.d.ts +64 -0
  82. package/dist/lib/index.js +252 -0
  83. package/dist/lib/models/common/v1/config/FQDN.d.ts +48 -0
  84. package/dist/lib/models/common/v1/config/FQDN.js +242 -0
  85. package/dist/lib/models/common/v1/config/Flag.d.ts +58 -0
  86. package/dist/lib/models/common/v1/config/Flag.js +275 -0
  87. package/dist/lib/models/common/v1/config/IPAddress.d.ts +61 -0
  88. package/dist/lib/models/common/v1/config/IPAddress.js +291 -0
  89. package/dist/lib/models/common/v1/config/IPv4Address.d.ts +62 -0
  90. package/dist/lib/models/common/v1/config/IPv4Address.js +288 -0
  91. package/dist/lib/models/common/v1/config/IPv6Address.d.ts +62 -0
  92. package/dist/lib/models/common/v1/config/IPv6Address.js +288 -0
  93. package/dist/lib/models/common/v1/config/KVPair.d.ts +62 -0
  94. package/dist/lib/models/common/v1/config/KVPair.js +332 -0
  95. package/dist/lib/models/common/v1/config/Message.d.ts +84 -0
  96. package/dist/lib/models/common/v1/config/Message.js +354 -0
  97. package/dist/lib/models/common/v1/config/MessageSeverity.d.ts +19 -0
  98. package/dist/lib/models/common/v1/config/MessageSeverity.js +91 -0
  99. package/dist/lib/models/common/v1/config/Metadata.d.ts +98 -0
  100. package/dist/lib/models/common/v1/config/Metadata.js +411 -0
  101. package/dist/lib/models/common/v1/config/TenantAwareModel.d.ts +50 -0
  102. package/dist/lib/models/common/v1/config/TenantAwareModel.js +243 -0
  103. package/dist/lib/models/common/v1/response/ApiLink.d.ts +62 -0
  104. package/dist/lib/models/common/v1/response/ApiLink.js +280 -0
  105. package/dist/lib/models/common/v1/response/ApiResponseMetadata.d.ts +98 -0
  106. package/dist/lib/models/common/v1/response/ApiResponseMetadata.js +438 -0
  107. package/dist/lib/models/common/v1/response/ExternalizableAbstractModel.d.ts +42 -0
  108. package/dist/lib/models/common/v1/response/ExternalizableAbstractModel.js +270 -0
  109. package/dist/lib/models/objects/v4/error/AppMessage.d.ts +108 -0
  110. package/dist/lib/models/objects/v4/error/AppMessage.js +432 -0
  111. package/dist/lib/models/objects/v4/error/ErrorResponse.d.ts +48 -0
  112. package/dist/lib/models/objects/v4/error/ErrorResponse.js +288 -0
  113. package/dist/lib/models/objects/v4/error/SchemaValidationError.d.ts +98 -0
  114. package/dist/lib/models/objects/v4/error/SchemaValidationError.js +407 -0
  115. package/dist/lib/models/objects/v4/error/SchemaValidationErrorMessage.d.ts +74 -0
  116. package/dist/lib/models/objects/v4/error/SchemaValidationErrorMessage.js +318 -0
  117. package/dist/lib/models/objects/v4/operations/Certificate.d.ts +78 -0
  118. package/dist/lib/models/objects/v4/operations/Certificate.js +411 -0
  119. package/dist/lib/models/objects/v4/operations/CertificateApiResponse.d.ts +59 -0
  120. package/dist/lib/models/objects/v4/operations/CertificateApiResponse.js +311 -0
  121. package/dist/lib/models/objects/v4/operations/CertificateListApiResponse.d.ts +59 -0
  122. package/dist/lib/models/objects/v4/operations/CertificateListApiResponse.js +338 -0
  123. package/dist/lib/models/objects/v4/operations/CertificateProjection.d.ts +9 -0
  124. package/dist/lib/models/objects/v4/operations/CertificateProjection.js +131 -0
  125. package/dist/lib/models/objects/v4/operations/Objectstore.d.ts +242 -0
  126. package/dist/lib/models/objects/v4/operations/Objectstore.js +945 -0
  127. package/dist/lib/models/objects/v4/operations/ObjectstoreApiResponse.d.ts +59 -0
  128. package/dist/lib/models/objects/v4/operations/ObjectstoreApiResponse.js +311 -0
  129. package/dist/lib/models/objects/v4/operations/ObjectstoreListApiResponse.d.ts +59 -0
  130. package/dist/lib/models/objects/v4/operations/ObjectstoreListApiResponse.js +338 -0
  131. package/dist/lib/models/objects/v4/operations/ObjectstoreProjection.d.ts +50 -0
  132. package/dist/lib/models/objects/v4/operations/ObjectstoreProjection.js +298 -0
  133. package/dist/lib/models/objects/v4/operations/StateEnum.d.ts +19 -0
  134. package/dist/lib/models/objects/v4/operations/StateEnum.js +145 -0
  135. package/dist/lib/models/objects/v4/operations/TaskReferenceApiResponse.d.ts +59 -0
  136. package/dist/lib/models/objects/v4/operations/TaskReferenceApiResponse.js +311 -0
  137. package/dist/lib/models/prism/v4/config/TaskReference.d.ts +50 -0
  138. package/dist/lib/models/prism/v4/config/TaskReference.js +247 -0
  139. package/dist/lib/models/validation/ValidationError.d.ts +13 -0
  140. package/dist/lib/models/validation/ValidationError.js +60 -0
  141. package/dist/lib/models/validation/ValidationScopes.d.ts +9 -0
  142. package/dist/lib/models/validation/ValidationScopes.js +38 -0
  143. package/dist/lib/utils/ValidationUtils.d.ts +13 -0
  144. package/dist/lib/utils/ValidationUtils.js +85 -0
  145. package/package.json +53 -0
@@ -0,0 +1,411 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+ var _FQDN = _interopRequireDefault(require("../../../common/v1/config/FQDN"));
8
+ var _Metadata = _interopRequireDefault(require("../../../common/v1/config/Metadata"));
9
+ var _ApiLink = _interopRequireDefault(require("../../../common/v1/response/ApiLink"));
10
+ var _ExternalizableAbstractModel = _interopRequireDefault(require("../../../common/v1/response/ExternalizableAbstractModel"));
11
+ var _ValidationScopes = _interopRequireDefault(require("../../../validation/ValidationScopes"));
12
+ var _ValidationUtils = _interopRequireDefault(require("../../../../utils/ValidationUtils"));
13
+ var _ValidationError = _interopRequireDefault(require("../../../validation/ValidationError"));
14
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
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(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _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(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
19
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
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(arr) { if (Array.isArray(arr)) return arr; }
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(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
25
+ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
26
+ function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
27
+ function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
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); }
30
+ function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
31
+ function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
32
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
33
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
34
+ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
35
+ function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
36
+ function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
37
+ function _classPrivateMethodInitSpec(obj, privateSet) { _checkPrivateRedeclaration(obj, privateSet); privateSet.add(obj); }
38
+ function _checkPrivateRedeclaration(obj, privateCollection) { if (privateCollection.has(obj)) { throw new TypeError("Cannot initialize the same private elements twice on an object"); } } /*
39
+ * Nutanix Objects Storage Management APIs
40
+ *
41
+ * OpenAPI spec version: 4.0.1-alpha-2
42
+ *
43
+ * NOTE: This class is auto generated by the Open API Dev Platform.
44
+ *
45
+ * Open API Dev Platform Codegen version: 16.8.0.7344-RELEASE
46
+ *
47
+ * Do not edit the class manually.
48
+ *
49
+ */
50
+ /**
51
+ * The Certificate model module.
52
+ * @module Ntnx/Certificate
53
+ * @version 4.0.1-alpha-2
54
+ * @class Certificate
55
+ */
56
+ var _Certificate_brand = /*#__PURE__*/new WeakSet();
57
+ var Certificate = exports["default"] = /*#__PURE__*/function (_ExternalizableAbstra) {
58
+ /**
59
+ * Constructs a new <code>Certificate</code>.
60
+ * @alias module:Ntnx/Certificate
61
+ * @extends module:Ntnx/ExternalizableAbstractModel
62
+ */
63
+ function Certificate() {
64
+ var _this;
65
+ _classCallCheck(this, Certificate);
66
+ _this = _callSuper(this, Certificate);
67
+ /*
68
+ * toJson method for a map type which supports map with primitive keys and values of object types
69
+ * @param {Object} obj
70
+ * @returns {Object|Map} Returns a new transofrmed Map by calling toJson on the values if applicable.
71
+ * Otherwise, just returns the input object.
72
+ */
73
+ _classPrivateMethodInitSpec(_this, _Certificate_brand);
74
+ _this.$objectType = "objects.v4.operations.Certificate";
75
+ _this.$reserved = {
76
+ '$fv': "v4.r0.a2"
77
+ };
78
+ _this.$unknownFields = {};
79
+ return _this;
80
+ }
81
+
82
+ /**
83
+ * Constructs a <code>Certificate</code> from a plain JavaScript object, optionally creating a new instance.
84
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
85
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
86
+ * @param {module:Ntnx/Certificate} obj Optional instance to populate.
87
+ * @param callFromChild {Boolean} Flag to recognise calling instance
88
+ * @return {module:Ntnx/Certificate} The populated <code>Certificate</code> instance.
89
+ */
90
+ _inherits(Certificate, _ExternalizableAbstra);
91
+ return _createClass(Certificate, [{
92
+ key: "getMetadata",
93
+ value:
94
+ /**
95
+ * @return {}
96
+ */
97
+ function getMetadata() {
98
+ return this.metadata;
99
+ }
100
+
101
+ /**
102
+ * @param {} metadata
103
+ */
104
+ }, {
105
+ key: "setMetadata",
106
+ value: function setMetadata(metadata) {
107
+ this.metadata = metadata;
108
+ }
109
+
110
+ /**
111
+ * Returns The public certificate to upload.
112
+ * @return {}
113
+ */
114
+ }, {
115
+ key: "getPublicCert",
116
+ value: function getPublicCert() {
117
+ return this.publicCert;
118
+ }
119
+
120
+ /**
121
+ * Sets The public certificate to upload.
122
+ * @param {} publicCert The public certificate to upload.
123
+ */
124
+ }, {
125
+ key: "setPublicCert",
126
+ value: function setPublicCert(publicCert) {
127
+ this.publicCert = publicCert;
128
+ }
129
+
130
+ /**
131
+ * Returns The private key to upload.
132
+ * @return {}
133
+ */
134
+ }, {
135
+ key: "getPrivateKey",
136
+ value: function getPrivateKey() {
137
+ return this.privateKey;
138
+ }
139
+
140
+ /**
141
+ * Sets The private key to upload.
142
+ * @param {} privateKey The private key to upload.
143
+ */
144
+ }, {
145
+ key: "setPrivateKey",
146
+ value: function setPrivateKey(privateKey) {
147
+ this.privateKey = privateKey;
148
+ }
149
+
150
+ /**
151
+ * Returns CA file to upload.
152
+ * @return {}
153
+ */
154
+ }, {
155
+ key: "getCa",
156
+ value: function getCa() {
157
+ return this.ca;
158
+ }
159
+
160
+ /**
161
+ * Sets CA file to upload.
162
+ * @param {} ca CA file to upload.
163
+ */
164
+ }, {
165
+ key: "setCa",
166
+ value: function setCa(ca) {
167
+ this.ca = ca;
168
+ }
169
+
170
+ /**
171
+ * Returns The list of alternate FQDNs for accessing the Object store. The FQDNs must consist of at least 2 parts separated by a '.'. Each part can contain upper and lower case letters, digits, hyphens or underscores but must begin and end with a letter. Each part can be up to 63 characters long. For e.g 'objects-0.pc_nutanix.com'.
172
+ * @return {}
173
+ */
174
+ }, {
175
+ key: "getAlternateFqdns",
176
+ value: function getAlternateFqdns() {
177
+ return this.alternateFqdns;
178
+ }
179
+
180
+ /**
181
+ * Sets The list of alternate FQDNs for accessing the Object store. The FQDNs must consist of at least 2 parts separated by a '.'. Each part can contain upper and lower case letters, digits, hyphens or underscores but must begin and end with a letter. Each part can be up to 63 characters long. For e.g 'objects-0.pc_nutanix.com'.
182
+ * @param {} alternateFqdns The list of alternate FQDNs for accessing the Object store. The FQDNs must consist of at least 2 parts separated by a '.'. Each part can contain upper and lower case letters, digits, hyphens or underscores but must begin and end with a letter. Each part can be up to 63 characters long. For e.g 'objects-0.pc_nutanix.com'.
183
+ */
184
+ }, {
185
+ key: "setAlternateFqdns",
186
+ value: function setAlternateFqdns(alternateFqdns) {
187
+ this.alternateFqdns = alternateFqdns;
188
+ }
189
+ }, {
190
+ key: "toJson",
191
+ value: function toJson(forMutation) {
192
+ if (forMutation === false) {
193
+ return _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({}, typeof this.getMetadata() !== 'undefined' && this.getMetadata() !== null ? {
194
+ 'metadata': this.getMetadata().toJson(false)
195
+ } : {}), typeof this.getPublicCert() !== 'undefined' && this.getPublicCert() !== null ? {
196
+ 'publicCert': this.getPublicCert()
197
+ } : {}), typeof this.getPrivateKey() !== 'undefined' && this.getPrivateKey() !== null ? {
198
+ 'privateKey': this.getPrivateKey()
199
+ } : {}), typeof this.getCa() !== 'undefined' && this.getCa() !== null ? {
200
+ 'ca': this.getCa()
201
+ } : {}), typeof this.getAlternateFqdns() !== 'undefined' && this.getAlternateFqdns() !== null ? {
202
+ 'alternateFqdns': this.getAlternateFqdns().map(function (item) {
203
+ return item.toJson(false);
204
+ })
205
+ } : {}), typeof this.getExtId() !== 'undefined' && this.getExtId() !== null ? {
206
+ 'extId': this.getExtId()
207
+ } : {}), typeof this.getLinks() !== 'undefined' && this.getLinks() !== null ? {
208
+ 'links': this.getLinks().map(function (item) {
209
+ return item.toJson(false);
210
+ })
211
+ } : {}), typeof this.getTenantId() !== 'undefined' && this.getTenantId() !== null ? {
212
+ 'tenantId': this.getTenantId()
213
+ } : {}), {}, {
214
+ '$reserved': this.get$Reserved(),
215
+ '$objectType': this.get$ObjectType(),
216
+ '$unknownFields': this.get$UnknownFields()
217
+ });
218
+ }
219
+ return _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({}, typeof this.getMetadata() !== 'undefined' && this.getMetadata() !== null ? {
220
+ 'metadata': this.getMetadata().toJson(false)
221
+ } : {}), typeof this.getPublicCert() !== 'undefined' && this.getPublicCert() !== null ? {
222
+ 'publicCert': this.getPublicCert()
223
+ } : {}), typeof this.getPrivateKey() !== 'undefined' && this.getPrivateKey() !== null ? {
224
+ 'privateKey': this.getPrivateKey()
225
+ } : {}), typeof this.getCa() !== 'undefined' && this.getCa() !== null ? {
226
+ 'ca': this.getCa()
227
+ } : {}), typeof this.getAlternateFqdns() !== 'undefined' && this.getAlternateFqdns() !== null ? {
228
+ 'alternateFqdns': this.getAlternateFqdns().map(function (item) {
229
+ return item.toJson(false);
230
+ })
231
+ } : {}), typeof this.getExtId() !== 'undefined' && this.getExtId() !== null ? {
232
+ 'extId': this.getExtId()
233
+ } : {}), {}, {
234
+ '$reserved': this.get$Reserved(),
235
+ '$objectType': this.get$ObjectType(),
236
+ '$unknownFields': this.get$UnknownFields()
237
+ });
238
+ }
239
+ }, {
240
+ key: "validate",
241
+ value: function validate(scope, properties) {
242
+ var _this2 = this;
243
+ var propList = [];
244
+ if (arguments.length === 0 || arguments.length === 1 && arguments[0] instanceof _ValidationScopes["default"]) {
245
+ //cases validate() and validate(scope)
246
+ propList = [];
247
+ } else if (arguments.length === 1) {
248
+ //case validate(properties)
249
+ propList = arguments[0];
250
+ scope = null;
251
+ } else {
252
+ //case validate(scope, properties)
253
+ propList = arguments[1];
254
+ }
255
+ var res = [];
256
+ var err = null;
257
+ propList.forEach(function (property) {
258
+ err = _this2.validateProperty(property, scope);
259
+ if (err) {
260
+ res.push(err);
261
+ }
262
+ });
263
+ return new Promise(function (resolve, reject) {
264
+ if (res.length !== 0) {
265
+ reject(err);
266
+ } else {
267
+ resolve();
268
+ }
269
+ });
270
+ }
271
+ }, {
272
+ key: "validateProperty",
273
+ value: function validateProperty(scope, property) {
274
+ if (property === "metadata") {
275
+ if (typeof this.metadata === 'undefined' || this.metadata === null) {
276
+ return new _ValidationError["default"]("metadata", "undefined or null");
277
+ }
278
+ }
279
+ if (property === "publicCert") {
280
+ if (typeof this.publicCert === 'undefined' || this.publicCert === null) {
281
+ return new _ValidationError["default"]("publicCert", "undefined or null");
282
+ }
283
+ if (!_ValidationUtils["default"].validateMaxLength(this.publicCert, 2000000)) {
284
+ return new _ValidationError["default"]("publicCert", "does not satisfy required maxLength constraint: 2000000");
285
+ }
286
+ if (!_ValidationUtils["default"].validateMinLength(this.publicCert, 1)) {
287
+ return new _ValidationError["default"]("publicCert", "does not satisfy required minLength constraint: 1");
288
+ }
289
+ }
290
+ if (property === "privateKey") {
291
+ if (typeof this.privateKey === 'undefined' || this.privateKey === null) {
292
+ return new _ValidationError["default"]("privateKey", "undefined or null");
293
+ }
294
+ if (!_ValidationUtils["default"].validateMaxLength(this.privateKey, 2000000)) {
295
+ return new _ValidationError["default"]("privateKey", "does not satisfy required maxLength constraint: 2000000");
296
+ }
297
+ if (!_ValidationUtils["default"].validateMinLength(this.privateKey, 1)) {
298
+ return new _ValidationError["default"]("privateKey", "does not satisfy required minLength constraint: 1");
299
+ }
300
+ }
301
+ if (property === "ca") {
302
+ if (typeof this.ca === 'undefined' || this.ca === null) {
303
+ return new _ValidationError["default"]("ca", "undefined or null");
304
+ }
305
+ if (!_ValidationUtils["default"].validateMaxLength(this.ca, 2000000)) {
306
+ return new _ValidationError["default"]("ca", "does not satisfy required maxLength constraint: 2000000");
307
+ }
308
+ if (!_ValidationUtils["default"].validateMinLength(this.ca, 1)) {
309
+ return new _ValidationError["default"]("ca", "does not satisfy required minLength constraint: 1");
310
+ }
311
+ }
312
+ if (property === "alternateFqdns") {
313
+ if (typeof this.alternateFqdns === 'undefined' || this.alternateFqdns === null) {
314
+ return new _ValidationError["default"]("alternateFqdns", "undefined or null");
315
+ }
316
+ if (!_ValidationUtils["default"].validateMaxItems(this.alternateFqdns, 1000)) {
317
+ return new _ValidationError["default"]("alternateFqdns", "does not satisfy required maxItems constraint: 1000");
318
+ }
319
+ if (!_ValidationUtils["default"].validateMinItems(this.alternateFqdns, 1)) {
320
+ return new _ValidationError["default"]("alternateFqdns", "does not satisfy required minItems constraint: 1");
321
+ }
322
+ }
323
+ return new _ValidationError["default"](property, "no such property exists");
324
+ }
325
+ }], [{
326
+ key: "constructFromObject",
327
+ value: function constructFromObject(data, obj) {
328
+ var callFromChild = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
329
+ var items, item, i, itemArr, discriminator;
330
+ if (data) {
331
+ obj = obj || new Certificate();
332
+ _ExternalizableAbstractModel["default"].constructFromObject(data, obj, true);
333
+ if (data.hasOwnProperty('metadata') && data.metadata !== null && data.metadata !== undefined) {
334
+ obj.setMetadata(_Metadata["default"].constructFromObject(data['metadata']));
335
+ }
336
+ if (data.hasOwnProperty('publicCert') && data.publicCert !== null && data.publicCert !== undefined) {
337
+ obj.setPublicCert(data['publicCert']);
338
+ }
339
+ if (data.hasOwnProperty('privateKey') && data.privateKey !== null && data.privateKey !== undefined) {
340
+ obj.setPrivateKey(data['privateKey']);
341
+ }
342
+ if (data.hasOwnProperty('ca') && data.ca !== null && data.ca !== undefined) {
343
+ obj.setCa(data['ca']);
344
+ }
345
+ if (data.hasOwnProperty('alternateFqdns') && data.alternateFqdns !== null && data.alternateFqdns !== undefined) {
346
+ itemArr = [];
347
+ items = data.alternateFqdns;
348
+ for (i = 0; i < items.length; i++) {
349
+ item = _FQDN["default"].constructFromObject(items[i], undefined);
350
+ itemArr.push(item);
351
+ }
352
+ obj.setAlternateFqdns(itemArr);
353
+ }
354
+ if (!callFromChild) {
355
+ obj.$unknownFields = _objectSpread({}, data.$unknownFields);
356
+ for (var property in data) {
357
+ if (!Object.keys(obj).includes(property) && !(property[0] === "$" && property.endsWith("ItemDiscriminator"))) {
358
+ obj.$unknownFields[property] = data[property];
359
+ }
360
+ }
361
+ }
362
+ }
363
+ return obj;
364
+ }
365
+ }]);
366
+ }(_ExternalizableAbstractModel["default"]);
367
+ /**
368
+ * @memberof Certificate
369
+ */
370
+ function _toJsonMapType(obj, forMutation) {
371
+ if (obj instanceof Map) {
372
+ return Object.fromEntries(Array.from(obj, function (_ref) {
373
+ var _ref2 = _slicedToArray(_ref, 2),
374
+ k = _ref2[0],
375
+ v = _ref2[1];
376
+ return [k, typeof v.toJson !== "undefined" ? v.toJson(forMutation) : v];
377
+ }));
378
+ } else if (_typeof(obj) === 'object' && obj != null && obj.constructor === Object) {
379
+ return Object.fromEntries(Array.from(Object.entries(obj), function (entry) {
380
+ return [entry[0], typeof entry[1].toJson !== "undefined" ? entry[1].toJson(forMutation) : entry[1]];
381
+ }));
382
+ }
383
+ return obj;
384
+ }
385
+ Certificate.prototype.metadata = undefined;
386
+
387
+ /**
388
+ * The public certificate to upload.
389
+ * @memberof Certificate
390
+ */
391
+ Certificate.prototype.publicCert = undefined;
392
+
393
+ /**
394
+ * The private key to upload.
395
+ * @memberof Certificate
396
+ */
397
+ Certificate.prototype.privateKey = undefined;
398
+
399
+ /**
400
+ * CA file to upload.
401
+ * @memberof Certificate
402
+ */
403
+ Certificate.prototype.ca = undefined;
404
+
405
+ /**
406
+ * The list of alternate FQDNs for accessing the Object store. The FQDNs must consist of at least 2 parts separated by a '.'. Each part can contain upper and lower case letters, digits, hyphens or underscores but must begin and end with a letter. Each part can be up to 63 characters long. For e.g 'objects-0.pc_nutanix.com'.
407
+ * @memberof Certificate
408
+ */
409
+ Certificate.prototype.alternateFqdns = undefined;
410
+
411
+ // Implement OneOfobjects.v4.operations.CertificateApiResponsedata interface:
@@ -0,0 +1,59 @@
1
+ /**
2
+ * The CertificateApiResponse model module.
3
+ * @module Ntnx/CertificateApiResponse
4
+ * @version 4.0.1-alpha-2
5
+ * @class CertificateApiResponse
6
+ */
7
+ export default class CertificateApiResponse extends Paginable {
8
+ /**
9
+ * Constructs a <code>CertificateApiResponse</code> from a plain JavaScript object, optionally creating a new instance.
10
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
11
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
12
+ * @param {module:Ntnx/CertificateApiResponse} obj Optional instance to populate.
13
+ * @param callFromChild {Boolean} Flag to recognise calling instance
14
+ * @return {module:Ntnx/CertificateApiResponse} The populated <code>CertificateApiResponse</code> instance.
15
+ */
16
+ static constructFromObject(data: any, obj: any, callFromChild?: boolean): any;
17
+ $objectType: string;
18
+ $reserved: {
19
+ $fv: string;
20
+ };
21
+ $unknownFields: {};
22
+ /**
23
+ * @return {}
24
+ */
25
+ getMetadata(): any;
26
+ /**
27
+ * @param {} metadata
28
+ */
29
+ setMetadata(metadata: any): void;
30
+ metadata: any;
31
+ /**
32
+ * @return {}
33
+ */
34
+ getData(): any;
35
+ /**
36
+ * @param {} data
37
+ */
38
+ setData(data: any): void;
39
+ data: any;
40
+ get$Reserved(): {
41
+ $fv: string;
42
+ };
43
+ get$ObjectType(): string;
44
+ get$UnknownFields(): {};
45
+ toJson(forMutation: any): {
46
+ $reserved: {
47
+ $fv: string;
48
+ };
49
+ $objectType: string;
50
+ $unknownFields: {};
51
+ data?: any;
52
+ metadata?: any;
53
+ };
54
+ validate(scope: any, properties: any, ...args: any[]): Promise<any>;
55
+ validateProperty(scope: any, property: any): ValidationError;
56
+ #private;
57
+ }
58
+ import Paginable from "../../../../Paginable";
59
+ import ValidationError from "../../../validation/ValidationError";