Oracle Email Java API Reference
Release 2(9.0.4)

B10724-01

oracle.mail.sdk.rule
Class RuleListType

java.lang.Object
  |
  +--oracle.xml.classgen.CGXSDElement
        |
        +--oracle.mail.sdk.rule.RuleElement
              |
              +--oracle.mail.sdk.rule.RuleListType

public class RuleListType
extends RuleElement

This class represents a list of rules associated with one event. Objects of this class are building blocks for the AccountType class, with each RuleListType object associated with one applicable event.

The list of allowable event values are:

A RuleListType object should contain at least one rule. Rules in the RuleListType object are ordered and will be evaluated in order at runtime.

Since:
9.0
Version:
$Header: RuleListType.java 01-may-2003.16:43:35 haye Exp $
See Also:
AccountType

Constructor Summary
RuleListType()
           

 

Method Summary
 void activateGroup(java.lang.String groupName)
          Marks attribute "active" to "yes" for all rules in a group.
 void addRule(RuleType therule)
          Adds a rule object to this list.
 void disableGroup(java.lang.String groupName)
          Marks attribute "active" to "no" for all rules in a group.
 java.util.Set getAllGroupNames()
          Gets all rule group names without duplicates.
 java.lang.String getEvent()
          Gets the value of the Event attribute.
 java.util.Vector getRules()
          Gets the list of rules.
 java.util.Vector getRulesForGroup(java.lang.String groupName)
          Gets the list of rules that has the same "group" attribute value as the given group name.
 java.util.Vector getVisibleRules()
          Gets the list of all visible rules.
 void setEvent(java.lang.String theevent)
          Sets the value of Event attribute.
 void setRules(java.util.Vector therules)
          Resets this object with given list of rules as a Vector os RuleType objects.

 

Methods inherited from class oracle.mail.sdk.rule.RuleElement
getParent, getType, printAttributes, removeAll, removeAt

 

Methods inherited from class oracle.xml.classgen.CGXSDElement
getAttributes, getChildElements, getNodeValue, print, printAttributes

 

Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Constructor Detail

RuleListType

public RuleListType()
Method Detail

setEvent

public void setEvent(java.lang.String theevent)
              throws java.lang.IllegalArgumentException,
                     oracle.xml.classgen.InvalidContentException
Sets the value of Event attribute.
Parameters:
theevent - the event string
Throws:
java.lang.IllegalArgumentException - if the attribute is not valid.

getEvent

public java.lang.String getEvent()
Gets the value of the Event attribute.
Returns:
the value of the Event attribute

addRule

public void addRule(RuleType therule)
             throws oracle.xml.classgen.InvalidContentException
Adds a rule object to this list. The new rule object will be added to the end of the rule list.
Parameters:
rule - the rule object
Throws:
oracle.xml.classgen.InvalidContentException - if the element is not valid.
See Also:
RuleType

setRules

public void setRules(java.util.Vector therules)
              throws oracle.xml.classgen.InvalidContentException
Resets this object with given list of rules as a Vector os RuleType objects. This method can be used to re-order the rules in the list.
Parameters:
therules - the vector of rules
Throws:
oracle.xml.classgen.InvalidContentException - if the element is not valid.

getRules

public java.util.Vector getRules()
Gets the list of rules.
Returns:
the list of rules in this object

getRulesForGroup

public java.util.Vector getRulesForGroup(java.lang.String groupName)
Gets the list of rules that has the same "group" attribute value as the given group name. A group is a name that a rule can identify with.
Parameters:
groupName - the group name to retrieve
Returns:
the list of the rules with the same given group attribute

getAllGroupNames

public java.util.Set getAllGroupNames()
Gets all rule group names without duplicates. A group is a name that a rule can identify with.
Returns:
the set of all rule group names in this rule list object

getVisibleRules

public java.util.Vector getVisibleRules()
Gets the list of all visible rules.
Returns:
a list of all rules that has the attribute "visible" set to "yes"

activateGroup

public void activateGroup(java.lang.String groupName)
                   throws oracle.xml.classgen.InvalidContentException
Marks attribute "active" to "yes" for all rules in a group.
Parameters:
groupName - the name of the rule group to activate

disableGroup

public void disableGroup(java.lang.String groupName)
                  throws oracle.xml.classgen.InvalidContentException
Marks attribute "active" to "no" for all rules in a group.
Parameters:
groupName - the name of the rule group to disable

Oracle Email Java API Reference
Release 2(9.0.4)

B10724-01

Copyright © 1988, 2003 Oracle Corporation. All Rights Reserved.