use of com.microsoft.azure.toolkit.lib.webapp.WebAppConfig in project azure-tools-for-java by Microsoft.
the class CreateWebAppAction method openDialog.
@AzureOperation(name = "webapp.open_creation_dialog", type = AzureOperation.Type.ACTION)
private void openDialog(final Project project, @Nullable final WebAppConfig data) {
final WebAppCreationDialog dialog = new WebAppCreationDialog(project);
if (Objects.nonNull(data)) {
dialog.setData(data);
}
dialog.setOkActionListener((config) -> {
dialog.close();
this.createWebApp(config).subscribe(webapp -> {
final Path artifact = config.getApplication();
if (Objects.nonNull(artifact) && artifact.toFile().exists()) {
AzureTaskManager.getInstance().runLater("deploy", () -> deploy(webapp, artifact, project));
}
}, (error) -> {
final String title = String.format("Reopen dialog \"%s\"", dialog.getTitle());
final Consumer<Object> act = t -> AzureTaskManager.getInstance().runLater("open dialog", () -> this.openDialog(project, config));
final Action<?> action = new Action<>(act, new ActionView.Builder(title));
AzureMessager.getMessager().error(error, null, action);
});
});
dialog.show();
}
use of com.microsoft.azure.toolkit.lib.webapp.WebAppConfig in project azure-tools-for-java by Microsoft.
the class WebAppConfigFormPanelAdvance method getData.
@Override
public WebAppConfig getData() {
final WebAppConfig data = appServiceConfigPanelAdvanced.getData();
data.setMonitorConfig(appServiceMonitorPanel.getData());
return data;
}
Aggregations