public void actionPerformed()

in src/main/java/org/apache/openwhisk/intellij/explorer/toolwindow/action/EditActionAction.java [53:73]


    public void actionPerformed(@NotNull AnActionEvent e) {
        if (whiskAuth != null && whiskActionMetaData != null) {
            try {
                List<WhiskActionMetaData> actions = whiskActionService.getWhiskActions(whiskAuth);
                whiskActionService.getWhiskAction(whiskAuth,
                        Optional.of(whiskActionMetaData.getNamespacePath()),
                        whiskActionMetaData.getWhiskPackage(),
                        whiskActionMetaData.getName())
                        .ifPresent(action -> {
                            ActionManagerDialog dialog = new ActionManagerDialog(e.getProject(), whiskAuth, action, actions);
                            if (dialog.showAndGet()) {
                                LOG.info("ActionManagerDialog is closed");
                            }
                        });
            } catch (IOException ex) {
                final String msg = "The action cannot be loaded: " + whiskActionMetaData.getFullyQualifiedName();
                LOG.error(msg, ex);
                NOTIFIER.notify(e.getProject(), msg, NotificationType.ERROR);
            }
        }
    }