public class JavaScratchConfiguration extends ApplicationConfiguration
ApplicationConfiguration.JavaApplicationCommandLineState<T extends ApplicationConfiguration>
InputRedirectAware.InputRedirectOptions, InputRedirectAware.InputRedirectOptionsImpl
RunConfiguration.RestartSingletonResult
ALTERNATIVE_JRE_PATH, ALTERNATIVE_JRE_PATH_ENABLED, MAIN_CLASS_NAME, PROGRAM_PARAMETERS, WORKING_DIRECTORY
TO_CLONE_ELEMENT_NAME
TYPES_WITH_REDIRECT_AWARE_UI
DATA_KEY
Modifier | Constructor and Description |
---|---|
protected |
JavaScratchConfiguration(java.lang.String name,
Project project,
ConfigurationFactory factory) |
Modifier and Type | Method and Description |
---|---|
void |
checkConfiguration()
Checks whether the run configuration settings are valid.
|
SettingsEditor<? extends RunConfiguration> |
getConfigurationEditor()
Returns the UI control for editing the run configuration settings.
|
protected JavaScratchConfigurationOptions |
getOptions()
Because we have to keep backward compatibility, never use `getOptions()` to get or set values - use only designated getters/setters.
|
java.lang.String |
getScratchFileUrl() |
VirtualFile |
getScratchVirtualFile() |
RunProfileState |
getState(Executor executor,
ExecutionEnvironment env)
Prepares for executing a specific instance of the run configuration.
|
boolean |
isBuildProjectOnEmptyModuleList()
Modifies behavior for the case when
RunProfileWithCompileBeforeLaunchOption.getModules() returns empty list. |
void |
setScratchFileUrl(java.lang.String url) |
canRunOn, getActionName, getAlternativeJrePath, getDefaultLanguageRuntimeType, getDefaultOptionsClass, getDefaultTargetName, getEnvs, getInputRedirectOptions, getMainClass, getMainClassName, getPackage, getProgramParameters, getRefactoringElementListener, getRunClass, getShortenCommandLine, getValidModules, getVMParameters, getWorkingDirectory, isAlternativeJrePathEnabled, isPassParentEnvs, isProvidedScopeIncluded, isSwingInspectorEnabled, onAlternativeJreChanged, readExternal, setAlternativeJrePath, setAlternativeJrePathEnabled, setDefaultTargetName, setEnvs, setIncludeProvidedScope, setMainClass, setMainClassName, setOptionsFromConfigurationFile, setPassParentEnvs, setProgramParameters, setShortenCommandLine, setSwingInspectorEnabled, setVMParameters, setWorkingDirectory, suggestedName, writeExternal
canRestoreOriginalModule, clone, createInstance, getAllModules, getConfigurationModule, getModules, getState, isModuleDirMacroSupported, loadState, onNewConfigurationCreated, readModule, restoreOriginalModule, setModule, setModuleName, syncModuleName, writeModule
isGeneratedName, setGeneratedName, setNameChangedByUser
addLogFile, addLogFile, addPredefinedLogFile, checkRunnerSettings, checkSettingsBeforeRun, collectOutputFromProcessHandler, createAdditionalTabComponents, customizeLogConsole, equals, excludeCompileBeforeLaunchOption, getAllLogFiles, getBeforeRunTasks, getFactory, getIcon, getLogFiles, getName, getOptionsClass, getOptionsForPredefinedLogFile, getOutputFilePath, getPredefinedLogFiles, getProject, hashCode, isAllowRunningInParallel, isNewSerializationUsed, isSaveOutputToFile, isShowConsoleOnStdErr, isShowConsoleOnStdOut, onConfigurationCopied, removeAllLogFiles, removeAllPredefinedLogFiles, setAllowRunningInParallel, setBeforeRunTasks, setFileOutputPath, setName, setSaveOutputToFile, setShowConsoleOnStdErr, setShowConsoleOnStdOut, toString
changeUserMap, clearUserData, copyCopyableDataTo, copyUserDataTo, getCopyableUserData, getUserData, getUserDataString, getUserMap, isUserDataEmpty, putCopyableUserData, putUserData, putUserDataIfAbsent, replace, setUserMap
finalize, getClass, notify, notifyAll, wait, wait, wait
getProject
getProject
getInputFile, getInputRedirectOptions
clone, createRunnerSettings, getBeforeRunTasks, getFactory, getId, getPresentableType, getProject, getRunnerSettingsEditor, getType, getUniqueID, hideDisabledExecutorButtons, isAllowRunningInParallel, restartSingleton, setAllowRunningInParallel, setBeforeRunTasks, setName
getIcon, getName
getSearchScope
isBuildBeforeLaunchAddedByDefault, isExcludeCompileBeforeLaunchOption
protected JavaScratchConfiguration(java.lang.String name, Project project, ConfigurationFactory factory)
public boolean isBuildProjectOnEmptyModuleList()
RunProfileWithCompileBeforeLaunchOption
RunProfileWithCompileBeforeLaunchOption.getModules()
returns empty list.
By default whole project will be built in this case.public void checkConfiguration() throws RuntimeConfigurationException
RunConfiguration
checkConfiguration
in interface RunConfiguration
checkConfiguration
in class ApplicationConfiguration
RuntimeConfigurationException
- if the configuration settings contain a non-fatal problem which the user should be warned about
but the execution should still be allowed.RuntimeConfigurationError
- if the configuration settings contain a fatal problem which makes it impossible
to execute the run configuration.public RunProfileState getState(Executor executor, ExecutionEnvironment env) throws ExecutionException
RunProfile
getState
in interface RunProfile
getState
in class ApplicationConfiguration
executor
- the execution mode selected by the user (run, debug, profile etc.)env
- the environment object containing additional settings for executing the configuration.ExecutionException
public SettingsEditor<? extends RunConfiguration> getConfigurationEditor()
RunConfiguration
CheckableRunConfigurationEditor
. The returned object
can also implement SettingsEditorGroup
if the settings it provides need to be displayed in
multiple tabs.getConfigurationEditor
in interface RunConfiguration
getConfigurationEditor
in class ApplicationConfiguration
public void setScratchFileUrl(java.lang.String url)
public java.lang.String getScratchFileUrl()
public VirtualFile getScratchVirtualFile()
protected JavaScratchConfigurationOptions getOptions()
ApplicationConfiguration
getOptions
in class ApplicationConfiguration