Oracle Beehive
  Oracle® Beehive RESTful Web Services API Reference
  Release 2 (2.0.1.7)
  E16658-04

Contents

Overview

A RuleDefinition holds the meta information of the rule condition and action definitions. RuleDefinition in built up on the EventDefintion. If the RuleDefinition included as part of the PolicySchema then RuleDefinition should also can contain attribute definitions which can be used to define the RuleConditionDefinition. If the definition is with in the policy then the rule condition definition and the action definition must not contain any attribute definitions in them i.e., the rule condition definition is the action condition in this case.

Priority of the rule definition defines the order in which the actions of this rule definitions will be executed of the same policy and of the same event definition

Members

Name Type Required Description

actionPreferences

associativeArray<stringstring>

preferences of the actions are the extra information can be provided to the action. If the preferences are defined , this preferences are passed to the action. Each instance of the Rule can have its own preferences. If the action preferences at the rule level is not provided, preferences provided at the RuleDefinition will be used.

actions

ruleActionDefinition[]

Ordered list of actions of the definition. Event though it is defined as list, for now currently we support only one action.

attributeDefinitions

attributeDefinition[]

attributes

attributeDefinition[]

Set of attribute definitions that the rule definition is built upon. This attribute definitions should be used in building RuleConditionDefinition. No two attributes within the same RuleDefinition can have the same name. This restrictions is because RuleCondition Expression refers to the name of the attribute as bind variable.

collabId

beeId

condition

ruleConditionDefinition

Condition part of the rule definition

description

string

Description of the definition

eventDefinition

eventDefinition

EventDefinition is returned on which the rule definition is built

handle

beeId<ruleDefinition>

name

string

Name of the definition

priority

int

Priority of the rule definition

Hierarchy

Applied Markers

Examples

Below are examples in JSON and XML formats. All examples are shown with all inherited members. Quoting when required is part of the examples, but you must obviously populate with your own data.

XML Example

(show inherited members)

<obh:ruleDefinition xsi:type="obh:ruleDefinition" xmlns:obh="http://www.oracle.com/beehive" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
        <obh:actionPreferences>your_associativeArray_0</obh:actionPreferences>
        <obh:actions>your_ruleActionDefinition_0</obh:actions>
        <obh:actions>your_ruleActionDefinition_1</obh:actions>
        <obh:actions>your_ruleActionDefinition_2</obh:actions>
        <obh:attributeDefinitions>your_attributeDefinition_0</obh:attributeDefinitions>
        <obh:attributeDefinitions>your_attributeDefinition_1</obh:attributeDefinitions>
        <obh:attributeDefinitions>your_attributeDefinition_2</obh:attributeDefinitions>
        <obh:attributes>your_attributeDefinition_0</obh:attributes>
        <obh:attributes>your_attributeDefinition_1</obh:attributes>
        <obh:attributes>your_attributeDefinition_2</obh:attributes>
        <obh:collabId>your_beeId_0</obh:collabId>
        <obh:condition>your_ruleConditionDefinition_0</obh:condition>
        <obh:description>your_string_0</obh:description>
        <obh:eventDefinition>your_eventDefinition_0</obh:eventDefinition>
        <obh:handle>your_beeId_0</obh:handle>
        <obh:name>your_string_0</obh:name>
        <obh:priority>your_int_0</obh:priority>
</obh:ruleDefinition>

JSON Example

(show inherited members)

{
    "beeType":"ruleDefinition",
        "actionPreferences":{ your_{http://www.oracle.com/beehive}actionPreferences_as_associativeArray0 },
        "actions":[
            { your_{http://www.oracle.com/beehive}actions_as_ruleActionDefinition0 },
            { your_{http://www.oracle.com/beehive}actions_as_ruleActionDefinition1 },
            { your_{http://www.oracle.com/beehive}actions_as_ruleActionDefinition2 }
        ],
        "attributeDefinitions":[
            { your_{http://www.oracle.com/beehive}attributeDefinitions_as_attributeDefinition0 },
            { your_{http://www.oracle.com/beehive}attributeDefinitions_as_attributeDefinition1 },
            { your_{http://www.oracle.com/beehive}attributeDefinitions_as_attributeDefinition2 }
        ],
        "attributes":[
            { your_{http://www.oracle.com/beehive}attributes_as_attributeDefinition0 },
            { your_{http://www.oracle.com/beehive}attributes_as_attributeDefinition1 },
            { your_{http://www.oracle.com/beehive}attributes_as_attributeDefinition2 }
        ],
        "collabId":{ your_{http://www.oracle.com/beehive}collabId_as_beeId0 },
        "condition":{ your_{http://www.oracle.com/beehive}condition_as_ruleConditionDefinition0 },
        "description":"your_{http://www.oracle.com/beehive}description_as_string0",
        "eventDefinition":{ your_{http://www.oracle.com/beehive}eventDefinition_as_eventDefinition0 },
        "handle":{ your_{http://www.oracle.com/beehive}handle_as_beeId0 },
        "name":"your_{http://www.oracle.com/beehive}name_as_string0",
        "priority":your_{http://www.oracle.com/beehive}priority_as_int0
}

XML Schema


<xs:complexType final="extension restriction" name="ruleDefinition">
    <xs:sequence>
        <xs:element minOccurs="0" name="actionPreferences" type="tns:associativeArray"/>
        <xs:element maxOccurs="unbounded" minOccurs="0" name="actions"
            nillable="true" type="tns:ruleActionDefinition"/>
        <xs:element maxOccurs="unbounded" minOccurs="0"
            name="attributeDefinitions" type="tns:attributeDefinition"/>
        <xs:element maxOccurs="unbounded" minOccurs="0"
            name="attributes" type="tns:attributeDefinition"/>
        <xs:element minOccurs="0" name="collabId" type="tns:beeId"/>
        <xs:element minOccurs="0" name="condition" type="tns:ruleConditionDefinition"/>
        <xs:element minOccurs="0" name="description" type="xs:string"/>
        <xs:element minOccurs="0" name="eventDefinition" type="tns:eventDefinition"/>
        <xs:element minOccurs="0" name="handle" type="tns:beeId"/>
        <xs:element minOccurs="0" name="name" type="xs:string"/>
        <xs:element name="priority" type="xs:int"/>
    </xs:sequence>
</xs:complexType>

        

References

The following data represents the references to ruleDefinition

Referenced By Resources

Not Referenced Directly by Resources

Referenced By Representaions