com.nutanix.dp1.pri.prism.v4.serviceability.AutoResolve Maven / Gradle / Ivy
/*
* Generated file ..
*
* Product version: 4.0.3-alpha-2
*
* Part of the Nutanix Prism Versioned APIs
*
* (c) 2023 Nutanix Inc. All rights reserved
*
*/
package com.nutanix.dp1.pri.prism.v4.serviceability;
import javax.validation.constraints.*;
import static com.nutanix.dp1.pri.deserializers.PriDeserializerUtils.*;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import java.util.Arrays;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.stream.Collectors;
/**
* Auto resolve status for this system defined alert policy on specified cluster.
*/
public enum AutoResolve {
$UNKNOWN,
$REDACTED,
/**
* Indicates that the alerts generated by this policy will be auto-resolved. The system will automatically resolve alerts under certain conditions such as when the system recognizes that the error has been resolved or when the initiating event has not reoccurred for 48 hours.
*/
ENABLED,
/**
* Indicates that the alerts generated by this policy will not be auto-resolved.
*/
DISABLED,
/**
* Indicates that auto-resolution of alerts generated by this policy is not supported.
*/
NOT_SUPPORTED ;
private static final Map lookup = new LinkedHashMap();
static {
lookup.put("$UNKNOWN", $UNKNOWN);
lookup.put("$REDACTED", $REDACTED);
lookup.put("ENABLED", ENABLED);
lookup.put("DISABLED", DISABLED);
lookup.put("NOT_SUPPORTED", NOT_SUPPORTED);
}
@JsonCreator
public static AutoResolve fromString(String enumTypeVar) {
return lookup.getOrDefault(enumTypeVar, AutoResolve.$UNKNOWN);
}
@JsonValue
public String fromEnum() {
for (Map.Entry entry : lookup.entrySet()) {
if (entry.getValue() == this) {
return entry.getKey();
}
}
return "$UNKNOWN";
}
}