/** * Use this in place of valueOf. * * @param value * real value * @return AppType corresponding to the value * * @throws IllegalArgumentException * If the specified value does not map to one of the known values in this enum. */ public static AppType fromValue(String value) { if (value == null || "".equals(value)) { throw new IllegalArgumentException("Value cannot be null or empty!"); } for (AppType enumEntry : AppType.values()) { if (enumEntry.toString().equals(value)) { return enumEntry; } } throw new IllegalArgumentException("Cannot create enum from " + value + " value!"); } }
/** * <p> * The app type. * </p> * * @param type * The app type. * @return Returns a reference to this object so that method calls can be chained together. * @see AppType */ public UpdateAppRequest withType(AppType type) { this.type = type.toString(); return this; }
} else { try { AppType.valueOf(type); } catch (IllegalArgumentException e) { System.out
/** * <p> * The app type. * </p> * * @param type * The app type. * @return Returns a reference to this object so that method calls can be chained together. * @see AppType */ public App withType(AppType type) { this.type = type.toString(); return this; }
AppType.valueOf(type); } catch (IllegalArgumentException e) { System.out
/** * Use this in place of valueOf. * * @param value * real value * @return AppType corresponding to the value * * @throws IllegalArgumentException * If the specified value does not map to one of the known values in this enum. */ public static AppType fromValue(String value) { if (value == null || "".equals(value)) { throw new IllegalArgumentException("Value cannot be null or empty!"); } for (AppType enumEntry : AppType.values()) { if (enumEntry.toString().equals(value)) { return enumEntry; } } throw new IllegalArgumentException("Cannot create enum from " + value + " value!"); } }
/** * <p> * The app type. Each supported type is associated with a particular layer. For example, PHP applications are * associated with a PHP layer. AWS OpsWorks Stacks deploys an application to those instances that are members of * the corresponding layer. If your app isn't one of the standard types, or you prefer to implement your own Deploy * recipes, specify <code>other</code>. * </p> * * @param type * The app type. Each supported type is associated with a particular layer. For example, PHP applications are * associated with a PHP layer. AWS OpsWorks Stacks deploys an application to those instances that are * members of the corresponding layer. If your app isn't one of the standard types, or you prefer to * implement your own Deploy recipes, specify <code>other</code>. * @return Returns a reference to this object so that method calls can be chained together. * @see AppType */ public CreateAppRequest withType(AppType type) { this.type = type.toString(); return this; }
/** * <p> * The app type. * </p> * * @param type * The app type. * @return Returns a reference to this object so that method calls can be chained together. * @see AppType */ public UpdateAppRequest withType(AppType type) { this.type = type.toString(); return this; }
/** * <p> * The app type. * </p> * * @param type * The app type. * @return Returns a reference to this object so that method calls can be chained together. * @see AppType */ public App withType(AppType type) { this.type = type.toString(); return this; }
/** * <p> * The app type. Each supported type is associated with a particular layer. For example, PHP applications are * associated with a PHP layer. AWS OpsWorks Stacks deploys an application to those instances that are members of * the corresponding layer. If your app isn't one of the standard types, or you prefer to implement your own Deploy * recipes, specify <code>other</code>. * </p> * * @param type * The app type. Each supported type is associated with a particular layer. For example, PHP applications are * associated with a PHP layer. AWS OpsWorks Stacks deploys an application to those instances that are * members of the corresponding layer. If your app isn't one of the standard types, or you prefer to * implement your own Deploy recipes, specify <code>other</code>. * @return Returns a reference to this object so that method calls can be chained together. * @see AppType */ public CreateAppRequest withType(AppType type) { this.type = type.toString(); return this; }