Class PermuteProperty<T>
- Type Parameters:
T- element-type of the bean whose property or properties will be changed during permutation.
- Direct Known Subclasses:
PermutePropertyDoubleSet,PermutePropertySequence,PermutePropertyStringSet
Changes properties of an
AnchorBean to one of a range of possible values.
A property can be a direct property of the bean, or one or more indirect properties found in nested child-beans.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateSetter(AnchorBean<?> bean) Creates aPermutationAssignerwhich allows the particular property to be changed.abstract StringdescribePropertyValue(T value) Describes a particular property-value in a unique but human-readable way.Additional property paths that are also changed, together withpropertyPath.Either a direct property of a bean or a nested-property with the children separated by full-stops.An iterator with possible alternative values for the property.voidsetAdditionalPropertyPaths(StringSet additionalPropertyPaths) Additional property paths that are also changed, together withpropertyPath.voidsetPropertyPath(String propertyPath) Either a direct property of a bean or a nested-property with the children separated by full-stops.Methods inherited from class org.anchoranalysis.bean.AnchorBean
checkMisconfigured, describeBean, describeChildren, duplicateBean, fields, findFieldsOfClass, getBeanName, getLocalPath, localise, toString
-
Constructor Details
-
PermuteProperty
public PermuteProperty()
-
-
Method Details
-
describePropertyValue
Describes a particular property-value in a unique but human-readable way.- Parameters:
value- the value to describe, which should one of the values returned bypropertyValues().- Returns:
- the description of
value.
-
createSetter
Creates aPermutationAssignerwhich allows the particular property to be changed.- Parameters:
bean- the bean whose property will be changed.- Returns:
- the setter that can change the property.
- Throws:
AssignPermutationException- if no property can be found atpropertyPathto change.
-
propertyValues
An iterator with possible alternative values for the property.- Returns:
- a newly created iterator of all possible alternative values.
-
getPropertyPath
Either a direct property of a bean or a nested-property with the children separated by full-stops.e.g. a direct property
somepropertyor a nested-property e.g.somechild1.somechild2.somepropertyA child bean used in this way must be of single multiplicity, and always be a subclass of
AnchorBean. -
setPropertyPath
Either a direct property of a bean or a nested-property with the children separated by full-stops.e.g. a direct property
somepropertyor a nested-property e.g.somechild1.somechild2.somepropertyA child bean used in this way must be of single multiplicity, and always be a subclass of
AnchorBean. -
getAdditionalPropertyPaths
Additional property paths that are also changed, together withpropertyPath. -
setAdditionalPropertyPaths
Additional property paths that are also changed, together withpropertyPath.
-