/** * <p> * The status of the returned data. <code>Complete</code> indicates that all data points in the requested time range * were returned. <code>PartialData</code> means that an incomplete set of data points were returned. You can use * the <code>NextToken</code> value that was returned and repeat your request to get more data points. * <code>NextToken</code> is not returned if you are performing a math expression. <code>InternalError</code> * indicates that an error occurred. Retry your request using <code>NextToken</code>, if present. * </p> * <p> * If the service returns an enum value that is not available in the current SDK version, {@link #statusCode} will * return {@link StatusCode#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #statusCodeAsString}. * </p> * * @return The status of the returned data. <code>Complete</code> indicates that all data points in the requested * time range were returned. <code>PartialData</code> means that an incomplete set of data points were * returned. You can use the <code>NextToken</code> value that was returned and repeat your request to get * more data points. <code>NextToken</code> is not returned if you are performing a math expression. * <code>InternalError</code> indicates that an error occurred. Retry your request using * <code>NextToken</code>, if present. * @see StatusCode */ public StatusCode statusCode() { return StatusCode.fromValue(statusCode); }
/** * Use this in place of valueOf to convert the raw string returned by the service into the enum value. * * @param value * real value * @return StatusCode corresponding to the value */ public static StatusCode fromValue(String value) { if (value == null) { return null; } return Stream.of(StatusCode.values()).filter(e -> e.toString().equals(value)).findFirst().orElse(UNKNOWN_TO_SDK_VERSION); }
/** * Use this in place of {@link #values()} to return a {@link Set} of all values known to the SDK. This will return * all known enum values except {@link #UNKNOWN_TO_SDK_VERSION}. * * @return a {@link Set} of known {@link StatusCode}s */ public static Set<StatusCode> knownValues() { return Stream.of(values()).filter(v -> v != UNKNOWN_TO_SDK_VERSION).collect(toSet()); } }
@Override public final Builder statusCode(StatusCode statusCode) { this.statusCode(statusCode.toString()); return this; }
/** * Use this in place of {@link #values()} to return a {@link Set} of all values known to the SDK. This will return * all known enum values except {@link #UNKNOWN_TO_SDK_VERSION}. * * @return a {@link Set} of known {@link StatusCode}s */ public static Set<StatusCode> knownValues() { return Stream.of(values()).filter(v -> v != UNKNOWN_TO_SDK_VERSION).collect(toSet()); } }
@Override public final Builder statusCode(StatusCode statusCode) { this.statusCode(statusCode.toString()); return this; }
/** * Use this in place of valueOf to convert the raw string returned by the service into the enum value. * * @param value * real value * @return StatusCode corresponding to the value */ public static StatusCode fromValue(String value) { if (value == null) { return null; } return Stream.of(StatusCode.values()).filter(e -> e.toString().equals(value)).findFirst().orElse(UNKNOWN_TO_SDK_VERSION); }
/** * <p> * The status of the returned data. <code>Complete</code> indicates that all data points in the requested time range * were returned. <code>PartialData</code> means that an incomplete set of data points were returned. You can use * the <code>NextToken</code> value that was returned and repeat your request to get more data points. * <code>NextToken</code> is not returned if you are performing a math expression. <code>InternalError</code> * indicates that an error occurred. Retry your request using <code>NextToken</code>, if present. * </p> * <p> * If the service returns an enum value that is not available in the current SDK version, {@link #statusCode} will * return {@link StatusCode#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #statusCodeAsString}. * </p> * * @return The status of the returned data. <code>Complete</code> indicates that all data points in the requested * time range were returned. <code>PartialData</code> means that an incomplete set of data points were * returned. You can use the <code>NextToken</code> value that was returned and repeat your request to get * more data points. <code>NextToken</code> is not returned if you are performing a math expression. * <code>InternalError</code> indicates that an error occurred. Retry your request using * <code>NextToken</code>, if present. * @see StatusCode */ public StatusCode statusCode() { return StatusCode.fromValue(statusCode); }