|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ibm.are.xml.rules.Rule
public abstract class Rule
The Rule
class represents a rule within the Application Runtime Expert environment.
A rule is an entity that is capable of verifying a condition, and is the foundation for much of the
verification that is done by the Application Runtime Expert. Typically a rule class is the class
that understands how to actually perform a specific check. Because of this, rule classes are very
helpful not just internally to the Application Runtime Expert, but also externally as an API to
Application Runtime Expert plugins. Rule classes are typically standalone and do not require any
additional setup or special logic to use them. This makes them ideal for re-use, especially because they
implement potentially complex checks via a standard, easy to use key/value map interface.
Field Summary | |
---|---|
static java.lang.String |
COPYRIGHT
Copyright for class bytecode |
static java.lang.String |
MAP_ITEM_CHECK_CLASS
The data type (class) of the expected and actual values |
static java.lang.String |
MAP_ITEM_CHECK_OBJECT
The name of the reference that refers to a Check object |
static java.lang.String |
MAP_ITEM_CHECK_TYPE
The type of check to perform between the expected and actual values |
static java.lang.String |
MAP_ITEM_ERROR_LEVEL
Specifies the severity level a problem is reported at for this check. |
static java.lang.String |
MAP_ITEM_EXPECTED_VALUE
The expected value is the value that is used to compare against, or check, the actual value |
static java.lang.String |
MAP_ITEM_MATCH_CASE
Specifies whether or not character case is honored when performing string comparisons |
Method Summary | |
---|---|
com.ibm.are.xml.rules.XmlNodeInfo |
getNodeInfo()
Retrieves the XML node information associated with this rule. |
com.ibm.are.report.ProblemContext |
report(com.ibm.are.plugin.Plugin plugin,
java.lang.String str)
Reports the specified problem and returns a reference to the ProblemContext
that represents the reported problem. |
com.ibm.are.report.ProblemContext |
report(com.ibm.are.plugin.Plugin plugin,
java.lang.String str,
com.ibm.are.autofix.FixAction fixAction)
Reports the specified problem, registers the specified fix action for correcting the problem, and returns a reference to the ProblemContext that represents the reported problem. |
abstract boolean |
run(com.ibm.are.plugin.Plugin plugin)
Runs the rule, which performs the check/verification implemented by that rule. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String COPYRIGHT
public static final java.lang.String MAP_ITEM_CHECK_OBJECT
Check
object
public static final java.lang.String MAP_ITEM_CHECK_CLASS
public static final java.lang.String MAP_ITEM_CHECK_TYPE
public static final java.lang.String MAP_ITEM_MATCH_CASE
public static final java.lang.String MAP_ITEM_EXPECTED_VALUE
public static final java.lang.String MAP_ITEM_ERROR_LEVEL
false
,
a problem is reported. The severity of the reported problem is determined by the error level.
Method Detail |
---|
public com.ibm.are.report.ProblemContext report(com.ibm.are.plugin.Plugin plugin, java.lang.String str)
ProblemContext
that represents the reported problem.
plugin
- The plugin that is reporting the problemstr
- The problem text
ProblemContext
that represents the reported problem.public com.ibm.are.report.ProblemContext report(com.ibm.are.plugin.Plugin plugin, java.lang.String str, com.ibm.are.autofix.FixAction fixAction)
ProblemContext
that represents the reported problem.
plugin
- The plugin that is reporting the problemstr
- The problem textfixAction
- The description of an action that can be taken to fix the reported problem
ProblemContext
that represents the reported problem.public com.ibm.are.xml.rules.XmlNodeInfo getNodeInfo()
NullNodeInfo
object.
NullNodeInfo
object if the rule was created via the Map API interface.public abstract boolean run(com.ibm.are.plugin.Plugin plugin)
plugin
- The plugin for which the rule is being run for.
true
if the verification was successful and no problems were found.
false
if the verification resulted in a problem being found and reported.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |