01: /* Copyright 2002 The JA-SIG Collaborative. All rights reserved.
02: * See license distributed with this file and
03: * available online at http://www.uportal.org/license.html
04: */
05:
06: package org.jasig.portal.groups;
07:
08: import org.apache.commons.logging.Log;
09: import org.apache.commons.logging.LogFactory;
10:
11: /**
12: * Creates an instance of the reference <code>IEntityStore</code>.
13: * @author Dan Ellentuck
14: * @version $Revision: 35418 $
15: */
16:
17: public class ReferenceEntityStoreFactory implements IEntityStoreFactory {
18:
19: private static final Log log = LogFactory
20: .getLog(ReferenceEntityStoreFactory.class);
21:
22: /**
23: * ReferenceGroupServiceFactory constructor.
24: */
25: public ReferenceEntityStoreFactory() {
26: super ();
27: }
28:
29: /**
30: * Return an instance of the entity store implementation.
31: * @return IEntityStore
32: * @exception GroupsException
33: */
34: public IEntityStore newEntityStore() throws GroupsException {
35: return newInstance();
36: }
37:
38: /**
39: * Return an instance of the entity store implementation.
40: * @return IEntityStore
41: * @exception GroupsException
42: */
43: public IEntityStore newInstance() throws GroupsException {
44: try {
45: return new RDBMEntityStore();
46: } catch (Exception ex) {
47: log.error("ReferenceEntityStoreFactory.newInstance(): "
48: + ex);
49: throw new GroupsException(ex);
50: }
51: }
52: }
|