Rio Project 4.2 API Documentation



org.rioproject.gnostic
Interface Gnostic

All Known Implementing Classes:
GnosticImpl

public interface Gnostic

Provides the ability to add, remove and return managed rules.

Author:
Dennis Reedy

Method Summary
 boolean add(RuleMap ruleMap)
          Add a rule mapping to Gnostic.
 List<RuleMap> get()
          Get all managed rule mappings
 int getScannerInterval()
          Get the amount of time (in seconds) the Gnostic polls for changes to managed rules.
 boolean remove(RuleMap ruleMap)
          Remove an existing managed rule mapping
 void setScannerInterval(int interval)
          Set the amount of time (in seconds) the Gnostic polls for changes to managed rules.
 

Method Detail

add

boolean add(RuleMap ruleMap)
            throws RemoteException
Add a rule mapping to Gnostic.

Parameters:
ruleMap - The rule mapping to add.
Returns:
True if the rule mapping was added, false otherwise. If the rule mapping already exists, this method will return false. Note that adding a rule mapping is asynchronous. Returning true means that the rule was added for processing. The rule(s) still require compilation and validation, verifying that the rule has been added can be achieved by getting the managed rule mappings.
Throws:
IllegalArgumentException - if the ruleMap argument is null or contains null values.
RemoteException - If communication errors occur

get

List<RuleMap> get()
                  throws RemoteException
Get all managed rule mappings

Returns:
A non-modifiable list of managed rule mappings. If there are no managed rule mappings a zer-length array is returned. A new array is created each time.
Throws:
RemoteException - If communication errors occur

remove

boolean remove(RuleMap ruleMap)
               throws RemoteException
Remove an existing managed rule mapping

Parameters:
ruleMap - The rule map to remove
Returns:
True if the rule mapping was removed, false otherwise. If the rule mapping does not exist, this method will return false.
Throws:
IllegalArgumentException - if the ruleMap argument is null or contains null values.
RemoteException - If communication errors occur

getScannerInterval

int getScannerInterval()
                       throws RemoteException
Get the amount of time (in seconds) the Gnostic polls for changes to managed rules.

Returns:
The amount of time (in seconds) the Gnostic polls for changes made to managed rules
Throws:
RemoteException - If communication errors occur

setScannerInterval

void setScannerInterval(int interval)
                        throws RemoteException
Set the amount of time (in seconds) the Gnostic polls for changes to managed rules.

Parameters:
interval - The amount of time (in seconds) to poll
Throws:
RemoteException - If communication errors occur
IllegalArgumentException - if the scannerInterval is <= 0

Copyright © Rio Project.

Copyright © 2006-2011 Rio Project. All Rights Reserved.