Defining the Search Criteria for Object Groups

There are two types of search criteria : Any Criteria or All Criteria. Any Criteria fetches object groups that match any of the conditions specified in the search criteria. All Criteria fetches object groups that match all the conditions specified in the search criteria.

Procedure

  1. Navigate to <TIBCO_HOME>/pd/1.2/samples/<Name_of_the_Governance_Control_Template> and open the appropriate data file.
  2. For Any Criteria, specify the search condition in multiple <Expressions> tags. In this case, each <Expression> contains only one <Statement> tag within it. The <Expressions> tags together makes for a search condition. Object groups are retrieved even if one of the search criteria is satisfied. The attribute specified in the <type> element varies depending upon the criteria type, which varies depending upon the domain type. For more details on selecting the appropriate attributes, see Selecting Attributes for The Search Criteria . The valid values for the operator are: equals, contains, startsWith, and endsWith. The following code snippet retrieves object groups whose application name either contains, equals, or ends with MCR-DAA1-1.
    <Expressions> 
      <Expression> 
        <Statements> 
          <Statement> 
             <type localPart="Application" 
              namespace="http://tns.tibco.com/governance/common/govdomain/tibco/amx3"/> 
             <property localPart="name" namespace=""/> 
             <operator>contains</operator> 
             <operand1>MCR-DAA1-1</operand1> 
           </Statement> 
         </Statements> 
       </Expression> 
    </Expressions>
    <Expressions> 
      <Expression> 
        <Statements> 
          <Statement> 
             <type localPart="Application" 
              namespace="http://tns.tibco.com/governance/common/govdomain/tibco/amx3"/> 
             <property localPart="name" namespace=""/> 
             <operator>equals</operator> 
             <operand1>MCR-DAA1-1</operand1> 
           </Statement> 
         </Statements> 
       </Expression> 
    </Expressions>
    <Expressions> 
      <Expression> 
        <Statements> 
          <Statement> 
             <type localPart="Application" 
              namespace="http://tns.tibco.com/governance/common/govdomain/tibco/amx3"/> 
             <property localPart="name" namespace=""/> 
             <operator>endsWith</operator> 
             <operand1>MCR-DAA1-1</operand1> 
           </Statement> 
         </Statements> 
       </Expression> 
    </Expressions>
  3. For All Criteria, specify all the search conditions in one <Expressions> tag. In this case, each <Expression> contains multiple <Statement> tags within it. The attribute list varies depending upon the criteria type, which varies depending upon the domain type. For more details on selecting the appropriate attributes, see Selecting Attributes for The Search Criteria . The valid values for the operator are: equals, contains, startsWith, and endsWith.The following code snippet retrieves object groups whose application name matches the following conditions: contains DAA, starts with MCR, and ends with DAA1-1.
    <Expressions> 
      <Expression> 
        <Statements> 
          <Statement> 
             <type localPart="Application" 
              namespace="http://tns.tibco.com/governance/common/govdomain/tibco/amx3"/> 
             <property localPart="name" namespace=""/> 
             <operator>contains</operator> 
             <operand1>DAA</operand1> 
           </Statement> 
           <Statement> 
             <type localPart="Application" 
              namespace="http://tns.tibco.com/governance/common/govdomain/tibco/amx3"/> 
             <property localPart="name" namespace=""/> 
             <operator>startsWith</operator> 
             <operand1>MCR</operand1> 
           </Statement>
           <Statement> 
             <type localPart="Application"
              namespace="http://tns.tibco.com/governance/common/govdomain/tibco/amx3"/> 
             <property localPart="name" namespace=""/> 
             <operator>endsWith</operator> 
             <operand1>DAA1-1</operand1> 
           </Statement>
         </Statements> 
       </Expression> 
    </Expressions>