Categories:
Audio (13)
Biotech (29)
Bytecode (36)
Database (77)
Framework (7)
Game (7)
General (507)
Graphics (53)
I/O (35)
IDE (2)
JAR Tools (102)
JavaBeans (21)
JDBC (121)
JDK (426)
JSP (20)
Logging (108)
Mail (58)
Messaging (8)
Network (84)
PDF (97)
Report (7)
Scripting (84)
Security (32)
Server (121)
Servlet (26)
SOAP (24)
Testing (54)
Web (15)
XML (322)
Collections:
Other Resources:
jTDS JDBC Driver Source Code Files
jTDS JDBC Driver Source Code Files are provided in the
source package file, jtds-1.3.1-fyi.zip.
You can browse jTDS JDBC Driver Source Code files below:
✍: FYIcenter.com
⏎ net/sourceforge/jtds/jdbcx/JtdsObjectFactory.java
// jTDS JDBC Driver for Microsoft SQL Server and Sybase
// Copyright (C) 2004 The jTDS Project
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 2.1 of the License, or (at your option) any later version.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
package net.sourceforge.jtds.jdbcx;
import java.util.Enumeration;
import java.util.HashMap;
import java.util.Hashtable;
import javax.naming.Context;
import javax.naming.Name;
import javax.naming.RefAddr;
import javax.naming.Reference;
import javax.naming.spi.ObjectFactory;
import net.sourceforge.jtds.jdbc.Driver;
import net.sourceforge.jtds.jdbc.Messages;
/**
* Description
*
* @author
* Alin Sinplean, Holger Rehn
*
* @since
* 0.3
*/
public class JtdsObjectFactory implements ObjectFactory
{
/**
*
*/
public Object getObjectInstance( Object refObj, Name name, Context nameCtx, Hashtable env )
throws Exception
{
Reference ref = (Reference) refObj;
if( ref.getClassName().equals( JtdsDataSource.class.getName() ) )
{
HashMap props = loadProps( ref, new String[]
{
JtdsDataSource.DESCRIPTION,
Driver.APPNAME,
Driver.AUTOCOMMIT,
Driver.BATCHSIZE,
Driver.BINDADDRESS,
Driver.BUFFERDIR,
Driver.BUFFERMAXMEMORY,
Driver.BUFFERMINPACKETS,
Driver.CACHEMETA,
Driver.CHARSET,
Driver.DATABASENAME,
Driver.DOMAIN,
Driver.INSTANCE,
Driver.LANGUAGE,
Driver.LASTUPDATECOUNT,
Driver.LOBBUFFER,
Driver.LOGFILE,
Driver.LOGINTIMEOUT,
Driver.MACADDRESS,
Driver.MAXSTATEMENTS,
Driver.NAMEDPIPE,
Driver.PACKETSIZE,
Driver.PASSWORD,
Driver.PORTNUMBER,
Driver.PREPARESQL,
Driver.PROGNAME,
Driver.SERVERNAME,
Driver.SERVERTYPE,
Driver.SOTIMEOUT,
Driver.SOKEEPALIVE,
Driver.PROCESSID,
Driver.SSL,
Driver.TCPNODELAY,
Driver.TDS,
Driver.USECURSORS,
Driver.USEJCIFS,
Driver.USENTLMV2,
Driver.USEKERBEROS,
Driver.USELOBS,
Driver.USER,
Driver.SENDSTRINGPARAMETERSASUNICODE,
Driver.WSID,
Driver.XAEMULATION
} );
return new JtdsDataSource( props );
}
return null;
}
private HashMap loadProps( Reference ref, String[] props )
{
HashMap config = new HashMap();
HashMap values = new HashMap();
Enumeration c = ref.getAll();
while( c.hasMoreElements() )
{
RefAddr ra = (RefAddr) c.nextElement();
values.put( ra.getType().toLowerCase(), ra.getContent() );
}
for( int i = 0; i < props.length; i ++ )
{
String value = (String) values.get( props[i].toLowerCase() );
value = value == null ? (String) values.get( Messages.get( props[i].toLowerCase() ) ) : value;
if( value != null )
{
config.put( props[i], value );
}
}
return config;
}
}⏎ net/sourceforge/jtds/jdbcx/JtdsObjectFactory.java
Or download all of them as a single archive file:
File name: jtds-1.3.1-fyi.zip File size: 323160 bytes Release date: 2013-06-08 Download
⇐ What Is jtds-1.3.1-dist.zip?
2016-11-26, ≈23🔥, 0💬
Popular Posts:
JRE 8 rt.jar is the JAR file for JRE 8 RT (Runtime) libraries. JRE (Java Runtime) 8 is the runtime e...
Apache Neethi provides general framework for the programmers to use WS Policy. It is compliant with ...
What Is poi-5.2.3.jar? poi-5.2.3.jar is one of the JAR files for Apache POI 5.2.3, which provides an...
Woodstox 6.4.0 Source Code Files are provided at the Woodstox GitHub Website . You can download them...
How to download and install JDK (Java Development Kit) 6? If you want to write Java applications, yo...