/** * <p> * Specifies whether the rule is enabled or disabled. * </p> * <p> * If the service returns an enum value that is not available in the current SDK version, {@link #state} will return * {@link RuleState#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #stateAsString}. * </p> * * @return Specifies whether the rule is enabled or disabled. * @see RuleState */ public RuleState state() { return RuleState.fromValue(state); }
/** * Use this in place of valueOf to convert the raw string returned by the service into the enum value. * * @param value * real value * @return RuleState corresponding to the value */ public static RuleState fromValue(String value) { if (value == null) { return null; } return Stream.of(RuleState.values()).filter(e -> e.toString().equals(value)).findFirst().orElse(UNKNOWN_TO_SDK_VERSION); }
@Override public final Builder state(RuleState state) { this.state(state.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 RuleState}s */ public static Set<RuleState> knownValues() { return Stream.of(values()).filter(v -> v != UNKNOWN_TO_SDK_VERSION).collect(toSet()); } }
/** * Use this in place of valueOf to convert the raw string returned by the service into the enum value. * * @param value * real value * @return RuleState corresponding to the value */ public static RuleState fromValue(String value) { if (value == null) { return null; } return Stream.of(RuleState.values()).filter(e -> e.toString().equals(value)).findFirst().orElse(UNKNOWN_TO_SDK_VERSION); }
@Override public final Builder state(RuleState state) { this.state(state.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 RuleState}s */ public static Set<RuleState> knownValues() { return Stream.of(values()).filter(v -> v != UNKNOWN_TO_SDK_VERSION).collect(toSet()); } }
/** * Use this in place of valueOf to convert the raw string returned by the service into the enum value. * * @param value * real value * @return RuleState corresponding to the value */ public static RuleState fromValue(String value) { if (value == null) { return null; } return Stream.of(RuleState.values()).filter(e -> e.toString().equals(value)).findFirst().orElse(UNKNOWN_TO_SDK_VERSION); }
@Override public final Builder state(RuleState state) { this.state(state.toString()); return this; }
/** * <p> * The state of the rule. * </p> * <p> * If the service returns an enum value that is not available in the current SDK version, {@link #state} will return * {@link RuleState#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #stateAsString}. * </p> * * @return The state of the rule. * @see RuleState */ public RuleState state() { return RuleState.fromValue(state); }
/** * 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 RuleState}s */ public static Set<RuleState> knownValues() { return Stream.of(values()).filter(v -> v != UNKNOWN_TO_SDK_VERSION).collect(toSet()); } }
@Override public final Builder state(RuleState state) { this.state(state.toString()); return this; }
/** * <p> * Indicates whether the rule is enabled or disabled. * </p> * <p> * If the service returns an enum value that is not available in the current SDK version, {@link #state} will return * {@link RuleState#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #stateAsString}. * </p> * * @return Indicates whether the rule is enabled or disabled. * @see RuleState */ public RuleState state() { return RuleState.fromValue(state); }
@Override public final Builder state(RuleState state) { this.state(state.toString()); return this; }
/** * <p> * Specifies whether the rule is enabled or disabled. * </p> * <p> * If the service returns an enum value that is not available in the current SDK version, {@link #state} will return * {@link RuleState#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #stateAsString}. * </p> * * @return Specifies whether the rule is enabled or disabled. * @see RuleState */ public RuleState state() { return RuleState.fromValue(state); }
@Override public final Builder state(RuleState state) { this.state(state.toString()); return this; }
/** * <p> * The state of the rule. * </p> * <p> * If the service returns an enum value that is not available in the current SDK version, {@link #state} will return * {@link RuleState#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #stateAsString}. * </p> * * @return The state of the rule. * @see RuleState */ public RuleState state() { return RuleState.fromValue(state); }
@Override public final Builder state(RuleState state) { this.state(state.toString()); return this; }
/** * <p> * Indicates whether the rule is enabled or disabled. * </p> * <p> * If the service returns an enum value that is not available in the current SDK version, {@link #state} will return * {@link RuleState#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #stateAsString}. * </p> * * @return Indicates whether the rule is enabled or disabled. * @see RuleState */ public RuleState state() { return RuleState.fromValue(state); }
@Override public final Builder state(RuleState state) { this.state(state.toString()); return this; }