public class ConfigurationFromContextImpl extends ConfigurationFromContext
COMPARATOR, NAME_COMPARATOR
Constructor and Description |
---|
ConfigurationFromContextImpl(RunConfigurationProducer producer,
RunnerAndConfigurationSettings settings,
PsiElement element) |
Modifier and Type | Method and Description |
---|---|
RunConfigurationProducer |
getConfigurationProducer() |
RunnerAndConfigurationSettings |
getConfigurationSettings()
Returns the created run configuration settings.
|
PsiElement |
getSourceElement()
Returns the element from which this configuration was created.
|
boolean |
isPreferredTo(ConfigurationFromContext other)
Checks if this configuration should be discarded in favor of another configuration created from the same context.
|
boolean |
isProducedBy(java.lang.Class<? extends RunConfigurationProducer> producerClass)
Checks if this configuration was created by the specified producer.
|
void |
onFirstRun(ConfigurationContext context,
java.lang.Runnable startRunnable)
Called before the configuration created from context is first executed.
|
void |
setConfigurationSettings(RunnerAndConfigurationSettings configurationSettings) |
boolean |
shouldReplace(ConfigurationFromContext other)
Checks if this configuration should replace another one, that is if the other should be discarded.
|
getAlternativeLocationDisplayName, getConfiguration, getConfigurationType, isFromAlternativeLocation, setAlternativeLocationDisplayName, setFromAlternativeLocation, toString
public ConfigurationFromContextImpl(RunConfigurationProducer producer, RunnerAndConfigurationSettings settings, PsiElement element)
public RunnerAndConfigurationSettings getConfigurationSettings()
ConfigurationFromContext
getConfigurationSettings
in class ConfigurationFromContext
public void setConfigurationSettings(RunnerAndConfigurationSettings configurationSettings)
setConfigurationSettings
in class ConfigurationFromContext
public PsiElement getSourceElement()
ConfigurationFromContext
getSourceElement
in class ConfigurationFromContext
public boolean isPreferredTo(ConfigurationFromContext other)
ConfigurationFromContext
isPreferredTo
in class ConfigurationFromContext
other
- another configuration created from the same context.public boolean shouldReplace(ConfigurationFromContext other)
ConfigurationFromContext
shouldReplace
in class ConfigurationFromContext
RunConfigurationProducer.shouldReplace(ConfigurationFromContext, ConfigurationFromContext)
public boolean isProducedBy(java.lang.Class<? extends RunConfigurationProducer> producerClass)
ConfigurationFromContext
isProducedBy
in class ConfigurationFromContext
producerClass
- the run configuration producer class.public void onFirstRun(ConfigurationContext context, java.lang.Runnable startRunnable)
ConfigurationFromContext
onFirstRun
in class ConfigurationFromContext
context
- the contextstartRunnable
- the runnable that needs to be called after additional customization is complete.public RunConfigurationProducer getConfigurationProducer()