class ContainerPresenter {

    public void stopContainer() {
        specManagementService.call(new RemoteCallback<Void>() {
                                       @Override
                                       public void callback(final Void response) {
                                           updateStatus(KieContainerStatus.STOPPED);
                                       }
                                   },
                                   new ErrorCallback<Object>() {
                                       @Override
                                       public boolean error(final Object o,
                                                            final Throwable throwable) {
                                           notification.fire(new NotificationEvent(view.getStopContainerErrorMessage(),
                                                                                   NotificationEvent.NotificationType.ERROR));
                                           updateStatus(KieContainerStatus.STARTED);
                                           return false;
                                       }
                                   }).stopContainer(containerSpec);
    }

    @Inject public  ContainerPresenter(final Logger logger,
                              final View view,
                              final ContainerRemoteStatusPresenter containerRemoteStatusPresenter,
                              final ContainerStatusEmptyPresenter containerStatusEmptyPresenter,
                              final ContainerProcessConfigPresenter containerProcessConfigPresenter,
                              final ContainerRulesConfigPresenter containerRulesConfigPresenter,
                              final Caller<RuntimeManagementService> runtimeManagementService,
                              final Caller<SpecManagementService> specManagementService,
                              final Event<ServerTemplateSelected> serverTemplateSelectedEvent,
                              final Event<NotificationEvent> notification);

}