@Dependent public class ScenarioSimulationEditorKogitoWrapper extends org.kie.workbench.common.kogito.client.editor.MultiPageEditorContainerPresenter<org.drools.scenariosimulation.api.model.ScenarioSimulationModel> implements ScenarioSimulationEditorWrapper
| Modifier and Type | Field and Description |
|---|---|
protected org.kie.workbench.common.widgets.client.docks.AuthoringEditorDock |
authoringWorkbenchDocks |
protected org.uberfire.backend.vfs.Path |
currentPath |
protected static String |
DEFAULT_PACKAGE |
protected KogitoDMNService |
dmnTypeService |
protected org.kie.workbench.common.widgets.client.menu.FileMenuBuilder |
fileMenuBuilder |
protected KogitoAsyncPackageDataModelOracle |
kogitoOracle |
protected static String |
NEW_FILE_NAME |
protected org.uberfire.client.promise.Promises |
promises |
protected KogitoScenarioSimulationBuilder |
scenarioSimulationBuilder |
protected ScenarioSimulationEditorPresenter |
scenarioSimulationEditorPresenter |
protected ScenarioSimulationKogitoCreationPopupPresenter |
scenarioSimulationKogitoCreationPopupPresenter |
protected static String |
SCESIM |
protected SCESIM |
scesimContainer |
protected org.jboss.errai.ui.client.local.spi.TranslationService |
translationService |
| Constructor and Description |
|---|
ScenarioSimulationEditorKogitoWrapper() |
ScenarioSimulationEditorKogitoWrapper(ScenarioSimulationEditorPresenter scenarioSimulationEditorPresenter,
org.kie.workbench.common.widgets.client.menu.FileMenuBuilder fileMenuBuilder,
org.uberfire.client.mvp.PlaceManager placeManager,
org.kie.workbench.common.kogito.client.editor.MultiPageEditorContainerView multiPageEditorContainerView,
org.kie.workbench.common.widgets.client.docks.AuthoringEditorDock authoringWorkbenchDocks,
org.uberfire.client.promise.Promises promises,
KogitoDMNService dmnTypeService,
KogitoAsyncPackageDataModelOracle kogitoOracle,
org.jboss.errai.ui.client.local.spi.TranslationService translationService,
ScenarioSimulationKogitoCreationPopupPresenter scenarioSimulationKogitoCreationPopupPresenter,
KogitoScenarioSimulationBuilder scenarioSimulationBuilder) |
| Modifier and Type | Method and Description |
|---|---|
void |
addBackgroundPage(ScenarioGridWidget scenarioGridWidget)
This method adds specifically the Background grid and its related onFocus behavior
|
protected void |
buildMenuBar() |
protected org.uberfire.mvp.Command |
createNewFileCommand(org.uberfire.backend.vfs.Path path)
It creates the command launched when a user wants to create a new Scenario Simulation file.
|
elemental2.promise.Promise<String> |
getContent() |
protected Supplier<org.drools.scenariosimulation.api.model.ScenarioSimulationModel> |
getContentSupplier() |
org.uberfire.backend.vfs.Path |
getCurrentPath() |
org.kie.workbench.common.widgets.client.menu.FileMenuBuilder |
getFileMenuBuilder() |
protected SCESIMMarshallCallback |
getJSInteropMarshallCallback(elemental2.promise.Promise.PromiseExecutorCallbackFn.ResolveCallbackFn<String> resolveCallbackFn) |
protected SCESIMUnmarshallCallback |
getJSInteropUnmarshallCallback() |
Integer |
getOriginalHash() |
com.google.gwt.user.client.ui.IsWidget |
getTitle() |
org.kie.workbench.common.kogito.client.editor.MultiPageEditorContainerView |
getWidget() |
void |
gotoPath(org.uberfire.backend.vfs.Path path) |
protected void |
makeMenuBar()
If you want to customize the menu override this method.
|
protected void |
manageContent(String fullPath,
String content,
elemental2.promise.Promise.PromiseExecutorCallbackFn.ResolveCallbackFn<Object> success,
elemental2.promise.Promise.PromiseExecutorCallbackFn.RejectCallbackFn failure)
It manages the logic invoked in the Promise created during a
setContent() call |
protected void |
marshallContent(org.drools.scenariosimulation.api.model.ScenarioSimulationModel scenarioSimulationModel,
elemental2.promise.Promise.PromiseExecutorCallbackFn.ResolveCallbackFn<String> resolveCallbackFn) |
boolean |
mayClose() |
protected void |
onBackgroundTabSelected() |
void |
onDownloadReportToCsv(org.jboss.errai.common.client.api.RemoteCallback<Object> exportCallBack,
ScenarioSimulationHasBusyIndicatorDefaultErrorCallback scenarioSimulationHasBusyIndicatorDefaultErrorCallback,
org.drools.scenariosimulation.api.model.AuditLog auditLog) |
void |
onEditTabSelected()
This method is called when the main grid tab (Model) is focused
|
void |
onExportToCsv(org.jboss.errai.common.client.api.RemoteCallback<Object> exportCallBack,
ScenarioSimulationHasBusyIndicatorDefaultErrorCallback scenarioSimulationHasBusyIndicatorDefaultErrorCallback,
org.drools.scenariosimulation.api.model.AbstractScesimModel<? extends org.drools.scenariosimulation.api.model.AbstractScesimData> scesimModel) |
void |
onImport(String fileContents,
org.jboss.errai.common.client.api.RemoteCallback<org.drools.scenariosimulation.api.model.AbstractScesimModel> importCallBack,
org.jboss.errai.common.client.api.ErrorCallback<Object> importErrorCallback,
org.drools.scenariosimulation.api.model.AbstractScesimModel<? extends org.drools.scenariosimulation.api.model.AbstractScesimData> scesimModel) |
protected void |
onModelSuccessCallbackMethod(org.drools.scenariosimulation.api.model.ScenarioSimulationModel model) |
void |
onRunScenario(org.jboss.errai.common.client.api.RemoteCallback<SimulationRunResult> refreshModelCallback,
ScenarioSimulationHasBusyIndicatorDefaultErrorCallback scenarioSimulationHasBusyIndicatorDefaultErrorCallback,
org.drools.scenariosimulation.api.model.ScesimModelDescriptor simulationDescriptor,
org.drools.scenariosimulation.api.model.Settings settings,
List<org.drools.scenariosimulation.api.model.ScenarioWithIndex> toRun,
org.drools.scenariosimulation.api.model.Background background) |
void |
onStartup(org.uberfire.mvp.PlaceRequest place) |
void |
resetContentHash() |
void |
selectBackgroundTab() |
void |
selectSimulationTab() |
elemental2.promise.Promise |
setContent(String fullPath,
String content) |
void |
setMenus(Consumer<org.uberfire.workbench.model.menu.Menus> menusConsumer) |
protected void |
showScenarioSimulationCreationPopup(org.uberfire.backend.vfs.Path path)
It shows the
ScenarioSimulationKogitoCreationPopup given the file location, used |
protected elemental2.promise.Promise<String> |
transform(org.drools.scenariosimulation.api.model.ScenarioSimulationModel resource) |
protected void |
unmarshallContent(String toUnmarshal) |
void |
validate(org.drools.scenariosimulation.api.model.Simulation simulation,
org.drools.scenariosimulation.api.model.Settings settings,
org.jboss.errai.common.client.api.RemoteCallback<?> callback) |
void |
wrappedRegisterDock(String id,
com.google.gwt.user.client.ui.IsWidget widget) |
void |
wrappedSave(String commitMessage) |
addPage, asWidget, getSelectedTabIndex, init, isEditorTabSelected, OnClose, onEditTabUnselected, resetEditorPages, selectEditorTab, setSelectedTabdisableMenuItem, enableMenuItem, getBaseEditorView, getCurrentContentHash, getMenus, getOriginalContentHash, getPlaceManager, getPlaceRequest, isDirty, isReadOnly, setMenus, setOriginalContentHashclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitsynchronizeColumnsDimensionprotected static final String DEFAULT_PACKAGE
protected static final String NEW_FILE_NAME
protected static final String SCESIM
protected ScenarioSimulationEditorPresenter scenarioSimulationEditorPresenter
protected org.kie.workbench.common.widgets.client.menu.FileMenuBuilder fileMenuBuilder
protected org.kie.workbench.common.widgets.client.docks.AuthoringEditorDock authoringWorkbenchDocks
protected SCESIM scesimContainer
protected org.uberfire.client.promise.Promises promises
protected org.uberfire.backend.vfs.Path currentPath
protected KogitoDMNService dmnTypeService
protected KogitoAsyncPackageDataModelOracle kogitoOracle
protected org.jboss.errai.ui.client.local.spi.TranslationService translationService
protected ScenarioSimulationKogitoCreationPopupPresenter scenarioSimulationKogitoCreationPopupPresenter
protected KogitoScenarioSimulationBuilder scenarioSimulationBuilder
public ScenarioSimulationEditorKogitoWrapper()
@Inject public ScenarioSimulationEditorKogitoWrapper(ScenarioSimulationEditorPresenter scenarioSimulationEditorPresenter, org.kie.workbench.common.widgets.client.menu.FileMenuBuilder fileMenuBuilder, org.uberfire.client.mvp.PlaceManager placeManager, org.kie.workbench.common.kogito.client.editor.MultiPageEditorContainerView multiPageEditorContainerView, org.kie.workbench.common.widgets.client.docks.AuthoringEditorDock authoringWorkbenchDocks, org.uberfire.client.promise.Promises promises, KogitoDMNService dmnTypeService, KogitoAsyncPackageDataModelOracle kogitoOracle, org.jboss.errai.ui.client.local.spi.TranslationService translationService, ScenarioSimulationKogitoCreationPopupPresenter scenarioSimulationKogitoCreationPopupPresenter, KogitoScenarioSimulationBuilder scenarioSimulationBuilder)
protected void buildMenuBar()
buildMenuBar in class org.kie.workbench.common.kogito.client.editor.BaseKogitoEditor<org.drools.scenariosimulation.api.model.ScenarioSimulationModel>public elemental2.promise.Promise<String> getContent()
getContent in class org.kie.workbench.common.kogito.client.editor.BaseKogitoEditor<org.drools.scenariosimulation.api.model.ScenarioSimulationModel>public elemental2.promise.Promise setContent(String fullPath, String content)
setContent in class org.kie.workbench.common.kogito.client.editor.BaseKogitoEditor<org.drools.scenariosimulation.api.model.ScenarioSimulationModel>protected void manageContent(String fullPath, String content, elemental2.promise.Promise.PromiseExecutorCallbackFn.ResolveCallbackFn<Object> success, elemental2.promise.Promise.PromiseExecutorCallbackFn.RejectCallbackFn failure)
setContent() callfullPath - content - success - failure - public void wrappedRegisterDock(String id, com.google.gwt.user.client.ui.IsWidget widget)
wrappedRegisterDock in interface ScenarioSimulationEditorWrapperpublic void onImport(String fileContents, org.jboss.errai.common.client.api.RemoteCallback<org.drools.scenariosimulation.api.model.AbstractScesimModel> importCallBack, org.jboss.errai.common.client.api.ErrorCallback<Object> importErrorCallback, org.drools.scenariosimulation.api.model.AbstractScesimModel<? extends org.drools.scenariosimulation.api.model.AbstractScesimData> scesimModel)
onImport in interface ScenarioSimulationEditorWrapperpublic void onExportToCsv(org.jboss.errai.common.client.api.RemoteCallback<Object> exportCallBack, ScenarioSimulationHasBusyIndicatorDefaultErrorCallback scenarioSimulationHasBusyIndicatorDefaultErrorCallback, org.drools.scenariosimulation.api.model.AbstractScesimModel<? extends org.drools.scenariosimulation.api.model.AbstractScesimData> scesimModel)
onExportToCsv in interface ScenarioSimulationEditorWrapperpublic void onDownloadReportToCsv(org.jboss.errai.common.client.api.RemoteCallback<Object> exportCallBack, ScenarioSimulationHasBusyIndicatorDefaultErrorCallback scenarioSimulationHasBusyIndicatorDefaultErrorCallback, org.drools.scenariosimulation.api.model.AuditLog auditLog)
onDownloadReportToCsv in interface ScenarioSimulationEditorWrapperpublic void validate(org.drools.scenariosimulation.api.model.Simulation simulation,
org.drools.scenariosimulation.api.model.Settings settings,
org.jboss.errai.common.client.api.RemoteCallback<?> callback)
validate in interface ScenarioSimulationEditorWrapperpublic void onEditTabSelected()
onEditTabSelected in interface org.kie.workbench.common.kogito.client.editor.MultiPageEditorContainerView.PresenteronEditTabSelected in class org.kie.workbench.common.kogito.client.editor.MultiPageEditorContainerPresenter<org.drools.scenariosimulation.api.model.ScenarioSimulationModel>public void addBackgroundPage(ScenarioGridWidget scenarioGridWidget)
addBackgroundPage in interface ScenarioSimulationEditorWrapperscenarioGridWidget - public void selectSimulationTab()
selectSimulationTab in interface ScenarioSimulationEditorWrapperpublic void selectBackgroundTab()
selectBackgroundTab in interface ScenarioSimulationEditorWrapperpublic void resetContentHash()
resetContentHash in class org.kie.workbench.common.kogito.client.editor.BaseKogitoEditor<org.drools.scenariosimulation.api.model.ScenarioSimulationModel>public void onStartup(org.uberfire.mvp.PlaceRequest place)
public void gotoPath(org.uberfire.backend.vfs.Path path)
public org.uberfire.backend.vfs.Path getCurrentPath()
public boolean mayClose()
mayClose in class org.kie.workbench.common.kogito.client.editor.BaseKogitoEditor<org.drools.scenariosimulation.api.model.ScenarioSimulationModel>public com.google.gwt.user.client.ui.IsWidget getTitle()
getTitle in class org.kie.workbench.common.kogito.client.editor.BaseKogitoEditor<org.drools.scenariosimulation.api.model.ScenarioSimulationModel>public org.kie.workbench.common.kogito.client.editor.MultiPageEditorContainerView getWidget()
getWidget in class org.kie.workbench.common.kogito.client.editor.MultiPageEditorContainerPresenter<org.drools.scenariosimulation.api.model.ScenarioSimulationModel>public org.kie.workbench.common.widgets.client.menu.FileMenuBuilder getFileMenuBuilder()
public void setMenus(Consumer<org.uberfire.workbench.model.menu.Menus> menusConsumer)
public void onRunScenario(org.jboss.errai.common.client.api.RemoteCallback<SimulationRunResult> refreshModelCallback, ScenarioSimulationHasBusyIndicatorDefaultErrorCallback scenarioSimulationHasBusyIndicatorDefaultErrorCallback, org.drools.scenariosimulation.api.model.ScesimModelDescriptor simulationDescriptor, org.drools.scenariosimulation.api.model.Settings settings, List<org.drools.scenariosimulation.api.model.ScenarioWithIndex> toRun, org.drools.scenariosimulation.api.model.Background background)
onRunScenario in interface ScenarioSimulationEditorWrapperpublic void wrappedSave(String commitMessage)
wrappedSave in interface ScenarioSimulationEditorWrapperpublic Integer getOriginalHash()
getOriginalHash in interface ScenarioSimulationEditorWrapperprotected elemental2.promise.Promise<String> transform(org.drools.scenariosimulation.api.model.ScenarioSimulationModel resource)
protected void makeMenuBar()
makeMenuBar in class org.kie.workbench.common.kogito.client.editor.BaseKogitoEditor<org.drools.scenariosimulation.api.model.ScenarioSimulationModel>protected Supplier<org.drools.scenariosimulation.api.model.ScenarioSimulationModel> getContentSupplier()
getContentSupplier in class org.kie.workbench.common.kogito.client.editor.BaseKogitoEditor<org.drools.scenariosimulation.api.model.ScenarioSimulationModel>protected void marshallContent(org.drools.scenariosimulation.api.model.ScenarioSimulationModel scenarioSimulationModel,
elemental2.promise.Promise.PromiseExecutorCallbackFn.ResolveCallbackFn<String> resolveCallbackFn)
protected void unmarshallContent(String toUnmarshal)
protected SCESIMMarshallCallback getJSInteropMarshallCallback(elemental2.promise.Promise.PromiseExecutorCallbackFn.ResolveCallbackFn<String> resolveCallbackFn)
protected SCESIMUnmarshallCallback getJSInteropUnmarshallCallback()
protected void onModelSuccessCallbackMethod(org.drools.scenariosimulation.api.model.ScenarioSimulationModel model)
protected void onBackgroundTabSelected()
protected void showScenarioSimulationCreationPopup(org.uberfire.backend.vfs.Path path)
ScenarioSimulationKogitoCreationPopup given the file location, usedpath - protected org.uberfire.mvp.Command createNewFileCommand(org.uberfire.backend.vfs.Path path)
path - The part where the scesim file is locatedCommand which will be launched pressing the 'Create' new scesim file buttonCopyright © 2001–2020 JBoss by Red Hat. All rights reserved.