The accept rules in your rule set determine what content should be delivered to your users. The rules test properties of the content items and properties of your user’s profile. If the relationships among these properties result in a match, then the system delivers the content item to the user.

Example: Targeting Content

For example, suppose you have a repository that includes news items about companies in different industrial sectors, and you want to deliver items about companies in the rubber industry sector to users whose profiles identify them as analysts who cover the rubber industry. First, you can write a rule that identifies which of the items in your repository relate to the rubber industry, like this:

<rule op=eq name="Rubber sector">
  <valueof target="industrySector">
  <valueof constant="rubber">
</rule>

This rule is true with respect to a document if the industrySector property of the document has the value “rubber.” When you use the target type in a <valueof> tag, you are testing properties of items in your repository. See <valueof> Tag.

Example: Targeting Users

Next, you can write a rule that identifies whether one of the industry sectors covered by the user is the rubber industry, like this:

<rule op=includes name="Rubber analysts">
  <valueof bean="Profile.sectorsCovered">
  <valueof constant="rubber">
</rule>

This rule is true with respect to a user if the sectorsCovered property of his or her profile includes the value “rubber.” The <valueof bean="..."> tag points to the user’s profile and tests the indicated property against the constant in the next tag. See <valueof> Tag.

Example: A Complete Accept Rule

Now, you can put the two rules together in an and rule within the <accepts> tag to match the content to the user:

<accepts>
  <rule op=and>
    <rule op=eq name="Rubber sector">
      <valueof target="industry sector">
      <valueof constant="rubber">
    </rule>
    <rule op=includes name="Rubber analysts">
      <valueof bean="Profile.sectorsCovered">
      <valueof constant="rubber">
    </rule>
  </rule>
</accepts>

Copyright © 1997, 2014 Oracle and/or its affiliates. All rights reserved. Legal Notices