/** * Use this in place of valueOf. * * @param value * real value * @return AutoScalingType corresponding to the value * * @throws IllegalArgumentException * If the specified value does not map to one of the known values in this enum. */ public static AutoScalingType fromValue(String value) { if (value == null || "".equals(value)) { throw new IllegalArgumentException("Value cannot be null or empty!"); } for (AutoScalingType enumEntry : AutoScalingType.values()) { if (enumEntry.toString().equals(value)) { return enumEntry; } } throw new IllegalArgumentException("Cannot create enum from " + value + " value!"); } }
/** * <p> * For load-based or time-based instances, the type. * </p> * * @param autoScalingType * For load-based or time-based instances, the type. * @return Returns a reference to this object so that method calls can be chained together. * @see AutoScalingType */ public Instance withAutoScalingType(AutoScalingType autoScalingType) { this.autoScalingType = autoScalingType.toString(); return this; }
/** * Set the type of autoscaling to use for this instance. Not required. * * @param autoScalingType * The type of autoscaling to use for this instance. */ public void setAutoScalingType(String autoScalingType) { try { this.autoScalingType = AutoScalingType.valueOf(autoScalingType); } catch (IllegalArgumentException e) { throw new BuildException(e.getMessage(), e); } }
/** * <p> * For load-based or time-based instances, the type. Windows stacks can use only time-based instances. * </p> * * @param autoScalingType * For load-based or time-based instances, the type. Windows stacks can use only time-based instances. * @return Returns a reference to this object so that method calls can be chained together. * @see AutoScalingType */ public UpdateInstanceRequest withAutoScalingType(AutoScalingType autoScalingType) { this.autoScalingType = autoScalingType.toString(); return this; }
/** * Use this in place of valueOf. * * @param value * real value * @return AutoScalingType corresponding to the value * * @throws IllegalArgumentException * If the specified value does not map to one of the known values in this enum. */ public static AutoScalingType fromValue(String value) { if (value == null || "".equals(value)) { throw new IllegalArgumentException("Value cannot be null or empty!"); } for (AutoScalingType enumEntry : AutoScalingType.values()) { if (enumEntry.toString().equals(value)) { return enumEntry; } } throw new IllegalArgumentException("Cannot create enum from " + value + " value!"); } }
/** * <p> * For load-based or time-based instances, the type. Windows stacks can use only time-based instances. * </p> * * @param autoScalingType * For load-based or time-based instances, the type. Windows stacks can use only time-based instances. * @return Returns a reference to this object so that method calls can be chained together. * @see AutoScalingType */ public CreateInstanceRequest withAutoScalingType(AutoScalingType autoScalingType) { this.autoScalingType = autoScalingType.toString(); return this; }
/** * <p> * For load-based or time-based instances, the type. Windows stacks can use only time-based instances. * </p> * * @param autoScalingType * For load-based or time-based instances, the type. Windows stacks can use only time-based instances. * @return Returns a reference to this object so that method calls can be chained together. * @see AutoScalingType */ public UpdateInstanceRequest withAutoScalingType(AutoScalingType autoScalingType) { this.autoScalingType = autoScalingType.toString(); return this; }
/** * <p> * For load-based or time-based instances, the type. * </p> * * @param autoScalingType * For load-based or time-based instances, the type. * @return Returns a reference to this object so that method calls can be chained together. * @see AutoScalingType */ public Instance withAutoScalingType(AutoScalingType autoScalingType) { this.autoScalingType = autoScalingType.toString(); return this; }
/** * <p> * For load-based or time-based instances, the type. Windows stacks can use only time-based instances. * </p> * * @param autoScalingType * For load-based or time-based instances, the type. Windows stacks can use only time-based instances. * @return Returns a reference to this object so that method calls can be chained together. * @see AutoScalingType */ public CreateInstanceRequest withAutoScalingType(AutoScalingType autoScalingType) { this.autoScalingType = autoScalingType.toString(); return this; }