@nutanix-scratch/monitoring-js-client 4.0.1-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE.txt +49 -0
- package/README.md +197 -0
- package/dist/Ntnx-Monitoring-js-client-prod.js +1 -0
- package/dist/Ntnx-Monitoring-js-client.js +1466 -0
- package/dist/es/ApiClient.d.ts +159 -0
- package/dist/es/ApiClient.js +1211 -0
- package/dist/es/Paginable.d.ts +95 -0
- package/dist/es/Paginable.js +287 -0
- package/dist/es/apis/alertemailconfiguration-endpoints.d.ts +41 -0
- package/dist/es/apis/alertemailconfiguration-endpoints.js +141 -0
- package/dist/es/apis/alerts-endpoints.d.ts +103 -0
- package/dist/es/apis/alerts-endpoints.js +201 -0
- package/dist/es/apis/audits-endpoints.d.ts +91 -0
- package/dist/es/apis/audits-endpoints.js +189 -0
- package/dist/es/apis/events-endpoints.d.ts +81 -0
- package/dist/es/apis/events-endpoints.js +179 -0
- package/dist/es/apis/managealerts-endpoints.d.ts +34 -0
- package/dist/es/apis/managealerts-endpoints.js +118 -0
- package/dist/es/apis/userdefinedpolicies-endpoints.d.ts +117 -0
- package/dist/es/apis/userdefinedpolicies-endpoints.js +345 -0
- package/dist/es/index.d.ts +198 -0
- package/dist/es/index.js +788 -0
- package/dist/es/models/common/v1/config/FQDN.d.ts +48 -0
- package/dist/es/models/common/v1/config/FQDN.js +242 -0
- package/dist/es/models/common/v1/config/Flag.d.ts +58 -0
- package/dist/es/models/common/v1/config/Flag.js +275 -0
- package/dist/es/models/common/v1/config/IPAddressOrFQDN.d.ts +72 -0
- package/dist/es/models/common/v1/config/IPAddressOrFQDN.js +332 -0
- package/dist/es/models/common/v1/config/IPv4Address.d.ts +62 -0
- package/dist/es/models/common/v1/config/IPv4Address.js +288 -0
- package/dist/es/models/common/v1/config/IPv6Address.d.ts +62 -0
- package/dist/es/models/common/v1/config/IPv6Address.js +288 -0
- package/dist/es/models/common/v1/config/KVPair.d.ts +62 -0
- package/dist/es/models/common/v1/config/KVPair.js +332 -0
- package/dist/es/models/common/v1/config/KVStringPair.d.ts +62 -0
- package/dist/es/models/common/v1/config/KVStringPair.js +280 -0
- package/dist/es/models/common/v1/config/Message.d.ts +84 -0
- package/dist/es/models/common/v1/config/Message.js +354 -0
- package/dist/es/models/common/v1/config/MessageSeverity.d.ts +19 -0
- package/dist/es/models/common/v1/config/MessageSeverity.js +91 -0
- package/dist/es/models/common/v1/config/TenantAwareModel.d.ts +50 -0
- package/dist/es/models/common/v1/config/TenantAwareModel.js +243 -0
- package/dist/es/models/common/v1/response/ApiLink.d.ts +62 -0
- package/dist/es/models/common/v1/response/ApiLink.js +280 -0
- package/dist/es/models/common/v1/response/ApiResponseMetadata.d.ts +98 -0
- package/dist/es/models/common/v1/response/ApiResponseMetadata.js +438 -0
- package/dist/es/models/common/v1/response/ExternalizableAbstractModel.d.ts +42 -0
- package/dist/es/models/common/v1/response/ExternalizableAbstractModel.js +270 -0
- package/dist/es/models/monitoring/v4/common/AlertEntityReference.d.ts +74 -0
- package/dist/es/models/monitoring/v4/common/AlertEntityReference.js +320 -0
- package/dist/es/models/monitoring/v4/common/BoolValue.d.ts +57 -0
- package/dist/es/models/monitoring/v4/common/BoolValue.js +246 -0
- package/dist/es/models/monitoring/v4/common/CauseAndResolution.d.ts +62 -0
- package/dist/es/models/monitoring/v4/common/CauseAndResolution.js +280 -0
- package/dist/es/models/monitoring/v4/common/ComparisonOperator.d.ts +19 -0
- package/dist/es/models/monitoring/v4/common/ComparisonOperator.js +103 -0
- package/dist/es/models/monitoring/v4/common/ConditionType.d.ts +19 -0
- package/dist/es/models/monitoring/v4/common/ConditionType.js +79 -0
- package/dist/es/models/monitoring/v4/common/DataType.d.ts +19 -0
- package/dist/es/models/monitoring/v4/common/DataType.js +97 -0
- package/dist/es/models/monitoring/v4/common/DoubleValue.d.ts +57 -0
- package/dist/es/models/monitoring/v4/common/DoubleValue.js +246 -0
- package/dist/es/models/monitoring/v4/common/EntityReference.d.ts +74 -0
- package/dist/es/models/monitoring/v4/common/EntityReference.js +321 -0
- package/dist/es/models/monitoring/v4/common/ImpactType.d.ts +19 -0
- package/dist/es/models/monitoring/v4/common/ImpactType.js +121 -0
- package/dist/es/models/monitoring/v4/common/IntValue.d.ts +57 -0
- package/dist/es/models/monitoring/v4/common/IntValue.js +247 -0
- package/dist/es/models/monitoring/v4/common/MetricDetail.d.ts +164 -0
- package/dist/es/models/monitoring/v4/common/MetricDetail.js +668 -0
- package/dist/es/models/monitoring/v4/common/OperationType.d.ts +19 -0
- package/dist/es/models/monitoring/v4/common/OperationType.js +307 -0
- package/dist/es/models/monitoring/v4/common/Parameter.d.ts +62 -0
- package/dist/es/models/monitoring/v4/common/Parameter.js +304 -0
- package/dist/es/models/monitoring/v4/common/Severity.d.ts +19 -0
- package/dist/es/models/monitoring/v4/common/Severity.js +91 -0
- package/dist/es/models/monitoring/v4/common/StringValue.d.ts +57 -0
- package/dist/es/models/monitoring/v4/common/StringValue.js +246 -0
- package/dist/es/models/monitoring/v4/error/AppMessage.d.ts +108 -0
- package/dist/es/models/monitoring/v4/error/AppMessage.js +432 -0
- package/dist/es/models/monitoring/v4/error/ErrorResponse.d.ts +48 -0
- package/dist/es/models/monitoring/v4/error/ErrorResponse.js +300 -0
- package/dist/es/models/monitoring/v4/error/SchemaValidationError.d.ts +98 -0
- package/dist/es/models/monitoring/v4/error/SchemaValidationError.js +407 -0
- package/dist/es/models/monitoring/v4/error/SchemaValidationErrorMessage.d.ts +74 -0
- package/dist/es/models/monitoring/v4/error/SchemaValidationErrorMessage.js +318 -0
- package/dist/es/models/monitoring/v4/serviceability/ActionType.d.ts +19 -0
- package/dist/es/models/monitoring/v4/serviceability/ActionType.js +85 -0
- package/dist/es/models/monitoring/v4/serviceability/Alert.d.ts +316 -0
- package/dist/es/models/monitoring/v4/serviceability/Alert.js +1232 -0
- package/dist/es/models/monitoring/v4/serviceability/AlertActionSpec.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/AlertActionSpec.js +245 -0
- package/dist/es/models/monitoring/v4/serviceability/AlertConfigExceptionGroup.d.ts +72 -0
- package/dist/es/models/monitoring/v4/serviceability/AlertConfigExceptionGroup.js +337 -0
- package/dist/es/models/monitoring/v4/serviceability/AlertDb.d.ts +210 -0
- package/dist/es/models/monitoring/v4/serviceability/AlertDb.js +882 -0
- package/dist/es/models/monitoring/v4/serviceability/AlertDbProjection.d.ts +49 -0
- package/dist/es/models/monitoring/v4/serviceability/AlertDbProjection.js +300 -0
- package/dist/es/models/monitoring/v4/serviceability/AlertEmailConfiguration.d.ts +153 -0
- package/dist/es/models/monitoring/v4/serviceability/AlertEmailConfiguration.js +632 -0
- package/dist/es/models/monitoring/v4/serviceability/Audit.d.ts +166 -0
- package/dist/es/models/monitoring/v4/serviceability/Audit.js +702 -0
- package/dist/es/models/monitoring/v4/serviceability/AuditDb.d.ts +148 -0
- package/dist/es/models/monitoring/v4/serviceability/AuditDb.js +598 -0
- package/dist/es/models/monitoring/v4/serviceability/AuditDbProjection.d.ts +9 -0
- package/dist/es/models/monitoring/v4/serviceability/AuditDbProjection.js +133 -0
- package/dist/es/models/monitoring/v4/serviceability/AuditEntityReference.d.ts +74 -0
- package/dist/es/models/monitoring/v4/serviceability/AuditEntityReference.js +320 -0
- package/dist/es/models/monitoring/v4/serviceability/AutoResolve.d.ts +19 -0
- package/dist/es/models/monitoring/v4/serviceability/AutoResolve.js +91 -0
- package/dist/es/models/monitoring/v4/serviceability/CommunicationStatus.d.ts +94 -0
- package/dist/es/models/monitoring/v4/serviceability/CommunicationStatus.js +390 -0
- package/dist/es/models/monitoring/v4/serviceability/Condition.d.ts +92 -0
- package/dist/es/models/monitoring/v4/serviceability/Condition.js +357 -0
- package/dist/es/models/monitoring/v4/serviceability/ConflictingPolicy.d.ts +60 -0
- package/dist/es/models/monitoring/v4/serviceability/ConflictingPolicy.js +250 -0
- package/dist/es/models/monitoring/v4/serviceability/ConnectionStatus.d.ts +19 -0
- package/dist/es/models/monitoring/v4/serviceability/ConnectionStatus.js +97 -0
- package/dist/es/models/monitoring/v4/serviceability/CreateUdaPolicyApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/CreateUdaPolicyApiResponse.js +311 -0
- package/dist/es/models/monitoring/v4/serviceability/DeleteUdaPolicyApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/DeleteUdaPolicyApiResponse.js +313 -0
- package/dist/es/models/monitoring/v4/serviceability/EmailConfigurationRule.d.ts +116 -0
- package/dist/es/models/monitoring/v4/serviceability/EmailConfigurationRule.js +507 -0
- package/dist/es/models/monitoring/v4/serviceability/EmailTemplate.d.ts +62 -0
- package/dist/es/models/monitoring/v4/serviceability/EmailTemplate.js +283 -0
- package/dist/es/models/monitoring/v4/serviceability/EntityFilter.d.ts +60 -0
- package/dist/es/models/monitoring/v4/serviceability/EntityFilter.js +250 -0
- package/dist/es/models/monitoring/v4/serviceability/Event.d.ts +150 -0
- package/dist/es/models/monitoring/v4/serviceability/Event.js +663 -0
- package/dist/es/models/monitoring/v4/serviceability/EventDb.d.ts +108 -0
- package/dist/es/models/monitoring/v4/serviceability/EventDb.js +463 -0
- package/dist/es/models/monitoring/v4/serviceability/EventDbProjection.d.ts +9 -0
- package/dist/es/models/monitoring/v4/serviceability/EventDbProjection.js +130 -0
- package/dist/es/models/monitoring/v4/serviceability/EventEntityReference.d.ts +74 -0
- package/dist/es/models/monitoring/v4/serviceability/EventEntityReference.js +320 -0
- package/dist/es/models/monitoring/v4/serviceability/FindConflictingUdaPoliciesApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/FindConflictingUdaPoliciesApiResponse.js +333 -0
- package/dist/es/models/monitoring/v4/serviceability/GetAlertApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/GetAlertApiResponse.js +311 -0
- package/dist/es/models/monitoring/v4/serviceability/GetAlertEmailConfigurationApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/GetAlertEmailConfigurationApiResponse.js +311 -0
- package/dist/es/models/monitoring/v4/serviceability/GetAuditApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/GetAuditApiResponse.js +311 -0
- package/dist/es/models/monitoring/v4/serviceability/GetEventApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/GetEventApiResponse.js +311 -0
- package/dist/es/models/monitoring/v4/serviceability/GetUdaPolicyApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/GetUdaPolicyApiResponse.js +311 -0
- package/dist/es/models/monitoring/v4/serviceability/GroupEntityType.d.ts +19 -0
- package/dist/es/models/monitoring/v4/serviceability/GroupEntityType.js +85 -0
- package/dist/es/models/monitoring/v4/serviceability/GroupFilter.d.ts +75 -0
- package/dist/es/models/monitoring/v4/serviceability/GroupFilter.js +291 -0
- package/dist/es/models/monitoring/v4/serviceability/HttpProxy.d.ts +110 -0
- package/dist/es/models/monitoring/v4/serviceability/HttpProxy.js +445 -0
- package/dist/es/models/monitoring/v4/serviceability/ListAlertsApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/ListAlertsApiResponse.js +333 -0
- package/dist/es/models/monitoring/v4/serviceability/ListAuditsApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/ListAuditsApiResponse.js +333 -0
- package/dist/es/models/monitoring/v4/serviceability/ListEventsApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/ListEventsApiResponse.js +333 -0
- package/dist/es/models/monitoring/v4/serviceability/ListUdaPoliciesApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/ListUdaPoliciesApiResponse.js +333 -0
- package/dist/es/models/monitoring/v4/serviceability/ManageAlertApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/ManageAlertApiResponse.js +311 -0
- package/dist/es/models/monitoring/v4/serviceability/ManageAlertsApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/ManageAlertsApiResponse.js +311 -0
- package/dist/es/models/monitoring/v4/serviceability/ParameterizedMessage.d.ts +58 -0
- package/dist/es/models/monitoring/v4/serviceability/ParameterizedMessage.js +285 -0
- package/dist/es/models/monitoring/v4/serviceability/PolicySeverityLevel.d.ts +19 -0
- package/dist/es/models/monitoring/v4/serviceability/PolicySeverityLevel.js +85 -0
- package/dist/es/models/monitoring/v4/serviceability/ProxyType.d.ts +19 -0
- package/dist/es/models/monitoring/v4/serviceability/ProxyType.js +91 -0
- package/dist/es/models/monitoring/v4/serviceability/RelatedPolicy.d.ts +76 -0
- package/dist/es/models/monitoring/v4/serviceability/RelatedPolicy.js +298 -0
- package/dist/es/models/monitoring/v4/serviceability/RemoteTunnelDetails.d.ts +78 -0
- package/dist/es/models/monitoring/v4/serviceability/RemoteTunnelDetails.js +347 -0
- package/dist/es/models/monitoring/v4/serviceability/RootCauseAnalysis.d.ts +56 -0
- package/dist/es/models/monitoring/v4/serviceability/RootCauseAnalysis.js +300 -0
- package/dist/es/models/monitoring/v4/serviceability/RootCauseAnalysisProjection.d.ts +9 -0
- package/dist/es/models/monitoring/v4/serviceability/RootCauseAnalysisProjection.js +129 -0
- package/dist/es/models/monitoring/v4/serviceability/ServiceCenter.d.ts +88 -0
- package/dist/es/models/monitoring/v4/serviceability/ServiceCenter.js +367 -0
- package/dist/es/models/monitoring/v4/serviceability/SeverityThresholdInfo.d.ts +60 -0
- package/dist/es/models/monitoring/v4/serviceability/SeverityThresholdInfo.js +278 -0
- package/dist/es/models/monitoring/v4/serviceability/SeverityTrail.d.ts +60 -0
- package/dist/es/models/monitoring/v4/serviceability/SeverityTrail.js +278 -0
- package/dist/es/models/monitoring/v4/serviceability/Status.d.ts +19 -0
- package/dist/es/models/monitoring/v4/serviceability/Status.js +91 -0
- package/dist/es/models/monitoring/v4/serviceability/TriggerCondition.d.ts +88 -0
- package/dist/es/models/monitoring/v4/serviceability/TriggerCondition.js +326 -0
- package/dist/es/models/monitoring/v4/serviceability/UpdateAlertEmailConfigurationApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/UpdateAlertEmailConfigurationApiResponse.js +311 -0
- package/dist/es/models/monitoring/v4/serviceability/UpdateSdaPolicyApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/UpdateSdaPolicyApiResponse.js +311 -0
- package/dist/es/models/monitoring/v4/serviceability/UpdateUdaPolicyApiResponse.d.ts +59 -0
- package/dist/es/models/monitoring/v4/serviceability/UpdateUdaPolicyApiResponse.js +311 -0
- package/dist/es/models/monitoring/v4/serviceability/UserDefinedPolicy.d.ts +207 -0
- package/dist/es/models/monitoring/v4/serviceability/UserDefinedPolicy.js +843 -0
- package/dist/es/models/monitoring/v4/serviceability/UserReference.d.ts +74 -0
- package/dist/es/models/monitoring/v4/serviceability/UserReference.js +324 -0
- package/dist/es/models/prism/v4/config/TaskReference.d.ts +50 -0
- package/dist/es/models/prism/v4/config/TaskReference.js +249 -0
- package/dist/es/models/validation/ValidationError.d.ts +13 -0
- package/dist/es/models/validation/ValidationError.js +60 -0
- package/dist/es/models/validation/ValidationScopes.d.ts +9 -0
- package/dist/es/models/validation/ValidationScopes.js +38 -0
- package/dist/es/utils/ValidationUtils.d.ts +13 -0
- package/dist/es/utils/ValidationUtils.js +85 -0
- package/dist/lib/ApiClient.d.ts +159 -0
- package/dist/lib/ApiClient.js +1211 -0
- package/dist/lib/Paginable.d.ts +95 -0
- package/dist/lib/Paginable.js +287 -0
- package/dist/lib/apis/alertemailconfiguration-endpoints.d.ts +41 -0
- package/dist/lib/apis/alertemailconfiguration-endpoints.js +141 -0
- package/dist/lib/apis/alerts-endpoints.d.ts +103 -0
- package/dist/lib/apis/alerts-endpoints.js +201 -0
- package/dist/lib/apis/audits-endpoints.d.ts +91 -0
- package/dist/lib/apis/audits-endpoints.js +189 -0
- package/dist/lib/apis/events-endpoints.d.ts +81 -0
- package/dist/lib/apis/events-endpoints.js +179 -0
- package/dist/lib/apis/managealerts-endpoints.d.ts +34 -0
- package/dist/lib/apis/managealerts-endpoints.js +118 -0
- package/dist/lib/apis/userdefinedpolicies-endpoints.d.ts +117 -0
- package/dist/lib/apis/userdefinedpolicies-endpoints.js +345 -0
- package/dist/lib/index.d.ts +198 -0
- package/dist/lib/index.js +788 -0
- package/dist/lib/models/common/v1/config/FQDN.d.ts +48 -0
- package/dist/lib/models/common/v1/config/FQDN.js +242 -0
- package/dist/lib/models/common/v1/config/Flag.d.ts +58 -0
- package/dist/lib/models/common/v1/config/Flag.js +275 -0
- package/dist/lib/models/common/v1/config/IPAddressOrFQDN.d.ts +72 -0
- package/dist/lib/models/common/v1/config/IPAddressOrFQDN.js +332 -0
- package/dist/lib/models/common/v1/config/IPv4Address.d.ts +62 -0
- package/dist/lib/models/common/v1/config/IPv4Address.js +288 -0
- package/dist/lib/models/common/v1/config/IPv6Address.d.ts +62 -0
- package/dist/lib/models/common/v1/config/IPv6Address.js +288 -0
- package/dist/lib/models/common/v1/config/KVPair.d.ts +62 -0
- package/dist/lib/models/common/v1/config/KVPair.js +332 -0
- package/dist/lib/models/common/v1/config/KVStringPair.d.ts +62 -0
- package/dist/lib/models/common/v1/config/KVStringPair.js +280 -0
- package/dist/lib/models/common/v1/config/Message.d.ts +84 -0
- package/dist/lib/models/common/v1/config/Message.js +354 -0
- package/dist/lib/models/common/v1/config/MessageSeverity.d.ts +19 -0
- package/dist/lib/models/common/v1/config/MessageSeverity.js +91 -0
- package/dist/lib/models/common/v1/config/TenantAwareModel.d.ts +50 -0
- package/dist/lib/models/common/v1/config/TenantAwareModel.js +243 -0
- package/dist/lib/models/common/v1/response/ApiLink.d.ts +62 -0
- package/dist/lib/models/common/v1/response/ApiLink.js +280 -0
- package/dist/lib/models/common/v1/response/ApiResponseMetadata.d.ts +98 -0
- package/dist/lib/models/common/v1/response/ApiResponseMetadata.js +438 -0
- package/dist/lib/models/common/v1/response/ExternalizableAbstractModel.d.ts +42 -0
- package/dist/lib/models/common/v1/response/ExternalizableAbstractModel.js +270 -0
- package/dist/lib/models/monitoring/v4/common/AlertEntityReference.d.ts +74 -0
- package/dist/lib/models/monitoring/v4/common/AlertEntityReference.js +320 -0
- package/dist/lib/models/monitoring/v4/common/BoolValue.d.ts +57 -0
- package/dist/lib/models/monitoring/v4/common/BoolValue.js +246 -0
- package/dist/lib/models/monitoring/v4/common/CauseAndResolution.d.ts +62 -0
- package/dist/lib/models/monitoring/v4/common/CauseAndResolution.js +280 -0
- package/dist/lib/models/monitoring/v4/common/ComparisonOperator.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/common/ComparisonOperator.js +103 -0
- package/dist/lib/models/monitoring/v4/common/ConditionType.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/common/ConditionType.js +79 -0
- package/dist/lib/models/monitoring/v4/common/DataType.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/common/DataType.js +97 -0
- package/dist/lib/models/monitoring/v4/common/DoubleValue.d.ts +57 -0
- package/dist/lib/models/monitoring/v4/common/DoubleValue.js +246 -0
- package/dist/lib/models/monitoring/v4/common/EntityReference.d.ts +74 -0
- package/dist/lib/models/monitoring/v4/common/EntityReference.js +321 -0
- package/dist/lib/models/monitoring/v4/common/ImpactType.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/common/ImpactType.js +121 -0
- package/dist/lib/models/monitoring/v4/common/IntValue.d.ts +57 -0
- package/dist/lib/models/monitoring/v4/common/IntValue.js +247 -0
- package/dist/lib/models/monitoring/v4/common/MetricDetail.d.ts +164 -0
- package/dist/lib/models/monitoring/v4/common/MetricDetail.js +668 -0
- package/dist/lib/models/monitoring/v4/common/OperationType.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/common/OperationType.js +307 -0
- package/dist/lib/models/monitoring/v4/common/Parameter.d.ts +62 -0
- package/dist/lib/models/monitoring/v4/common/Parameter.js +304 -0
- package/dist/lib/models/monitoring/v4/common/Severity.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/common/Severity.js +91 -0
- package/dist/lib/models/monitoring/v4/common/StringValue.d.ts +57 -0
- package/dist/lib/models/monitoring/v4/common/StringValue.js +246 -0
- package/dist/lib/models/monitoring/v4/error/AppMessage.d.ts +108 -0
- package/dist/lib/models/monitoring/v4/error/AppMessage.js +432 -0
- package/dist/lib/models/monitoring/v4/error/ErrorResponse.d.ts +48 -0
- package/dist/lib/models/monitoring/v4/error/ErrorResponse.js +300 -0
- package/dist/lib/models/monitoring/v4/error/SchemaValidationError.d.ts +98 -0
- package/dist/lib/models/monitoring/v4/error/SchemaValidationError.js +407 -0
- package/dist/lib/models/monitoring/v4/error/SchemaValidationErrorMessage.d.ts +74 -0
- package/dist/lib/models/monitoring/v4/error/SchemaValidationErrorMessage.js +318 -0
- package/dist/lib/models/monitoring/v4/serviceability/ActionType.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/serviceability/ActionType.js +85 -0
- package/dist/lib/models/monitoring/v4/serviceability/Alert.d.ts +316 -0
- package/dist/lib/models/monitoring/v4/serviceability/Alert.js +1232 -0
- package/dist/lib/models/monitoring/v4/serviceability/AlertActionSpec.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/AlertActionSpec.js +245 -0
- package/dist/lib/models/monitoring/v4/serviceability/AlertConfigExceptionGroup.d.ts +72 -0
- package/dist/lib/models/monitoring/v4/serviceability/AlertConfigExceptionGroup.js +337 -0
- package/dist/lib/models/monitoring/v4/serviceability/AlertDb.d.ts +210 -0
- package/dist/lib/models/monitoring/v4/serviceability/AlertDb.js +882 -0
- package/dist/lib/models/monitoring/v4/serviceability/AlertDbProjection.d.ts +49 -0
- package/dist/lib/models/monitoring/v4/serviceability/AlertDbProjection.js +300 -0
- package/dist/lib/models/monitoring/v4/serviceability/AlertEmailConfiguration.d.ts +153 -0
- package/dist/lib/models/monitoring/v4/serviceability/AlertEmailConfiguration.js +632 -0
- package/dist/lib/models/monitoring/v4/serviceability/Audit.d.ts +166 -0
- package/dist/lib/models/monitoring/v4/serviceability/Audit.js +702 -0
- package/dist/lib/models/monitoring/v4/serviceability/AuditDb.d.ts +148 -0
- package/dist/lib/models/monitoring/v4/serviceability/AuditDb.js +598 -0
- package/dist/lib/models/monitoring/v4/serviceability/AuditDbProjection.d.ts +9 -0
- package/dist/lib/models/monitoring/v4/serviceability/AuditDbProjection.js +133 -0
- package/dist/lib/models/monitoring/v4/serviceability/AuditEntityReference.d.ts +74 -0
- package/dist/lib/models/monitoring/v4/serviceability/AuditEntityReference.js +320 -0
- package/dist/lib/models/monitoring/v4/serviceability/AutoResolve.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/serviceability/AutoResolve.js +91 -0
- package/dist/lib/models/monitoring/v4/serviceability/CommunicationStatus.d.ts +94 -0
- package/dist/lib/models/monitoring/v4/serviceability/CommunicationStatus.js +390 -0
- package/dist/lib/models/monitoring/v4/serviceability/Condition.d.ts +92 -0
- package/dist/lib/models/monitoring/v4/serviceability/Condition.js +357 -0
- package/dist/lib/models/monitoring/v4/serviceability/ConflictingPolicy.d.ts +60 -0
- package/dist/lib/models/monitoring/v4/serviceability/ConflictingPolicy.js +250 -0
- package/dist/lib/models/monitoring/v4/serviceability/ConnectionStatus.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/serviceability/ConnectionStatus.js +97 -0
- package/dist/lib/models/monitoring/v4/serviceability/CreateUdaPolicyApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/CreateUdaPolicyApiResponse.js +311 -0
- package/dist/lib/models/monitoring/v4/serviceability/DeleteUdaPolicyApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/DeleteUdaPolicyApiResponse.js +313 -0
- package/dist/lib/models/monitoring/v4/serviceability/EmailConfigurationRule.d.ts +116 -0
- package/dist/lib/models/monitoring/v4/serviceability/EmailConfigurationRule.js +507 -0
- package/dist/lib/models/monitoring/v4/serviceability/EmailTemplate.d.ts +62 -0
- package/dist/lib/models/monitoring/v4/serviceability/EmailTemplate.js +283 -0
- package/dist/lib/models/monitoring/v4/serviceability/EntityFilter.d.ts +60 -0
- package/dist/lib/models/monitoring/v4/serviceability/EntityFilter.js +250 -0
- package/dist/lib/models/monitoring/v4/serviceability/Event.d.ts +150 -0
- package/dist/lib/models/monitoring/v4/serviceability/Event.js +663 -0
- package/dist/lib/models/monitoring/v4/serviceability/EventDb.d.ts +108 -0
- package/dist/lib/models/monitoring/v4/serviceability/EventDb.js +463 -0
- package/dist/lib/models/monitoring/v4/serviceability/EventDbProjection.d.ts +9 -0
- package/dist/lib/models/monitoring/v4/serviceability/EventDbProjection.js +130 -0
- package/dist/lib/models/monitoring/v4/serviceability/EventEntityReference.d.ts +74 -0
- package/dist/lib/models/monitoring/v4/serviceability/EventEntityReference.js +320 -0
- package/dist/lib/models/monitoring/v4/serviceability/FindConflictingUdaPoliciesApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/FindConflictingUdaPoliciesApiResponse.js +333 -0
- package/dist/lib/models/monitoring/v4/serviceability/GetAlertApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/GetAlertApiResponse.js +311 -0
- package/dist/lib/models/monitoring/v4/serviceability/GetAlertEmailConfigurationApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/GetAlertEmailConfigurationApiResponse.js +311 -0
- package/dist/lib/models/monitoring/v4/serviceability/GetAuditApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/GetAuditApiResponse.js +311 -0
- package/dist/lib/models/monitoring/v4/serviceability/GetEventApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/GetEventApiResponse.js +311 -0
- package/dist/lib/models/monitoring/v4/serviceability/GetUdaPolicyApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/GetUdaPolicyApiResponse.js +311 -0
- package/dist/lib/models/monitoring/v4/serviceability/GroupEntityType.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/serviceability/GroupEntityType.js +85 -0
- package/dist/lib/models/monitoring/v4/serviceability/GroupFilter.d.ts +75 -0
- package/dist/lib/models/monitoring/v4/serviceability/GroupFilter.js +291 -0
- package/dist/lib/models/monitoring/v4/serviceability/HttpProxy.d.ts +110 -0
- package/dist/lib/models/monitoring/v4/serviceability/HttpProxy.js +445 -0
- package/dist/lib/models/monitoring/v4/serviceability/ListAlertsApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/ListAlertsApiResponse.js +333 -0
- package/dist/lib/models/monitoring/v4/serviceability/ListAuditsApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/ListAuditsApiResponse.js +333 -0
- package/dist/lib/models/monitoring/v4/serviceability/ListEventsApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/ListEventsApiResponse.js +333 -0
- package/dist/lib/models/monitoring/v4/serviceability/ListUdaPoliciesApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/ListUdaPoliciesApiResponse.js +333 -0
- package/dist/lib/models/monitoring/v4/serviceability/ManageAlertApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/ManageAlertApiResponse.js +311 -0
- package/dist/lib/models/monitoring/v4/serviceability/ManageAlertsApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/ManageAlertsApiResponse.js +311 -0
- package/dist/lib/models/monitoring/v4/serviceability/ParameterizedMessage.d.ts +58 -0
- package/dist/lib/models/monitoring/v4/serviceability/ParameterizedMessage.js +285 -0
- package/dist/lib/models/monitoring/v4/serviceability/PolicySeverityLevel.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/serviceability/PolicySeverityLevel.js +85 -0
- package/dist/lib/models/monitoring/v4/serviceability/ProxyType.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/serviceability/ProxyType.js +91 -0
- package/dist/lib/models/monitoring/v4/serviceability/RelatedPolicy.d.ts +76 -0
- package/dist/lib/models/monitoring/v4/serviceability/RelatedPolicy.js +298 -0
- package/dist/lib/models/monitoring/v4/serviceability/RemoteTunnelDetails.d.ts +78 -0
- package/dist/lib/models/monitoring/v4/serviceability/RemoteTunnelDetails.js +347 -0
- package/dist/lib/models/monitoring/v4/serviceability/RootCauseAnalysis.d.ts +56 -0
- package/dist/lib/models/monitoring/v4/serviceability/RootCauseAnalysis.js +300 -0
- package/dist/lib/models/monitoring/v4/serviceability/RootCauseAnalysisProjection.d.ts +9 -0
- package/dist/lib/models/monitoring/v4/serviceability/RootCauseAnalysisProjection.js +129 -0
- package/dist/lib/models/monitoring/v4/serviceability/ServiceCenter.d.ts +88 -0
- package/dist/lib/models/monitoring/v4/serviceability/ServiceCenter.js +367 -0
- package/dist/lib/models/monitoring/v4/serviceability/SeverityThresholdInfo.d.ts +60 -0
- package/dist/lib/models/monitoring/v4/serviceability/SeverityThresholdInfo.js +278 -0
- package/dist/lib/models/monitoring/v4/serviceability/SeverityTrail.d.ts +60 -0
- package/dist/lib/models/monitoring/v4/serviceability/SeverityTrail.js +278 -0
- package/dist/lib/models/monitoring/v4/serviceability/Status.d.ts +19 -0
- package/dist/lib/models/monitoring/v4/serviceability/Status.js +91 -0
- package/dist/lib/models/monitoring/v4/serviceability/TriggerCondition.d.ts +88 -0
- package/dist/lib/models/monitoring/v4/serviceability/TriggerCondition.js +326 -0
- package/dist/lib/models/monitoring/v4/serviceability/UpdateAlertEmailConfigurationApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/UpdateAlertEmailConfigurationApiResponse.js +311 -0
- package/dist/lib/models/monitoring/v4/serviceability/UpdateSdaPolicyApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/UpdateSdaPolicyApiResponse.js +311 -0
- package/dist/lib/models/monitoring/v4/serviceability/UpdateUdaPolicyApiResponse.d.ts +59 -0
- package/dist/lib/models/monitoring/v4/serviceability/UpdateUdaPolicyApiResponse.js +311 -0
- package/dist/lib/models/monitoring/v4/serviceability/UserDefinedPolicy.d.ts +207 -0
- package/dist/lib/models/monitoring/v4/serviceability/UserDefinedPolicy.js +843 -0
- package/dist/lib/models/monitoring/v4/serviceability/UserReference.d.ts +74 -0
- package/dist/lib/models/monitoring/v4/serviceability/UserReference.js +324 -0
- package/dist/lib/models/prism/v4/config/TaskReference.d.ts +50 -0
- package/dist/lib/models/prism/v4/config/TaskReference.js +249 -0
- package/dist/lib/models/validation/ValidationError.d.ts +13 -0
- package/dist/lib/models/validation/ValidationError.js +60 -0
- package/dist/lib/models/validation/ValidationScopes.d.ts +9 -0
- package/dist/lib/models/validation/ValidationScopes.js +38 -0
- package/dist/lib/utils/ValidationUtils.d.ts +13 -0
- package/dist/lib/utils/ValidationUtils.js +85 -0
- package/package.json +53 -0
|
@@ -0,0 +1,357 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
var _ComparisonOperator = _interopRequireDefault(require("../common/ComparisonOperator"));
|
|
8
|
+
var _DoubleValue = _interopRequireDefault(require("../common/DoubleValue"));
|
|
9
|
+
var _IntValue = _interopRequireDefault(require("../common/IntValue"));
|
|
10
|
+
var _ValidationScopes = _interopRequireDefault(require("../../../validation/ValidationScopes"));
|
|
11
|
+
var _ValidationUtils = _interopRequireDefault(require("../../../../utils/ValidationUtils"));
|
|
12
|
+
var _ValidationError = _interopRequireDefault(require("../../../validation/ValidationError"));
|
|
13
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
14
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
15
|
+
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."); }
|
|
16
|
+
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); }
|
|
17
|
+
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; }
|
|
18
|
+
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; } }
|
|
19
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
20
|
+
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); }
|
|
21
|
+
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; }
|
|
22
|
+
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; }
|
|
23
|
+
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; }
|
|
24
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
25
|
+
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); } }
|
|
26
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
27
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
28
|
+
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); }
|
|
29
|
+
function _classPrivateMethodInitSpec(obj, privateSet) { _checkPrivateRedeclaration(obj, privateSet); privateSet.add(obj); }
|
|
30
|
+
function _checkPrivateRedeclaration(obj, privateCollection) { if (privateCollection.has(obj)) { throw new TypeError("Cannot initialize the same private elements twice on an object"); } }
|
|
31
|
+
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"); } /*
|
|
32
|
+
* Nutanix Monitoring Versioned APIs
|
|
33
|
+
*
|
|
34
|
+
* OpenAPI spec version: 4.0.1-beta-1
|
|
35
|
+
*
|
|
36
|
+
* NOTE: This class is auto generated by the Open API Dev Platform.
|
|
37
|
+
*
|
|
38
|
+
* Open API Dev Platform Codegen version: 16.8.0.7344-RELEASE
|
|
39
|
+
*
|
|
40
|
+
* Do not edit the class manually.
|
|
41
|
+
*
|
|
42
|
+
*/
|
|
43
|
+
/**
|
|
44
|
+
* The Condition model module.
|
|
45
|
+
* @module Ntnx/Condition
|
|
46
|
+
* @version 4.0.1-beta-1
|
|
47
|
+
* @class Condition
|
|
48
|
+
*
|
|
49
|
+
* @param { String } metricName The metric key. Allowed values of metrics list can be found at https://portal.nutanix.com/page/documents/details?targetId=Prism-Central-Guide-vpc_2022_9:mul-alerts-user-created-metrics-r.html
|
|
50
|
+
*
|
|
51
|
+
* @param { ComparisonOperator } operator
|
|
52
|
+
* @param { DoubleValue | IntValue } thresholdValue The threshold value that was used for the condition evaluation.
|
|
53
|
+
*
|
|
54
|
+
*/
|
|
55
|
+
var _Condition_brand = /*#__PURE__*/new WeakSet();
|
|
56
|
+
var Condition = exports["default"] = /*#__PURE__*/function () {
|
|
57
|
+
/**
|
|
58
|
+
* Constructs a new <code>Condition</code>.
|
|
59
|
+
* @alias module:Ntnx/Condition
|
|
60
|
+
*
|
|
61
|
+
* @param { String } metricName The metric key. Allowed values of metrics list can be found at https://portal.nutanix.com/page/documents/details?targetId=Prism-Central-Guide-vpc_2022_9:mul-alerts-user-created-metrics-r.html
|
|
62
|
+
*
|
|
63
|
+
* @param { ComparisonOperator } operator
|
|
64
|
+
* @param { DoubleValue | IntValue } thresholdValue The threshold value that was used for the condition evaluation.
|
|
65
|
+
*
|
|
66
|
+
*/
|
|
67
|
+
function Condition(metricName, operator, thresholdValue) {
|
|
68
|
+
_classCallCheck(this, Condition);
|
|
69
|
+
/*
|
|
70
|
+
* toJson method for a map type which supports map with primitive keys and values of object types
|
|
71
|
+
* @param {Object} obj
|
|
72
|
+
* @returns {Object|Map} Returns a new transofrmed Map by calling toJson on the values if applicable.
|
|
73
|
+
* Otherwise, just returns the input object.
|
|
74
|
+
*/
|
|
75
|
+
_classPrivateMethodInitSpec(this, _Condition_brand);
|
|
76
|
+
this.metricName = metricName;
|
|
77
|
+
this.operator = operator;
|
|
78
|
+
this.thresholdValue = thresholdValue;
|
|
79
|
+
this.$objectType = "monitoring.v4.serviceability.Condition";
|
|
80
|
+
this.$reserved = {
|
|
81
|
+
'$fv': "v4.r0.b1"
|
|
82
|
+
};
|
|
83
|
+
this.$unknownFields = {};
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
/**
|
|
87
|
+
* Constructs a <code>Condition</code> from a plain JavaScript object, optionally creating a new instance.
|
|
88
|
+
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
|
89
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
90
|
+
* @param {module:Ntnx/Condition} obj Optional instance to populate.
|
|
91
|
+
* @param callFromChild {Boolean} Flag to recognise calling instance
|
|
92
|
+
* @return {module:Ntnx/Condition} The populated <code>Condition</code> instance.
|
|
93
|
+
*/
|
|
94
|
+
return _createClass(Condition, [{
|
|
95
|
+
key: "getMetricName",
|
|
96
|
+
value:
|
|
97
|
+
/**
|
|
98
|
+
* Returns The metric key. Allowed values of metrics list can be found at https://portal.nutanix.com/page/documents/details?targetId=Prism-Central-Guide-vpc_2022_9:mul-alerts-user-created-metrics-r.html
|
|
99
|
+
* @return {}
|
|
100
|
+
*/
|
|
101
|
+
function getMetricName() {
|
|
102
|
+
return this.metricName;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
/**
|
|
106
|
+
* Sets The metric key. Allowed values of metrics list can be found at https://portal.nutanix.com/page/documents/details?targetId=Prism-Central-Guide-vpc_2022_9:mul-alerts-user-created-metrics-r.html
|
|
107
|
+
* @param {} metricName The metric key. Allowed values of metrics list can be found at https://portal.nutanix.com/page/documents/details?targetId=Prism-Central-Guide-vpc_2022_9:mul-alerts-user-created-metrics-r.html
|
|
108
|
+
*/
|
|
109
|
+
}, {
|
|
110
|
+
key: "setMetricName",
|
|
111
|
+
value: function setMetricName(metricName) {
|
|
112
|
+
this.metricName = metricName;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
/**
|
|
116
|
+
* @return {}
|
|
117
|
+
*/
|
|
118
|
+
}, {
|
|
119
|
+
key: "getOperator",
|
|
120
|
+
value: function getOperator() {
|
|
121
|
+
return this.operator;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
/**
|
|
125
|
+
* @param {} operator
|
|
126
|
+
*/
|
|
127
|
+
}, {
|
|
128
|
+
key: "setOperator",
|
|
129
|
+
value: function setOperator(operator) {
|
|
130
|
+
this.operator = operator;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
/**
|
|
134
|
+
* Returns The threshold value that was used for the condition evaluation.
|
|
135
|
+
* @return {}
|
|
136
|
+
*/
|
|
137
|
+
}, {
|
|
138
|
+
key: "getThresholdValue",
|
|
139
|
+
value: function getThresholdValue() {
|
|
140
|
+
return this.thresholdValue;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
/**
|
|
144
|
+
* Sets The threshold value that was used for the condition evaluation.
|
|
145
|
+
* @param {} thresholdValue The threshold value that was used for the condition evaluation.
|
|
146
|
+
*/
|
|
147
|
+
}, {
|
|
148
|
+
key: "setThresholdValue",
|
|
149
|
+
value: function setThresholdValue(thresholdValue) {
|
|
150
|
+
this.thresholdValue = thresholdValue;
|
|
151
|
+
}
|
|
152
|
+
}, {
|
|
153
|
+
key: "get$Reserved",
|
|
154
|
+
value: function get$Reserved() {
|
|
155
|
+
return this.$reserved;
|
|
156
|
+
}
|
|
157
|
+
}, {
|
|
158
|
+
key: "get$ObjectType",
|
|
159
|
+
value: function get$ObjectType() {
|
|
160
|
+
return this.$objectType;
|
|
161
|
+
}
|
|
162
|
+
}, {
|
|
163
|
+
key: "get$UnknownFields",
|
|
164
|
+
value: function get$UnknownFields() {
|
|
165
|
+
return this.$unknownFields;
|
|
166
|
+
}
|
|
167
|
+
}, {
|
|
168
|
+
key: "toJson",
|
|
169
|
+
value: function toJson(forMutation) {
|
|
170
|
+
if (forMutation === false) {
|
|
171
|
+
return _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, typeof this.getMetricName() !== 'undefined' && this.getMetricName() !== null ? {
|
|
172
|
+
'metricName': this.getMetricName()
|
|
173
|
+
} : {}), typeof this.getOperator() !== 'undefined' && this.getOperator() !== null ? {
|
|
174
|
+
'operator': this.getOperator()
|
|
175
|
+
} : {}), typeof this.getThresholdValue() !== 'undefined' && this.getThresholdValue() !== null ? {
|
|
176
|
+
'thresholdValue': typeof this.getThresholdValue().toJson !== "undefined" ? this.getThresholdValue().toJson(false) : Array.isArray(this.getThresholdValue()) ? this.getThresholdValue().map(function (item) {
|
|
177
|
+
return typeof item.toJson !== "undefined" ? item.toJson(false) : item;
|
|
178
|
+
}) : _assertClassBrand(_Condition_brand, this, _toJsonMapType).call(this, this.getThresholdValue(), false)
|
|
179
|
+
} : {}), {}, {
|
|
180
|
+
'$reserved': this.get$Reserved(),
|
|
181
|
+
'$objectType': this.get$ObjectType(),
|
|
182
|
+
'$unknownFields': this.get$UnknownFields()
|
|
183
|
+
});
|
|
184
|
+
}
|
|
185
|
+
return _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, typeof this.getMetricName() !== 'undefined' && this.getMetricName() !== null ? {
|
|
186
|
+
'metricName': this.getMetricName()
|
|
187
|
+
} : {}), typeof this.getOperator() !== 'undefined' && this.getOperator() !== null ? {
|
|
188
|
+
'operator': this.getOperator()
|
|
189
|
+
} : {}), typeof this.getThresholdValue() !== 'undefined' && this.getThresholdValue() !== null ? {
|
|
190
|
+
'thresholdValue': typeof this.getThresholdValue().toJson !== "undefined" ? this.getThresholdValue().toJson() : Array.isArray(this.getThresholdValue()) ? this.getThresholdValue().map(function (item) {
|
|
191
|
+
return typeof item.toJson !== "undefined" ? item.toJson() : item;
|
|
192
|
+
}) : _assertClassBrand(_Condition_brand, this, _toJsonMapType).call(this, this.getThresholdValue())
|
|
193
|
+
} : {}), {}, {
|
|
194
|
+
'$reserved': this.get$Reserved(),
|
|
195
|
+
'$objectType': this.get$ObjectType(),
|
|
196
|
+
'$unknownFields': this.get$UnknownFields()
|
|
197
|
+
});
|
|
198
|
+
}
|
|
199
|
+
}, {
|
|
200
|
+
key: "validate",
|
|
201
|
+
value: function validate(scope, properties) {
|
|
202
|
+
var _this = this;
|
|
203
|
+
var propList = [];
|
|
204
|
+
if (arguments.length === 0 || arguments.length === 1 && arguments[0] instanceof _ValidationScopes["default"]) {
|
|
205
|
+
//cases validate() and validate(scope)
|
|
206
|
+
propList = ["metricName", "operator", "thresholdValue"];
|
|
207
|
+
} else if (arguments.length === 1) {
|
|
208
|
+
//case validate(properties)
|
|
209
|
+
propList = arguments[0];
|
|
210
|
+
scope = null;
|
|
211
|
+
} else {
|
|
212
|
+
//case validate(scope, properties)
|
|
213
|
+
propList = arguments[1];
|
|
214
|
+
}
|
|
215
|
+
var res = [];
|
|
216
|
+
var err = null;
|
|
217
|
+
propList.forEach(function (property) {
|
|
218
|
+
err = _this.validateProperty(property, scope);
|
|
219
|
+
if (err) {
|
|
220
|
+
res.push(err);
|
|
221
|
+
}
|
|
222
|
+
});
|
|
223
|
+
return new Promise(function (resolve, reject) {
|
|
224
|
+
if (res.length !== 0) {
|
|
225
|
+
reject(err);
|
|
226
|
+
} else {
|
|
227
|
+
resolve();
|
|
228
|
+
}
|
|
229
|
+
});
|
|
230
|
+
}
|
|
231
|
+
}, {
|
|
232
|
+
key: "validateProperty",
|
|
233
|
+
value: function validateProperty(scope, property) {
|
|
234
|
+
if (property === "metricName") {
|
|
235
|
+
if (typeof this.metricName === 'undefined' || this.metricName === null) {
|
|
236
|
+
return new _ValidationError["default"]("metricName", "undefined or null");
|
|
237
|
+
}
|
|
238
|
+
if (!_ValidationUtils["default"].validateMaxLength(this.metricName, 150)) {
|
|
239
|
+
return new _ValidationError["default"]("metricName", "does not satisfy required maxLength constraint: 150");
|
|
240
|
+
}
|
|
241
|
+
if (!_ValidationUtils["default"].validateMinLength(this.metricName, 1)) {
|
|
242
|
+
return new _ValidationError["default"]("metricName", "does not satisfy required minLength constraint: 1");
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
if (property === "operator") {
|
|
246
|
+
if (typeof this.operator === 'undefined' || this.operator === null) {
|
|
247
|
+
return new _ValidationError["default"]("operator", "undefined or null");
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
if (property === "thresholdValue") {
|
|
251
|
+
if (typeof this.thresholdValue === 'undefined' || this.thresholdValue === null) {
|
|
252
|
+
return new _ValidationError["default"]("thresholdValue", "undefined or null");
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
if (property === "$reserved") {
|
|
256
|
+
if (typeof this.$reserved === 'undefined' || this.$reserved === null) {
|
|
257
|
+
return new _ValidationError["default"]("$reserved", "undefined or null");
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
if (property === "$objectType") {
|
|
261
|
+
if (typeof this.$objectType === 'undefined' || this.$objectType === null) {
|
|
262
|
+
return new _ValidationError["default"]("$objectType", "undefined or null");
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
if (property === "$unknownFields") {
|
|
266
|
+
if (typeof this.$unknownFields === 'undefined' || this.$unknownFields === null) {
|
|
267
|
+
return new _ValidationError["default"]("$unknownFields", "undefined or null");
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
return new _ValidationError["default"](property, "no such property exists");
|
|
271
|
+
}
|
|
272
|
+
}], [{
|
|
273
|
+
key: "constructFromObject",
|
|
274
|
+
value: function constructFromObject(data, obj) {
|
|
275
|
+
var callFromChild = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
|
|
276
|
+
var items, item, i, itemArr, discriminator;
|
|
277
|
+
if (data) {
|
|
278
|
+
obj = obj || new Condition();
|
|
279
|
+
if (data.hasOwnProperty('metricName') && data.metricName !== null && data.metricName !== undefined) {
|
|
280
|
+
obj.setMetricName(data['metricName']);
|
|
281
|
+
}
|
|
282
|
+
if (data.hasOwnProperty('operator') && data.operator !== null && data.operator !== undefined) {
|
|
283
|
+
obj.setOperator(_ComparisonOperator["default"].constructFromObject(data['operator']));
|
|
284
|
+
}
|
|
285
|
+
if (data.hasOwnProperty('thresholdValue') && data.thresholdValue !== null && data.thresholdValue !== undefined) {
|
|
286
|
+
if (data['thresholdValue'].hasOwnProperty('$objectType')) {
|
|
287
|
+
discriminator = data['thresholdValue']['$objectType'];
|
|
288
|
+
} else {
|
|
289
|
+
discriminator = _typeof(data['thresholdValue']);
|
|
290
|
+
}
|
|
291
|
+
switch (discriminator) {
|
|
292
|
+
case 'monitoring.v4.common.DoubleValue':
|
|
293
|
+
obj.setThresholdValue(_DoubleValue["default"].constructFromObject(data['thresholdValue'], undefined));
|
|
294
|
+
break;
|
|
295
|
+
case 'monitoring.v4.common.IntValue':
|
|
296
|
+
obj.setThresholdValue(_IntValue["default"].constructFromObject(data['thresholdValue'], undefined));
|
|
297
|
+
break;
|
|
298
|
+
default:
|
|
299
|
+
throw "Unknown datatype " + discriminator + " in data";
|
|
300
|
+
}
|
|
301
|
+
}
|
|
302
|
+
if (data.hasOwnProperty('$reserved')) {
|
|
303
|
+
obj.$reserved = data['$reserved'];
|
|
304
|
+
}
|
|
305
|
+
if (data.hasOwnProperty('$objectType')) {
|
|
306
|
+
obj.$objectType = data['$objectType'];
|
|
307
|
+
}
|
|
308
|
+
if (data.hasOwnProperty('$unknownFields')) {
|
|
309
|
+
obj.$unknownFields = data['$unknownFields'];
|
|
310
|
+
}
|
|
311
|
+
if (!callFromChild) {
|
|
312
|
+
obj.$unknownFields = _objectSpread({}, data.$unknownFields);
|
|
313
|
+
for (var property in data) {
|
|
314
|
+
if (!Object.keys(obj).includes(property) && !(property[0] === "$" && property.endsWith("ItemDiscriminator"))) {
|
|
315
|
+
obj.$unknownFields[property] = data[property];
|
|
316
|
+
}
|
|
317
|
+
}
|
|
318
|
+
}
|
|
319
|
+
}
|
|
320
|
+
return obj;
|
|
321
|
+
}
|
|
322
|
+
}]);
|
|
323
|
+
}();
|
|
324
|
+
/**
|
|
325
|
+
* The metric key. Allowed values of metrics list can be found at https://portal.nutanix.com/page/documents/details?targetId=Prism-Central-Guide-vpc_2022_9:mul-alerts-user-created-metrics-r.html
|
|
326
|
+
* @memberof Condition
|
|
327
|
+
*/
|
|
328
|
+
function _toJsonMapType(obj, forMutation) {
|
|
329
|
+
if (obj instanceof Map) {
|
|
330
|
+
return Object.fromEntries(Array.from(obj, function (_ref) {
|
|
331
|
+
var _ref2 = _slicedToArray(_ref, 2),
|
|
332
|
+
k = _ref2[0],
|
|
333
|
+
v = _ref2[1];
|
|
334
|
+
return [k, typeof v.toJson !== "undefined" ? v.toJson(forMutation) : v];
|
|
335
|
+
}));
|
|
336
|
+
} else if (_typeof(obj) === 'object' && obj != null && obj.constructor === Object) {
|
|
337
|
+
return Object.fromEntries(Array.from(Object.entries(obj), function (entry) {
|
|
338
|
+
return [entry[0], typeof entry[1].toJson !== "undefined" ? entry[1].toJson(forMutation) : entry[1]];
|
|
339
|
+
}));
|
|
340
|
+
}
|
|
341
|
+
return obj;
|
|
342
|
+
}
|
|
343
|
+
Condition.prototype.metricName = undefined;
|
|
344
|
+
|
|
345
|
+
/**
|
|
346
|
+
* @memberof Condition
|
|
347
|
+
*/
|
|
348
|
+
Condition.prototype.operator = undefined;
|
|
349
|
+
|
|
350
|
+
/**
|
|
351
|
+
* The threshold value that was used for the condition evaluation.
|
|
352
|
+
* @memberof Condition
|
|
353
|
+
*/
|
|
354
|
+
Condition.prototype.thresholdValue = undefined;
|
|
355
|
+
Condition.prototype.$reserved = undefined;
|
|
356
|
+
Condition.prototype.$objectType = undefined;
|
|
357
|
+
Condition.prototype.$unknownFields = undefined;
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The ConflictingPolicy model module.
|
|
3
|
+
* @module Ntnx/ConflictingPolicy
|
|
4
|
+
* @version 4.0.1-beta-1
|
|
5
|
+
* @class ConflictingPolicy
|
|
6
|
+
*
|
|
7
|
+
* @param { String } extId Unique UUID associated with the User-Defined Alert policy which conflicts with the given policy.
|
|
8
|
+
*/
|
|
9
|
+
export default class ConflictingPolicy {
|
|
10
|
+
/**
|
|
11
|
+
* Constructs a <code>ConflictingPolicy</code> from a plain JavaScript object, optionally creating a new instance.
|
|
12
|
+
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
|
13
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
14
|
+
* @param {module:Ntnx/ConflictingPolicy} obj Optional instance to populate.
|
|
15
|
+
* @param callFromChild {Boolean} Flag to recognise calling instance
|
|
16
|
+
* @return {module:Ntnx/ConflictingPolicy} The populated <code>ConflictingPolicy</code> instance.
|
|
17
|
+
*/
|
|
18
|
+
static constructFromObject(data: any, obj: any, callFromChild?: boolean): any;
|
|
19
|
+
/**
|
|
20
|
+
* Constructs a new <code>ConflictingPolicy</code>.
|
|
21
|
+
* Details of the policy conflicting with a given User-Defined Alert policy.
|
|
22
|
+
* @alias module:Ntnx/ConflictingPolicy
|
|
23
|
+
*
|
|
24
|
+
* @param { String } extId Unique UUID associated with the User-Defined Alert policy which conflicts with the given policy.
|
|
25
|
+
*/
|
|
26
|
+
constructor(extId: string);
|
|
27
|
+
extId: string;
|
|
28
|
+
$objectType: string;
|
|
29
|
+
$reserved: {
|
|
30
|
+
$fv: string;
|
|
31
|
+
};
|
|
32
|
+
$unknownFields: {};
|
|
33
|
+
/**
|
|
34
|
+
* Returns Unique UUID associated with the User-Defined Alert policy which conflicts with the given policy.
|
|
35
|
+
* @return {}
|
|
36
|
+
*/
|
|
37
|
+
getExtId(): any;
|
|
38
|
+
/**
|
|
39
|
+
* Sets Unique UUID associated with the User-Defined Alert policy which conflicts with the given policy.
|
|
40
|
+
* @param {} extId Unique UUID associated with the User-Defined Alert policy which conflicts with the given policy.
|
|
41
|
+
*/
|
|
42
|
+
setExtId(extId: any): void;
|
|
43
|
+
get$Reserved(): {
|
|
44
|
+
$fv: string;
|
|
45
|
+
};
|
|
46
|
+
get$ObjectType(): string;
|
|
47
|
+
get$UnknownFields(): {};
|
|
48
|
+
toJson(forMutation: any): {
|
|
49
|
+
$reserved: {
|
|
50
|
+
$fv: string;
|
|
51
|
+
};
|
|
52
|
+
$objectType: string;
|
|
53
|
+
$unknownFields: {};
|
|
54
|
+
extId?: any;
|
|
55
|
+
};
|
|
56
|
+
validate(scope: any, properties: any, ...args: any[]): Promise<any>;
|
|
57
|
+
validateProperty(scope: any, property: any): ValidationError;
|
|
58
|
+
#private;
|
|
59
|
+
}
|
|
60
|
+
import ValidationError from "../../../validation/ValidationError";
|
|
@@ -0,0 +1,250 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
var _ValidationScopes = _interopRequireDefault(require("../../../validation/ValidationScopes"));
|
|
8
|
+
var _ValidationUtils = _interopRequireDefault(require("../../../../utils/ValidationUtils"));
|
|
9
|
+
var _ValidationError = _interopRequireDefault(require("../../../validation/ValidationError"));
|
|
10
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
11
|
+
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); }
|
|
12
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
13
|
+
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."); }
|
|
14
|
+
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); }
|
|
15
|
+
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; }
|
|
16
|
+
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; } }
|
|
17
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
18
|
+
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; }
|
|
19
|
+
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; }
|
|
20
|
+
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; }
|
|
21
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
22
|
+
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); } }
|
|
23
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
24
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
25
|
+
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); }
|
|
26
|
+
function _classPrivateMethodInitSpec(obj, privateSet) { _checkPrivateRedeclaration(obj, privateSet); privateSet.add(obj); }
|
|
27
|
+
function _checkPrivateRedeclaration(obj, privateCollection) { if (privateCollection.has(obj)) { throw new TypeError("Cannot initialize the same private elements twice on an object"); } } /*
|
|
28
|
+
* Nutanix Monitoring Versioned APIs
|
|
29
|
+
*
|
|
30
|
+
* OpenAPI spec version: 4.0.1-beta-1
|
|
31
|
+
*
|
|
32
|
+
* NOTE: This class is auto generated by the Open API Dev Platform.
|
|
33
|
+
*
|
|
34
|
+
* Open API Dev Platform Codegen version: 16.8.0.7344-RELEASE
|
|
35
|
+
*
|
|
36
|
+
* Do not edit the class manually.
|
|
37
|
+
*
|
|
38
|
+
*/
|
|
39
|
+
/**
|
|
40
|
+
* The ConflictingPolicy model module.
|
|
41
|
+
* @module Ntnx/ConflictingPolicy
|
|
42
|
+
* @version 4.0.1-beta-1
|
|
43
|
+
* @class ConflictingPolicy
|
|
44
|
+
*
|
|
45
|
+
* @param { String } extId Unique UUID associated with the User-Defined Alert policy which conflicts with the given policy.
|
|
46
|
+
*/
|
|
47
|
+
var _ConflictingPolicy_brand = /*#__PURE__*/new WeakSet();
|
|
48
|
+
var ConflictingPolicy = exports["default"] = /*#__PURE__*/function () {
|
|
49
|
+
/**
|
|
50
|
+
* Constructs a new <code>ConflictingPolicy</code>.
|
|
51
|
+
* Details of the policy conflicting with a given User-Defined Alert policy.
|
|
52
|
+
* @alias module:Ntnx/ConflictingPolicy
|
|
53
|
+
*
|
|
54
|
+
* @param { String } extId Unique UUID associated with the User-Defined Alert policy which conflicts with the given policy.
|
|
55
|
+
*/
|
|
56
|
+
function ConflictingPolicy(extId) {
|
|
57
|
+
_classCallCheck(this, ConflictingPolicy);
|
|
58
|
+
/*
|
|
59
|
+
* toJson method for a map type which supports map with primitive keys and values of object types
|
|
60
|
+
* @param {Object} obj
|
|
61
|
+
* @returns {Object|Map} Returns a new transofrmed Map by calling toJson on the values if applicable.
|
|
62
|
+
* Otherwise, just returns the input object.
|
|
63
|
+
*/
|
|
64
|
+
_classPrivateMethodInitSpec(this, _ConflictingPolicy_brand);
|
|
65
|
+
this.extId = extId;
|
|
66
|
+
this.$objectType = "monitoring.v4.serviceability.ConflictingPolicy";
|
|
67
|
+
this.$reserved = {
|
|
68
|
+
'$fv': "v4.r0.b1"
|
|
69
|
+
};
|
|
70
|
+
this.$unknownFields = {};
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* Constructs a <code>ConflictingPolicy</code> from a plain JavaScript object, optionally creating a new instance.
|
|
75
|
+
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
|
76
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
77
|
+
* @param {module:Ntnx/ConflictingPolicy} obj Optional instance to populate.
|
|
78
|
+
* @param callFromChild {Boolean} Flag to recognise calling instance
|
|
79
|
+
* @return {module:Ntnx/ConflictingPolicy} The populated <code>ConflictingPolicy</code> instance.
|
|
80
|
+
*/
|
|
81
|
+
return _createClass(ConflictingPolicy, [{
|
|
82
|
+
key: "getExtId",
|
|
83
|
+
value:
|
|
84
|
+
/**
|
|
85
|
+
* Returns Unique UUID associated with the User-Defined Alert policy which conflicts with the given policy.
|
|
86
|
+
* @return {}
|
|
87
|
+
*/
|
|
88
|
+
function getExtId() {
|
|
89
|
+
return this.extId;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
/**
|
|
93
|
+
* Sets Unique UUID associated with the User-Defined Alert policy which conflicts with the given policy.
|
|
94
|
+
* @param {} extId Unique UUID associated with the User-Defined Alert policy which conflicts with the given policy.
|
|
95
|
+
*/
|
|
96
|
+
}, {
|
|
97
|
+
key: "setExtId",
|
|
98
|
+
value: function setExtId(extId) {
|
|
99
|
+
this.extId = extId;
|
|
100
|
+
}
|
|
101
|
+
}, {
|
|
102
|
+
key: "get$Reserved",
|
|
103
|
+
value: function get$Reserved() {
|
|
104
|
+
return this.$reserved;
|
|
105
|
+
}
|
|
106
|
+
}, {
|
|
107
|
+
key: "get$ObjectType",
|
|
108
|
+
value: function get$ObjectType() {
|
|
109
|
+
return this.$objectType;
|
|
110
|
+
}
|
|
111
|
+
}, {
|
|
112
|
+
key: "get$UnknownFields",
|
|
113
|
+
value: function get$UnknownFields() {
|
|
114
|
+
return this.$unknownFields;
|
|
115
|
+
}
|
|
116
|
+
}, {
|
|
117
|
+
key: "toJson",
|
|
118
|
+
value: function toJson(forMutation) {
|
|
119
|
+
if (forMutation === false) {
|
|
120
|
+
return _objectSpread(_objectSpread({}, typeof this.getExtId() !== 'undefined' && this.getExtId() !== null ? {
|
|
121
|
+
'extId': this.getExtId()
|
|
122
|
+
} : {}), {}, {
|
|
123
|
+
'$reserved': this.get$Reserved(),
|
|
124
|
+
'$objectType': this.get$ObjectType(),
|
|
125
|
+
'$unknownFields': this.get$UnknownFields()
|
|
126
|
+
});
|
|
127
|
+
}
|
|
128
|
+
return _objectSpread(_objectSpread({}, typeof this.getExtId() !== 'undefined' && this.getExtId() !== null ? {
|
|
129
|
+
'extId': this.getExtId()
|
|
130
|
+
} : {}), {}, {
|
|
131
|
+
'$reserved': this.get$Reserved(),
|
|
132
|
+
'$objectType': this.get$ObjectType(),
|
|
133
|
+
'$unknownFields': this.get$UnknownFields()
|
|
134
|
+
});
|
|
135
|
+
}
|
|
136
|
+
}, {
|
|
137
|
+
key: "validate",
|
|
138
|
+
value: function validate(scope, properties) {
|
|
139
|
+
var _this = this;
|
|
140
|
+
var propList = [];
|
|
141
|
+
if (arguments.length === 0 || arguments.length === 1 && arguments[0] instanceof _ValidationScopes["default"]) {
|
|
142
|
+
//cases validate() and validate(scope)
|
|
143
|
+
propList = ["extId"];
|
|
144
|
+
} else if (arguments.length === 1) {
|
|
145
|
+
//case validate(properties)
|
|
146
|
+
propList = arguments[0];
|
|
147
|
+
scope = null;
|
|
148
|
+
} else {
|
|
149
|
+
//case validate(scope, properties)
|
|
150
|
+
propList = arguments[1];
|
|
151
|
+
}
|
|
152
|
+
var res = [];
|
|
153
|
+
var err = null;
|
|
154
|
+
propList.forEach(function (property) {
|
|
155
|
+
err = _this.validateProperty(property, scope);
|
|
156
|
+
if (err) {
|
|
157
|
+
res.push(err);
|
|
158
|
+
}
|
|
159
|
+
});
|
|
160
|
+
return new Promise(function (resolve, reject) {
|
|
161
|
+
if (res.length !== 0) {
|
|
162
|
+
reject(err);
|
|
163
|
+
} else {
|
|
164
|
+
resolve();
|
|
165
|
+
}
|
|
166
|
+
});
|
|
167
|
+
}
|
|
168
|
+
}, {
|
|
169
|
+
key: "validateProperty",
|
|
170
|
+
value: function validateProperty(scope, property) {
|
|
171
|
+
if (property === "extId") {
|
|
172
|
+
if (typeof this.extId === 'undefined' || this.extId === null) {
|
|
173
|
+
return new _ValidationError["default"]("extId", "undefined or null");
|
|
174
|
+
}
|
|
175
|
+
if (!_ValidationUtils["default"].validatePattern(this.extId, /^[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}$/)) {
|
|
176
|
+
return new _ValidationError["default"]("extId", "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}$/");
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
if (property === "$reserved") {
|
|
180
|
+
if (typeof this.$reserved === 'undefined' || this.$reserved === null) {
|
|
181
|
+
return new _ValidationError["default"]("$reserved", "undefined or null");
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
if (property === "$objectType") {
|
|
185
|
+
if (typeof this.$objectType === 'undefined' || this.$objectType === null) {
|
|
186
|
+
return new _ValidationError["default"]("$objectType", "undefined or null");
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
if (property === "$unknownFields") {
|
|
190
|
+
if (typeof this.$unknownFields === 'undefined' || this.$unknownFields === null) {
|
|
191
|
+
return new _ValidationError["default"]("$unknownFields", "undefined or null");
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
return new _ValidationError["default"](property, "no such property exists");
|
|
195
|
+
}
|
|
196
|
+
}], [{
|
|
197
|
+
key: "constructFromObject",
|
|
198
|
+
value: function constructFromObject(data, obj) {
|
|
199
|
+
var callFromChild = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
|
|
200
|
+
var items, item, i, itemArr, discriminator;
|
|
201
|
+
if (data) {
|
|
202
|
+
obj = obj || new ConflictingPolicy();
|
|
203
|
+
if (data.hasOwnProperty('extId') && data.extId !== null && data.extId !== undefined) {
|
|
204
|
+
obj.setExtId(data['extId']);
|
|
205
|
+
}
|
|
206
|
+
if (data.hasOwnProperty('$reserved')) {
|
|
207
|
+
obj.$reserved = data['$reserved'];
|
|
208
|
+
}
|
|
209
|
+
if (data.hasOwnProperty('$objectType')) {
|
|
210
|
+
obj.$objectType = data['$objectType'];
|
|
211
|
+
}
|
|
212
|
+
if (data.hasOwnProperty('$unknownFields')) {
|
|
213
|
+
obj.$unknownFields = data['$unknownFields'];
|
|
214
|
+
}
|
|
215
|
+
if (!callFromChild) {
|
|
216
|
+
obj.$unknownFields = _objectSpread({}, data.$unknownFields);
|
|
217
|
+
for (var property in data) {
|
|
218
|
+
if (!Object.keys(obj).includes(property) && !(property[0] === "$" && property.endsWith("ItemDiscriminator"))) {
|
|
219
|
+
obj.$unknownFields[property] = data[property];
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
return obj;
|
|
225
|
+
}
|
|
226
|
+
}]);
|
|
227
|
+
}();
|
|
228
|
+
/**
|
|
229
|
+
* Unique UUID associated with the User-Defined Alert policy which conflicts with the given policy.
|
|
230
|
+
* @memberof ConflictingPolicy
|
|
231
|
+
*/
|
|
232
|
+
function _toJsonMapType(obj, forMutation) {
|
|
233
|
+
if (obj instanceof Map) {
|
|
234
|
+
return Object.fromEntries(Array.from(obj, function (_ref) {
|
|
235
|
+
var _ref2 = _slicedToArray(_ref, 2),
|
|
236
|
+
k = _ref2[0],
|
|
237
|
+
v = _ref2[1];
|
|
238
|
+
return [k, typeof v.toJson !== "undefined" ? v.toJson(forMutation) : v];
|
|
239
|
+
}));
|
|
240
|
+
} else if (_typeof(obj) === 'object' && obj != null && obj.constructor === Object) {
|
|
241
|
+
return Object.fromEntries(Array.from(Object.entries(obj), function (entry) {
|
|
242
|
+
return [entry[0], typeof entry[1].toJson !== "undefined" ? entry[1].toJson(forMutation) : entry[1]];
|
|
243
|
+
}));
|
|
244
|
+
}
|
|
245
|
+
return obj;
|
|
246
|
+
}
|
|
247
|
+
ConflictingPolicy.prototype.extId = undefined;
|
|
248
|
+
ConflictingPolicy.prototype.$reserved = undefined;
|
|
249
|
+
ConflictingPolicy.prototype.$objectType = undefined;
|
|
250
|
+
ConflictingPolicy.prototype.$unknownFields = undefined;
|