01: /*
02: * Copyright 2001-2007 Geert Bevin <gbevin[remove] at uwyn dot com>
03: * Distributed under the terms of either:
04: * - the common development and distribution license (CDDL), v1.0; or
05: * - the GNU Lesser General Public License, v2.1 or later
06: * $Id: org_firebirdsql_jdbc_FBDriver.java 3634 2007-01-08 21:42:24Z gbevin $
07: */
08: package com.uwyn.rife.scheduler.schedulermanagers.databasedrivers;
09:
10: import com.uwyn.rife.database.Datasource;
11: import com.uwyn.rife.scheduler.exceptions.SchedulerManagerException;
12:
13: public class org_firebirdsql_jdbc_FBDriver extends generic {
14: public org_firebirdsql_jdbc_FBDriver(Datasource datasource) {
15: super (datasource);
16: }
17:
18: public boolean install() throws SchedulerManagerException {
19: int poolsize = getDatasource().getPoolsize();
20:
21: getDatasource().setPoolsize(0);
22: try {
23: super .install();
24: } finally {
25: getDatasource().setPoolsize(poolsize);
26: }
27:
28: return true;
29: }
30:
31: public boolean remove() throws SchedulerManagerException {
32: int poolsize = getDatasource().getPoolsize();
33:
34: getDatasource().setPoolsize(0);
35: try {
36: super .remove();
37: } finally {
38: getDatasource().setPoolsize(poolsize);
39: }
40:
41: return true;
42: }
43: }
|