juergen 01/02/21 08:39:13
Modified: src/share/org/apache/slide/store AbstractStore.java
Log:
If the child stores (e.g. contentStore) was not specified in domain.xml, the
setParameters method was never called. Now it is called with the store parameters.
Revision Changes Path
1.10 +12 -13
jakarta-slide/src/share/org/apache/slide/store/AbstractStore.java
Index: AbstractStore.java
===================================================================
RCS file:
/home/cvs/jakarta-slide/src/share/org/apache/slide/store/AbstractStore.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- AbstractStore.java 2001/01/23 16:50:03 1.9
+++ AbstractStore.java 2001/02/21 16:39:12 1.10
@@ -1,7 +1,7 @@
/*
- * $Header:
/home/cvs/jakarta-slide/src/share/org/apache/slide/store/AbstractStore.java,v 1.9
2001/01/23 16:50:03 juergen Exp $
- * $Revision: 1.9 $
- * $Date: 2001/01/23 16:50:03 $
+ * $Header:
/home/cvs/jakarta-slide/src/share/org/apache/slide/store/AbstractStore.java,v 1.10
2001/02/21 16:39:12 juergen Exp $
+ * $Revision: 1.10 $
+ * $Date: 2001/02/21 16:39:12 $
*
* ====================================================================
*
@@ -88,7 +88,7 @@
* Abstract implementation of a store. Handles all caching operations.
*
* @author <a href="mailto:[EMAIL PROTECTED]">Remy Maucherat</a>
- * @version $Revision: 1.9 $
+ * @version $Revision: 1.10 $
*/
public abstract class AbstractStore extends AbstractSimpleService
implements Store {
@@ -171,15 +171,11 @@
}
-
+
+ private Hashtable parameters = null;
+
/**
- * Initializes the descriptors store with a set of parameters.
- * Those could be :
- * <li>User name, login info
- * <li>Host name on which to connect
- * <li>Remote port
- * <li>JDBC driver whoich is to be used :-)
- * <li>Anything else ...
+ * Remeber the store parameters to initialise the default child stores on
request
*
* @param parameters Hashtable containing the parameters' name
* and associated value
@@ -189,6 +185,7 @@
public void setParameters(Hashtable parameters)
throws ServiceParameterErrorException,
ServiceParameterMissingException {
+ this.parameters = parameters;
}
@@ -996,7 +993,8 @@
try {
defaultStoreInstance =
- (Service) Class.forName(defaultStore).newInstance();
+ (Service)Class.forName(defaultStore).newInstance();
+ defaultStoreInstance.setParameters(this.parameters);
} catch (Throwable t) {
// Should never happen ...
t.printStackTrace();
@@ -1139,3 +1137,4 @@
}
+