@Dependent public class ScenarioSimulationEditorPresenter extends Object
| Modifier and Type | Field and Description |
|---|---|
protected ScenarioSimulationContext |
context |
protected DataManagementStrategy |
dataManagementStrategy |
protected com.google.gwt.event.shared.EventBus |
eventBus |
static String |
IDENTIFIER |
protected SimulationRunResult |
lastRunResult |
protected org.drools.scenariosimulation.api.model.ScenarioSimulationModel |
model |
protected String |
packageName |
protected org.uberfire.backend.vfs.ObservablePath |
path |
protected org.uberfire.client.mvp.PlaceManager |
placeManager |
protected ScenarioGridPanel |
scenarioGridPanel |
protected long |
scenarioPresenterId |
protected TestRunnerReportingPanelWrapper |
testRunnerReportingPanel |
| Constructor and Description |
|---|
ScenarioSimulationEditorPresenter() |
ScenarioSimulationEditorPresenter(ScenarioSimulationProducer scenarioSimulationProducer,
ScenarioSimulationResourceType type,
org.uberfire.client.mvp.PlaceManager placeManager,
TestRunnerReportingPanelWrapper testRunnerReportingPanel,
ScenarioSimulationDocksHandler scenarioSimulationDocksHandler,
org.uberfire.ext.editor.commons.client.file.exports.TextFileExport textFileExport,
ConfirmPopupPresenter confirmPopupPresenter) |
| Modifier and Type | Method and Description |
|---|---|
void |
addCommonActions(org.kie.workbench.common.widgets.client.menu.FileMenuBuilder fileMenuBuilder,
org.uberfire.workbench.model.menu.MenuItem versionMenuItem,
org.uberfire.workbench.model.menu.MenuItem alertsButtonMenuItem) |
void |
addDownloadMenuItem(org.kie.workbench.common.widgets.client.menu.FileMenuBuilder fileMenuBuilder,
Supplier<org.uberfire.backend.vfs.Path> pathSupplier) |
protected void |
cleanReadOnlyColumn(org.drools.scenariosimulation.api.model.Simulation simulation)
Read only columns should not contains any values
|
protected void |
clearTestToolsStatus() |
void |
expandToolsDock() |
protected Optional<CheatSheetView.Presenter> |
getCheatSheetPresenter(org.uberfire.mvp.PlaceRequest placeRequest) |
Supplier<org.drools.scenariosimulation.api.model.ScenarioSimulationModel> |
getContentSupplier() |
ScenarioSimulationContext |
getContext() |
protected Optional<CoverageReportView.Presenter> |
getCoverageReportPresenter(org.uberfire.mvp.PlaceRequest placeRequest) |
protected org.uberfire.mvp.PlaceRequest |
getCurrentRightDockPlaceRequest(String identifier)
Returns a
PlaceRequest for the status of the right dock with the given identifier
relative to the current instance of ScenarioSimulationEditorPresenter |
DataManagementStrategy |
getDataManagementStrategy() |
com.google.gwt.event.shared.EventBus |
getEventBus() |
protected org.jboss.errai.common.client.api.RemoteCallback<Object> |
getExportCallBack() |
protected String |
getFileDownloadURL(Supplier<org.uberfire.backend.vfs.Path> pathSupplier) |
protected org.jboss.errai.common.client.api.RemoteCallback<org.drools.scenariosimulation.api.model.Simulation> |
getImportCallBack() |
protected org.jboss.errai.common.client.api.ErrorCallback<Object> |
getImportErrorCallback() |
String |
getJsonModel(org.drools.scenariosimulation.api.model.ScenarioSimulationModel model) |
org.drools.scenariosimulation.api.model.ScenarioSimulationModel |
getModel() |
void |
getModelSuccessCallbackMethod(DataManagementStrategy dataManagementStrategy,
org.drools.scenariosimulation.api.model.ScenarioSimulationModel model) |
org.uberfire.mvp.Command |
getPopulateTestToolsCommand() |
protected org.jboss.errai.common.client.api.RemoteCallback<SimulationRunResult> |
getRefreshModelCallback() |
protected org.uberfire.mvp.Command |
getSaveCommand() |
protected Optional<SettingsView.Presenter> |
getSettingsPresenter(org.uberfire.mvp.PlaceRequest placeRequest) |
protected Optional<TestToolsView.Presenter> |
getTestToolsPresenter(org.uberfire.mvp.PlaceRequest placeRequest) |
ScenarioSimulationResourceType |
getType() |
ScenarioSimulationView |
getView() |
void |
hideDocks() |
void |
init(ScenarioSimulationEditorWrapper scenarioSimulationEditorWrapper,
org.uberfire.backend.vfs.ObservablePath path) |
boolean |
isDirty() |
protected boolean |
isUberfireDocksInteractionEventToManage(org.uberfire.client.workbench.docks.UberfireDocksInteractionEvent uberfireDocksInteractionEvent)
Method to verify if the given
UberfireDocksInteractionEvent is to be processed by current instance. |
void |
loadContent() |
void |
makeMenuBar(org.kie.workbench.common.widgets.client.menu.FileMenuBuilder fileMenuBuilder)
If you want to customize the menu override this method.
|
void |
onClose() |
protected void |
onDownload(Supplier<org.uberfire.backend.vfs.Path> pathSupplier) |
protected void |
onExportToCsv() |
void |
onImport(String fileContents) |
void |
onRedo() |
void |
onRunScenario() |
void |
onRunScenario(List<Integer> indexOfScenarioToRun) |
void |
onUberfireDocksInteractionEvent(org.uberfire.client.workbench.docks.UberfireDocksInteractionEvent uberfireDocksInteractionEvent) |
void |
onUndo() |
protected void |
open(String downloadURL) |
void |
populateRightDocks(String identifier) |
protected void |
refreshModelContent(SimulationRunResult newData) |
protected void |
registerTestToolsCallback() |
void |
reloadTestTools(boolean disable)
To be called to force test tools panel reload
|
protected void |
resetDocks()
It resets the status of all Docks widgets present in ScenarioSimulation.
|
protected void |
setCheatSheet(CheatSheetView.Presenter presenter) |
protected void |
setCoverageReport(CoverageReportView.Presenter presenter) |
void |
setPackageName(String packageName) |
void |
setRedoButtonEnabledStatus(boolean enabled) |
protected void |
setSettings(SettingsView.Presenter presenter) |
protected void |
setTestTools(TestToolsView.Presenter presenter) |
void |
setUndoButtonEnabledStatus(boolean enabled) |
void |
showDocks(org.uberfire.client.mvp.PlaceStatus status) |
protected void |
showImportDialog() |
protected void |
unRegisterTestToolsCallback() |
public static final String IDENTIFIER
protected String packageName
protected org.uberfire.backend.vfs.ObservablePath path
protected com.google.gwt.event.shared.EventBus eventBus
protected ScenarioGridPanel scenarioGridPanel
protected org.uberfire.client.mvp.PlaceManager placeManager
protected DataManagementStrategy dataManagementStrategy
protected ScenarioSimulationContext context
protected org.drools.scenariosimulation.api.model.ScenarioSimulationModel model
protected TestRunnerReportingPanelWrapper testRunnerReportingPanel
protected SimulationRunResult lastRunResult
protected long scenarioPresenterId
public ScenarioSimulationEditorPresenter()
@Inject public ScenarioSimulationEditorPresenter(ScenarioSimulationProducer scenarioSimulationProducer, ScenarioSimulationResourceType type, org.uberfire.client.mvp.PlaceManager placeManager, TestRunnerReportingPanelWrapper testRunnerReportingPanel, ScenarioSimulationDocksHandler scenarioSimulationDocksHandler, org.uberfire.ext.editor.commons.client.file.exports.TextFileExport textFileExport, ConfirmPopupPresenter confirmPopupPresenter)
public void init(ScenarioSimulationEditorWrapper scenarioSimulationEditorWrapper, org.uberfire.backend.vfs.ObservablePath path)
public void setPackageName(String packageName)
public void onClose()
public void showDocks(org.uberfire.client.mvp.PlaceStatus status)
status - PlaceStatus of TestToolsPresenterpublic void hideDocks()
public void onUberfireDocksInteractionEvent(@Observes
org.uberfire.client.workbench.docks.UberfireDocksInteractionEvent uberfireDocksInteractionEvent)
public void expandToolsDock()
public ScenarioSimulationView getView()
public org.drools.scenariosimulation.api.model.ScenarioSimulationModel getModel()
public org.uberfire.mvp.Command getPopulateTestToolsCommand()
public void reloadTestTools(boolean disable)
disable - set this to true to also disable the panelpublic void onRunScenario()
public void onUndo()
public void onRedo()
public void setUndoButtonEnabledStatus(boolean enabled)
public void setRedoButtonEnabledStatus(boolean enabled)
public void addDownloadMenuItem(org.kie.workbench.common.widgets.client.menu.FileMenuBuilder fileMenuBuilder,
Supplier<org.uberfire.backend.vfs.Path> pathSupplier)
public DataManagementStrategy getDataManagementStrategy()
public void onImport(String fileContents)
public com.google.gwt.event.shared.EventBus getEventBus()
public ScenarioSimulationContext getContext()
protected void resetDocks()
protected boolean isUberfireDocksInteractionEventToManage(org.uberfire.client.workbench.docks.UberfireDocksInteractionEvent uberfireDocksInteractionEvent)
UberfireDocksInteractionEvent is to be processed by current instance.uberfireDocksInteractionEvent - true if UberfireDocksInteractionEvent.getTargetDock() != null and
the scesimpath parameter of UberfireDocksInteractionEvent.getTargetDock().getPlaceRequest()
is equals to the path (toString) of the current instance; false otherwiseprotected org.jboss.errai.common.client.api.RemoteCallback<SimulationRunResult> getRefreshModelCallback()
protected void refreshModelContent(SimulationRunResult newData)
protected void registerTestToolsCallback()
protected void unRegisterTestToolsCallback()
protected org.jboss.errai.common.client.api.ErrorCallback<Object> getImportErrorCallback()
public void makeMenuBar(org.kie.workbench.common.widgets.client.menu.FileMenuBuilder fileMenuBuilder)
fileMenuBuilder - public Supplier<org.drools.scenariosimulation.api.model.ScenarioSimulationModel> getContentSupplier()
public void addCommonActions(org.kie.workbench.common.widgets.client.menu.FileMenuBuilder fileMenuBuilder,
org.uberfire.workbench.model.menu.MenuItem versionMenuItem,
org.uberfire.workbench.model.menu.MenuItem alertsButtonMenuItem)
public void loadContent()
public boolean isDirty()
protected void onDownload(Supplier<org.uberfire.backend.vfs.Path> pathSupplier)
protected void open(String downloadURL)
protected void showImportDialog()
protected void onExportToCsv()
protected org.jboss.errai.common.client.api.RemoteCallback<Object> getExportCallBack()
protected org.jboss.errai.common.client.api.RemoteCallback<org.drools.scenariosimulation.api.model.Simulation> getImportCallBack()
protected void cleanReadOnlyColumn(org.drools.scenariosimulation.api.model.Simulation simulation)
simulation - public void populateRightDocks(String identifier)
public void getModelSuccessCallbackMethod(DataManagementStrategy dataManagementStrategy, org.drools.scenariosimulation.api.model.ScenarioSimulationModel model)
public ScenarioSimulationResourceType getType()
protected void setTestTools(TestToolsView.Presenter presenter)
protected void clearTestToolsStatus()
protected void setCheatSheet(CheatSheetView.Presenter presenter)
protected void setSettings(SettingsView.Presenter presenter)
protected void setCoverageReport(CoverageReportView.Presenter presenter)
public String getJsonModel(org.drools.scenariosimulation.api.model.ScenarioSimulationModel model)
protected Optional<CheatSheetView.Presenter> getCheatSheetPresenter(org.uberfire.mvp.PlaceRequest placeRequest)
protected Optional<TestToolsView.Presenter> getTestToolsPresenter(org.uberfire.mvp.PlaceRequest placeRequest)
protected Optional<SettingsView.Presenter> getSettingsPresenter(org.uberfire.mvp.PlaceRequest placeRequest)
protected Optional<CoverageReportView.Presenter> getCoverageReportPresenter(org.uberfire.mvp.PlaceRequest placeRequest)
protected org.uberfire.mvp.Command getSaveCommand()
protected org.uberfire.mvp.PlaceRequest getCurrentRightDockPlaceRequest(String identifier)
PlaceRequest for the status of the right dock with the given identifier
relative to the current instance of ScenarioSimulationEditorPresenterCopyright © 2001–2019 JBoss by Red Hat. All rights reserved.