Each selector is comprised of a list of selection criteria. More specifically, a field selector is comprised of field criteria, a method selector is comprised of method criteria, and a type selector is comprised of type criteria. However across these three kinds of criteria there are common attributes, and these are described once here.
Attribute | Description | Required |
---|---|---|
javadocTag | a Javadoc tag which qualifying Java elements must have | No |
javadocValuePattern | a reference to a pattern switch whose value is a pattern to which the value | No |
javadocValuePatternSwitch | a string which will be appended to the title of matching types in the format <<stereotype>> | No |
declaredBy | a reference to a type selector which includes the type in which this Java element is declared | No |
namePattern | a pattern to which the name of all included Java elements must conform | No |
namePatternSwitch | a reference to a pattern switch whose value is a pattern to which the name of all included Java elements must conform | No |
includedOtherSelector | a reference to another selector, inclusion in which is a prerequisite | No |
excludedOtherSelector | a reference to another selector, exclusion from which is a prerequisite | No |
A Java keyword modifier which must be present for a candidate Java element to be included.
<FieldSelector description="all fields whose name ends in ID" name="idFields">
<FieldCriterion namePattern="*ID"/>
</FieldSelector>
A name pattern which matches all Java elements (in this case fields) whose name ends in 'ID'.
<TypeSelector description="all abstract classes" name="abstractTypes" stereotype="abstract">
<TypesCriterion>
<Modifier value="abstract"/>
</TypesCriterion>
</TypeSelector>
Matches all abstract classes.