public String getStorageAccountType() { return StringUtils.isBlank(storageAccountType) ? SkuName.STANDARD_LRS.toString() : storageAccountType; }
/** * Parses a serialized value to a SkuName instance. * * @param value the serialized value to parse. * @return the parsed SkuName object, or null if unable to parse. */ @JsonCreator public static SkuName fromString(String value) { SkuName[] items = SkuName.values(); for (SkuName item : items) { if (item.toString().equalsIgnoreCase(value)) { return item; } } return null; }
/** * Parses a serialized value to a SkuName instance. * * @param value the serialized value to parse. * @return the parsed SkuName object, or null if unable to parse. */ @JsonCreator public static SkuName fromString(String value) { SkuName[] items = SkuName.values(); for (SkuName item : items) { if (item.toString().equalsIgnoreCase(value)) { return item; } } return null; }
public ListBoxModel doFillStorageAccountTypeItems( @QueryParameter String virtualMachineSize) throws IOException, ServletException { ListBoxModel model = new ListBoxModel(); model.add("--- Select Storage Account Type ---", ""); model.add(SkuName.STANDARD_LRS.toString()); /*As introduced in Azure Docs, the size contains 'S' supports premium storage*/ if (virtualMachineSize.matches(".*_[a-zA-Z]([0-9]+[Mm]?[Ss]|[Ss][0-9]+).*")) { model.add(SkuName.PREMIUM_LRS.toString()); } return model; }
storageAccountType = SkuName.STANDARD_LRS.toString();
azureClient.storageAccounts().listByResourceGroup(resourceGroupName); for (StorageAccount storageAccount : storageAccountList) { if (storageAccount.sku().name().toString().equalsIgnoreCase(storageAccountType)) { model.add(storageAccount.name());