Overview | Package | Class | Tree | Deprecated | Index | Help
| Copyright © 2006 BEA Systems, Inc. All Rights Reserved
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bea.p13n.controls.rules
Interface RulesManagerControl

All Superinterfaces
  Serializable

    public interface RulesManagerControl

extends Serializable

This control defines the API for accessing and managing rules and rulesets for the portal rules manager. It is intended to be used only by portal system administrators. Rulesets are stored in the Portal data repository and are updated using data sync. They are loaded automatically when the server starts. To facilitate loading rulesets via data sync, simply place the ruleset file (generally ends with .rls) into the application's META-INF/data directory. For better organization, you may place the rulesets into a subdirectory, such as META-INF/data/rulesets. The ruleset uri is relative to the META-INF/data directory. Because this control requires the caller be in an authorized role, it cannot be used from a JWS.
Security requirements: The caller must be in the role of "PortalSystemAdministrator" to invoke all of these methods

Method Summary
`String` | `getRuleDescription(String rulesetUri, String ruleName)` Retrieves the desrciption of the rule within the named ruleset
`Collection` | `getRuleSets()` Retrieves an immutable `Collection` containing the URI strings of all the rule sets available in the rule set repository subsystem.
`String` | `getRuleSetXml(String ruleSetUri)` Retrieves the rule set as an XML String
`String[]` | `getRulesForRuleSet(String rulesetUri)` Retrieves an array rule names for a given ruleset

Method Detail

### getRuleSetXml

    String getRuleSetXml(String ruleSetUri)
                         throws IllegalArgumentException,
                                com.bea.p13n.rules.manager.RuleSetNotFoundException,
                                com.bea.p13n.exceptions.ApplicationException,
                                com.bea.p13n.controls.exceptions.P13nControlException

  Retrieves the rule set as an XML String

  Parameters
    `ruleSetUri` - the URI of the target rule set.
    `format` - the desired format of the returned rule set.
  Returns
    the rule set as an XML String.
  Throws
    `com.bea.p13n.rules.manager.RuleSetNotFoundException` - if the rule set referenced by the supplied URI cannot be located by the rule set repository subsystem.
    `com.bea.p13n.exceptions.ApplicationException` - if the rule set repository subsystem is unable to retrieve the rule set.
    `IllegalArgumentException` - if the `ruleSetUri` is an invalid rule set URI or if the format is not supported.
    `com.bea.p13n.controls.exceptions.P13nControlException` - if remote errors are encountered.

### getRuleSets

    Collection getRuleSets()
                           throws com.bea.p13n.exceptions.ApplicationException,
                                  com.bea.p13n.controls.exceptions.P13nControlException

  Retrieves an immutable `Collection` containing the URI strings of all the rule sets available in the rule set repository subsystem.
  The rule sets represented by the returned URI strings may then be retrieved by supplying each returned rule set URI string to the `getRuleSet` method.

  Returns
    a `Collection` of all rule set URI strings.
  Throws
    `com.bea.p13n.exceptions.ApplicationException` - if the rule set repository subsystem is unable to retrieve the rule set URI strings.
    `com.bea.p13n.controls.exceptions.P13nControlException` - if remote errors are encountered.

### getRulesForRuleSet

    String[] getRulesForRuleSet(String rulesetUri)
                                throws com.bea.p13n.exceptions.ApplicationException,
                                       com.bea.p13n.controls.exceptions.P13nControlException

  Retrieves an array rule names for a given ruleset

  Parameters
    `rulesetUri` - uri of the ruleset, relative to the application's META-INF/data directory
  Returns
    an array of all rules for the named ruleset uri.
  Throws
    `com.bea.p13n.exceptions.ApplicationException` - if the rule set repository subsystem is unable to retrieve the rule set URI strings.
    `com.bea.p13n.exceptions.ApplicationException` - if the rule set repository subsystem is unable to retrieve the rule set URI strings.
    `com.bea.p13n.controls.exceptions.P13nControlException` - if remote errors are encountered.

### getRuleDescription

    String getRuleDescription(String rulesetUri,
                              String ruleName)
                              throws com.bea.p13n.rules.manager.RuleSetNotFoundException,
                                     com.bea.p13n.exceptions.ApplicationException,
                                     IllegalArgumentException,
                                     com.bea.p13n.controls.exceptions.P13nControlException

  Retrieves the desrciption of the rule within the named ruleset

  Parameters
    `rulesetUri` - uri of the ruleset, relative to the application's META-INF/data directory
    `the` - rule name
  Returns
    the description of the rule.
  Throws
    `com.bea.p13n.rules.manager.RuleSetNotFoundException` - if the rule set referenced by the supplied URI cannot be located by the rule set repository subsystem.
    `com.bea.p13n.exceptions.ApplicationException` - if the rule set repository subsystem is unable to retrieve the rule set.
    `IllegalArgumentException` - if the `ruleSetUri` is an invalid rule set URI or if the format is not supported.
    `com.bea.p13n.controls.exceptions.P13nControlException` - if remote errors are encountered.

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2006 BEA Systems, Inc. All Rights Reserved