|
IBM WebSphere Application ServerTM Release 7 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface PropertyQueryNode
This is an interface for querying properties associated with business rule groups. Each instance of this class contains the following:
Here are some examples:
// Find business rule groups where the value of property "Department" exactly // matches the string "Marketing". PropertyQueryNode propNode = QueryNodeFactory.createPropertyQueryNode("Department", QueryOperator.EQUAL, "Marketing");
// Find business rule groups where the value of property "Department" is like the // string "%Engineering%". PropertyQueryNode propNode = QueryNodeFactory.createPropertyQueryNode("Department", QueryOperator.LIKE, "%Engineering%");
// Find business rule groups where the value of property "Department" is not like the // string "%Engineering%". PropertyQueryNode propNode = QueryNodeFactory.createPropertyQueryNode("Department", QueryOperator.NOT_LIKE, "%Engineering%");
A PropertyQueryNode
can be used by itself to form a query, if the query is using
a single property, or it may be combined with other QueryNode
objects using
the logical operator nodes AndNode
, OrNode
, and NotNode
to form more complicated queries.
Special property names are defined to allow queries to be performed on the target name
space, name, and display name of an artifact (for example, a business rule group, ruleset,
or decision table). These names are defined as constants in the Property
interface:
PROPERTY_NAME__TARGET_NAME_SPACE
,
PROPERTY_NAME__NAME
, and
PROPERTY_NAME__DISPLAY_NAME
.
Note that if a particular business rule group does not have the
property in question defined, it will not even be considered when the query is performed.
This means that it will never be returned by a PropertyQueryNode
query that
specifies that property. For example, consider three business rule groups and a property
named "Department". Two of the business rule groups have a "Department" property defined
and the third one does not:
BRG1 Department = "Marketing" BRG2 Department = "Engineering" BRG3 No department propertyIf you perform a query for all business rule groups with the "Department" property equal to "Marketing", then you will get BRG1. If you perform a query for all business rule groups with the "Department" property not equal to "Marketing", you will get BRG2 but you will not get BRG3. Since BRG3 does not have the "Department" property defined, it will not even be considered in the query. If you want to perform a query that would also return BRG3, you can use the
PropertyIsDefinedQueryNode
and the
NotNode
to query for all business rule groups that do not have the
"Department" property defined. Then use an OrNode
to combine that query
with a query for all business rule groups with the "Department" property not equal to
"Marketing".
Field Summary | |
---|---|
static java.lang.String |
COPYRIGHT
|
Method Summary | |
---|---|
java.lang.String |
getPropertyName()
Get the name of the property whose value is to be queried by this node. |
java.lang.String |
getPropertyValue()
Get the value that is to be queried for for this property. |
QueryOperator |
getQueryOperator()
Get the operator for this query. |
Field Detail |
---|
static final java.lang.String COPYRIGHT
Method Detail |
---|
java.lang.String getPropertyName()
QueryOperator getQueryOperator()
java.lang.String getPropertyValue()
|
IBM WebSphere Application ServerTM Release 7 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |