public class StrategySettingsDefinition
extends java.lang.Object
Instances of this class defines how a user interfaces has to look like which
edits StrategySettings.
The StrategySettingsDefinition itself and all its provided sub
classes are read-only.
Each StrategyFactory should provide an instance of this class to
define the user interface which the user can use to edit supported
StrategySettings in created Strategy instances. If a
StrategyFactory provides no StrategySettingsDefinition an
empty user interface or even bedder an error message should be shown to the
user.
StrategyFactory,
AbstractStrategyPropertyDefinition,
OneOfStrategyPropertyDefinition,
StrategyPropertyValueDefinition| Modifier and Type | Field and Description |
|---|---|
private int |
defaultMaxRuleApplications
The default maximal rule applications.
|
private IDefaultStrategyPropertiesFactory |
defaultPropertiesFactory
The
IDefaultStrategyPropertiesFactory used to create default
StrategyProperties. |
private java.util.ArrayList<Triple<java.lang.String,java.lang.Integer,IDefaultStrategyPropertiesFactory>> |
furtherDefaults
Further default settings, for example suitable for simplification.
|
private java.lang.String |
maxRuleApplicationsLabel
The label shown in front of the control to edit
StrategySettings.getMaxSteps(). |
private ImmutableArray<AbstractStrategyPropertyDefinition> |
properties
Defines the controls to edit
StrategyProperties. |
private java.lang.String |
propertiesTitle
The label shown in front of the controls to edit
StrategyProperties. |
private boolean |
showMaxRuleApplications
Defines if a user interface control is shown to edit
StrategySettings.getMaxSteps(). |
private static java.util.ArrayList<Triple<java.lang.String,java.lang.Integer,IDefaultStrategyPropertiesFactory>> |
STD_FURTHER_DEFAULTS |
| Constructor and Description |
|---|
StrategySettingsDefinition(boolean showMaxRuleApplications,
java.lang.String maxRuleApplicationsLabel,
int defaultMaxRuleApplications,
java.lang.String propertiesTitle,
IDefaultStrategyPropertiesFactory defaultPropertiesFactory,
java.util.ArrayList<Triple<java.lang.String,java.lang.Integer,IDefaultStrategyPropertiesFactory>> furtherDefaults,
AbstractStrategyPropertyDefinition... properties)
Constructor.
|
StrategySettingsDefinition(java.lang.String propertiesTitle,
AbstractStrategyPropertyDefinition... properties)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getDefaultMaxRuleApplications()
Returns the default maximal rule applications.
|
IDefaultStrategyPropertiesFactory |
getDefaultPropertiesFactory()
Returns the
IDefaultStrategyPropertiesFactory used to create
default StrategyProperties. |
java.util.ArrayList<Triple<java.lang.String,java.lang.Integer,IDefaultStrategyPropertiesFactory>> |
getFurtherDefaults() |
java.lang.String |
getMaxRuleApplicationsLabel()
Returns the label shown in front of the control to edit
StrategySettings.getMaxSteps(). |
ImmutableArray<AbstractStrategyPropertyDefinition> |
getProperties()
Returns the definition of controls to edit
StrategyProperties. |
java.lang.String |
getPropertiesTitle()
Returns the label shown in front of the controls to edit
StrategyProperties. |
boolean |
isShowMaxRuleApplications()
Checks if the user interface control to edit
StrategySettings.getMaxSteps() should be shown or not. |
private static final java.util.ArrayList<Triple<java.lang.String,java.lang.Integer,IDefaultStrategyPropertiesFactory>> STD_FURTHER_DEFAULTS
private final boolean showMaxRuleApplications
StrategySettings.getMaxSteps().private final java.lang.String maxRuleApplicationsLabel
StrategySettings.getMaxSteps().private final java.lang.String propertiesTitle
StrategyProperties.private final ImmutableArray<AbstractStrategyPropertyDefinition> properties
StrategyProperties.private final int defaultMaxRuleApplications
private final IDefaultStrategyPropertiesFactory defaultPropertiesFactory
IDefaultStrategyPropertiesFactory used to create default
StrategyProperties.private final java.util.ArrayList<Triple<java.lang.String,java.lang.Integer,IDefaultStrategyPropertiesFactory>> furtherDefaults
public StrategySettingsDefinition(java.lang.String propertiesTitle,
AbstractStrategyPropertyDefinition... properties)
propertiesTitle - The label shown in front of the controls to edit
StrategyProperties.properties - Defines the controls to edit StrategyProperties.public StrategySettingsDefinition(boolean showMaxRuleApplications,
java.lang.String maxRuleApplicationsLabel,
int defaultMaxRuleApplications,
java.lang.String propertiesTitle,
IDefaultStrategyPropertiesFactory defaultPropertiesFactory,
java.util.ArrayList<Triple<java.lang.String,java.lang.Integer,IDefaultStrategyPropertiesFactory>> furtherDefaults,
AbstractStrategyPropertyDefinition... properties)
showMaxRuleApplications - Defines if a user interface control is shown to edit
StrategySettings.getMaxSteps().maxRuleApplicationsLabel - The label shown in front of the control to edit
StrategySettings.getMaxSteps().defaultMaxRuleApplications - The default maximal rule applications.propertiesTitle - The label shown in front of the controls to edit
StrategyProperties.defaultPropertiesFactory - The IDefaultStrategyPropertiesFactory used to create
default StrategyProperties.furtherDefaults - further defaults used to create
default StrategyProperties.properties - Defines the controls to edit StrategyProperties.public boolean isShowMaxRuleApplications()
StrategySettings.getMaxSteps() should be shown or not.true show control, false do not provide a
control.public java.lang.String getMaxRuleApplicationsLabel()
StrategySettings.getMaxSteps().StrategySettings.getMaxSteps() or null if no
label should be shown.public java.lang.String getPropertiesTitle()
StrategyProperties.StrategyProperties or null if no label should be
shown.public ImmutableArray<AbstractStrategyPropertyDefinition> getProperties()
StrategyProperties.StrategyProperties.public int getDefaultMaxRuleApplications()
public IDefaultStrategyPropertiesFactory getDefaultPropertiesFactory()
IDefaultStrategyPropertiesFactory used to create
default StrategyProperties.IDefaultStrategyPropertiesFactory used to create
default StrategyProperties.public java.util.ArrayList<Triple<java.lang.String,java.lang.Integer,IDefaultStrategyPropertiesFactory>> getFurtherDefaults()