public abstract class TestProperty extends Object implements Comparable<TestProperty>
| Modifier and Type | Class and Description |
|---|---|
static class |
TestProperty.TestPropertyType
Enumeration of the basic property types supported
|
| Modifier and Type | Field and Description |
|---|---|
static String |
PROP_CHOICE_COLLECTION |
static String |
PROP_DEFAULT |
static String |
PROP_DESCRIPTION |
static String |
PROP_GROUP |
static String |
PROP_HIDE |
static String |
PROP_MASK |
static String |
PROP_NAME |
static String |
PROP_TITLE |
static String |
PROP_TYPE |
static String |
PROP_VALIDATION |
| Constructor and Description |
|---|
TestProperty(String name,
Properties properties)
Construct a test property
|
| Modifier and Type | Method and Description |
|---|---|
void |
addError(String error)
Record and error condition against the test property.
|
void |
addError(String name,
String valueName,
String value)
Record an error when converting a value
|
protected abstract void |
addProperties(Properties properties)
Derived instances must override this and attach additional, type-specific properties
|
int |
compareTo(TestProperty o)
Compares based on group and name.
|
boolean |
equals(Object obj)
Equality is based purely on name.
|
String |
getChoices() |
String |
getDefault() |
String |
getDescription() |
List<String> |
getErrors() |
String |
getGroup() |
String |
getName() |
String |
getTitle() |
abstract TestProperty.TestPropertyType |
getType() |
String |
getValidation() |
static Set<String> |
getValueNames()
Fetch the values that should be defined for a test property.
|
int |
hashCode()
Hashcode is based purely on name.
|
boolean |
isHide() |
boolean |
isMask() |
Properties |
toProperties()
Convert the instance back into raw Java properties
|
String |
toString() |
public static final String PROP_NAME
public static final String PROP_TYPE
public static final String PROP_DEFAULT
public static final String PROP_GROUP
public static final String PROP_TITLE
public static final String PROP_DESCRIPTION
public static final String PROP_HIDE
public static final String PROP_MASK
public static final String PROP_VALIDATION
public static final String PROP_CHOICE_COLLECTION
public TestProperty(String name, Properties properties)
public static Set<String> getValueNames()
public int hashCode()
public boolean equals(Object obj)
public int compareTo(TestProperty o)
compareTo in interface Comparable<TestProperty>public void addError(String error)
public void addError(String name, String valueName, String value)
name - the name of the propertyvalueName - the value name e.g. 'minLength'value - the actual value supplied e.g. 'A'public abstract TestProperty.TestPropertyType getType()
public Properties toProperties()
protected abstract void addProperties(Properties properties)
public String getName()
public String getDefault()
public String getGroup()
public String getTitle()
public String getDescription()
public boolean isHide()
public boolean isMask()
public String getValidation()
public String getChoices()
Copyright © 2005–2018 Alfresco Software. All rights reserved.