01: // You can redistribute this software and/or modify it under the terms of
02: // the Infozone Software License version 2 published by the Infozone Group
03: // (http://www.infozone-group.org).
04: //
05: // Copyright (C) @year@ by The Infozone Group. All rights reserved.
06: //
07: // $Id: XUpdateQueryFactory.java,v 1.1 2002/05/10 08:59:12 per_nyfelt Exp $
08:
09: package org.infozone.tools.xml.queries;
10:
11: import javax.xml.parsers.FactoryConfigurationError;
12:
13: /**
14: * @version $Revision: 1.1 $ $Date: 2002/05/10 08:59:12 $
15: * @author <a href="http://www.softwarebuero.de">SMB</a>
16: * @see XUpdateQuery
17: */
18: public abstract class XUpdateQueryFactory {
19:
20: public XUpdateQueryFactory() {
21: }
22:
23: public static XUpdateQueryFactory newInstance() {
24: String factoryName = System.getProperty(
25: "org.infozone.tools.xml.queries.XUpdateQueryFactory",
26: "org.infozone.lexus.XUpdateQueryFactoryImpl");
27:
28: XUpdateQueryFactory factory = null;
29:
30: try {
31: Class clazz = Class.forName(factoryName);
32: factory = (XUpdateQueryFactory) clazz.newInstance();
33: } catch (ClassNotFoundException cnfe) {
34: throw new FactoryConfigurationError(cnfe);
35: } catch (IllegalAccessException iae) {
36: throw new FactoryConfigurationError(iae);
37: } catch (InstantiationException ie) {
38: throw new FactoryConfigurationError(ie);
39: }
40: return factory;
41: }
42:
43: public abstract XUpdateQuery newXUpdateQuery()
44: throws XUpdateQueryConfigurationException;
45:
46: }
|