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

## com.bea.p13n.rules.manager
Interface RuleSetRepository

All Known Subinterfaces:
  RulesManager

public interface RuleSetRepository

This interface defines the operations necessary to add, remove, and retrieve rule set XML documents to and from a rule set store. All rule set repository subsystems must implement this interface; however, the following operations are optional, and may not be supported by all implementations:

- `setRuleSet`
- `removeRuleSet`

See Also:
  `RuleSetArchive`

Field Summary
`static int` | `BINARY_FORMAT` Rule set format: binary representation.
`static int` | `STRING_FORMAT` Rule set format: XML string representation.

Method Summary
`Object` | `getRuleSet(String ruleSetUri, int format)` Retrieves the rule set with the given URI in the specified format.
`Collection` | `getRuleSets()` Retrieves a `Collection` containing the URI strings of all the rule sets available in the rule set repository subsystem.
`void` | `removeRuleSet(String ruleSetUri)` Removes a rule set with the given URI.
`void` | `setRuleSet(RuleSetArchive archive)` Saves a new or updated rule set.

Field Detail

### BINARY_FORMAT

    public static final int BINARY_FORMAT

  Rule set format: binary representation.

  See Also:
    Constant Field Values

### STRING_FORMAT

    public static final int STRING_FORMAT

  Rule set format: XML string representation.

  See Also:
    Constant Field Values

Method Detail

### getRuleSet

    public Object getRuleSet(String ruleSetUri,
                             int format)
                      throws RuleSetNotFoundException,
                             ApplicationException,
                             IllegalArgumentException,
                             RemoteException

  Retrieves the rule set with the given URI in the specified format. The format of a returned rule set may be one of the following:
  - `STRING_FORMAT` - an XML string representation of the rule set.
  - `BINARY_FORMAT` - a binary representation of the rule set.

  Parameters:
    `ruleSetUri` - the URI of the target rule set.
    `format` - the desired format of the returned rule set.
  Returns:
    the rule set in the specified format.
  Throws:
    `RuleSetNotFoundException` - if the rule set referenced by the supplied URI cannot be located by the rule set repository subsystem.
    `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.
    `RemoteException` - if a communication error occurs during the execution of a remote method call.

### getRuleSets

    public Collection getRuleSets()
                           throws ApplicationException,
                                  RemoteException

  Retrieves a `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:
    `ApplicationException` - if the rule set repository subsystem is unable to retrieve the rule set URI strings.
    `RemoteException` - if a communication error occurs during the execution of a remote method call.

### removeRuleSet

    public void removeRuleSet(String ruleSetUri)
                       throws RuleSetNotFoundException,
                              ApplicationException,
                              IllegalArgumentException,
                              UnsupportedOperationException,
                              RemoteException

  Removes a rule set with the given URI.

  Parameters:
    `ruleSetUri` - the URI of the target rule set.
  Throws:
    `RuleSetNotFoundException` - if the rule set referenced by the supplied URI cannot be located by the rule set repository subsystem.
    `ApplicationException` - if the rule set repository subsystem is unable to remove the rule set.
    `IllegalArgumentException` - if the `ruleSetUri` is an invalid rule set URI.
    `UnsupportedOperationException` - if the `setRuleSet` operation is not supported by the rule set repository subsystem.
    `RemoteException` - if a communication error occurs during the execution of a remote method call.

### setRuleSet

    public void setRuleSet(RuleSetArchive archive)
                    throws ApplicationException,
                           IllegalArgumentException,
                           UnsupportedOperationException,
                           RemoteException

  Saves a new or updated rule set. This method is an optional operation that may not be supported by the rule set repository subsystem.

  Parameters:
    `archive` - the `RuleSetArchive` that contains the rule set deployment information.
  Throws:
    `ApplicationException` - if the rule set repository subsystem is unable to persist the rule set.
    `IllegalArgumentException` - if the `RuleSetArchive` is invalid.
    `UnsupportedOperationException` - if the `setRuleSet` operation is not supported by the rule set repository subsystem.
    `RemoteException` - if a communication error occurs during the execution of a remote method call.

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

Copyright © 2004 BEA Systems, Inc. All Rights Reserved