com.beasys.commerce.axiom.reasoning.rules.service
Class ServiceProviderManager
java.lang.Object
|
+--com.beasys.commerce.axiom.reasoning.rules.service.ServiceProviderManager
- public class ServiceProviderManager
- extends java.lang.Object
Implements a rules service provider manager
Constructor Summary |
ServiceProviderManager(int rulesetExpirationPolicy,
long rulesetExpirationAge,
java.lang.String rulesheetDirectory,
java.util.Map mimeTypesMap,
java.util.Map mimeTypeHandlersMap,
java.lang.String vendorIndependentMimeType,
javax.naming.Context jndiContext,
java.lang.String rulesetDataHomeName)
Constructor |
Method Summary |
Context |
createContext(java.lang.String rulesetURI)
Creates a context for the given rule set uri |
Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
DIRECTORY_RELATIVE_URI_LEADING_STRING
public static final java.lang.String DIRECTORY_RELATIVE_URI_LEADING_STRING
- The leading character(s) of a ruleset-directory-relative uri
FILE_PROTOCOL
public static final java.lang.String FILE_PROTOCOL
- The protocol string for file uri's
HOST_DELIMITER
public static final java.lang.String HOST_DELIMITER
- The delimiter string used after the host in a uri
PROTOCOL_DELIMITER
public static final java.lang.String PROTOCOL_DELIMITER
- The delimiter string used after the protocol in a uri
URI_EXTENSION_DELIMITER
public static final char URI_EXTENSION_DELIMITER
- The character used to delimit a uri extension
XML_EXTENSION
public static final java.lang.String XML_EXTENSION
- The file extension for xml files
ServiceProviderManager
public ServiceProviderManager(int rulesetExpirationPolicy,
long rulesetExpirationAge,
java.lang.String rulesheetDirectory,
java.util.Map mimeTypesMap,
java.util.Map mimeTypeHandlersMap,
java.lang.String vendorIndependentMimeType,
javax.naming.Context jndiContext,
java.lang.String rulesetDataHomeName)
throws java.lang.IllegalArgumentException,
RulesServiceException
- Constructor
- Parameters:
rulesetExpirationPolicy
- The rule set expiration policyrulesetExpirationAge
- The age in milliseconds at which rulesets should
be expired. Ignored if rulesetExpirationPolicy is not
EXPIRE_RULE_SET_AT_AGErulesheetDirectory
- The rulesheet deployment directorymimeTypesMap
- The map of uri extensions to mime typesmimeTypeHandlersMap
- The map of mime types to mime type handlersvendorIndependentMimeType
- The vendor independent, xml-based mime typejndiContext
- The jndi context to use for lookups- Throws:
- java.lang.IllegalArgumentException - Thrown if:
1. rulesetExpirationPolicy is invalid
2. rulesetExpirationPolicy is EXPIRE_RULE_SET_AT_AGE and rulesetExpirationAge
is negative
3. mimeTypesMap is null
4. mimeTypeHandlersMap is null
5. vendorIndependentMimeType is null or zero-length
6. jndiContext is null
7. rulesetDataHomeName is null or zero-length
- RulesServiceException -
createContext
public Context createContext(java.lang.String rulesetURI)
throws RulesServiceException
- Creates a context for the given rule set uri
- Parameters:
rulesetURI
- The rule set uri for which a context is to be created- Returns:
- The new context
- Throws:
- java.lang.IllegalArgumentException - Thrown if rulesetURI is null
- RulesServiceException - Thrown if unable to create the context
TODO:
1. Improve no-service-provider-found code
Copyright © 2000 BEA Systems, Inc. All Rights Reserved