1 22 23 package org.xquark.mapper; 24 25 import org.xquark.xml.xdbc.XMLDBCException; 26 import org.xquark.xml.xdbc.XMLDriverManager; 27 28 33 final public class AccessManager 34 { 35 private static final String RCSRevision = "$Revision: 1.1 $"; 36 private static final String RCSName = "$Name: $"; 37 38 static 39 { 40 try 41 { 42 Class.forName("org.xquark.mapper.RepositoryDriver"); 43 } 44 catch (ClassNotFoundException e) 45 { 46 } 48 } 49 50 52 private AccessManager() {} 53 54 71 public static synchronized RepositoryConnection connect(String URL, String user, String password) 72 throws XMLDBCException 73 { 74 return (RepositoryConnection)XMLDriverManager.getConnection( 75 RepositoryDriver.REPOSITORY_URL_PREFIX + URL, 76 user, 77 password 78 ); 79 } 80 } 81 | Popular Tags |