📄 jtdsdatasource.java
字号:
public String getDomain() {
return domain;
}
public void setDomain(String domain) {
this.domain = domain;
}
public String getUseNTLMV2() {
return useNTLMV2;
}
public void setUseNTLMV2(String usentlmv2) {
this.useNTLMV2 = usentlmv2;
}
public String getInstance() {
return instance;
}
public void setInstance(String instance) {
this.instance = instance;
}
public boolean getSendStringParametersAsUnicode() {
return Boolean.valueOf(sendStringParametersAsUnicode).booleanValue();
}
public void setSendStringParametersAsUnicode(boolean sendStringParametersAsUnicode) {
this.sendStringParametersAsUnicode = String.valueOf(sendStringParametersAsUnicode);
}
public boolean getNamedPipe() {
return Boolean.valueOf(namedPipe).booleanValue();
}
public void setNamedPipe(boolean namedPipe) {
this.namedPipe = String.valueOf(namedPipe);
}
public boolean getLastUpdateCount() {
return Boolean.valueOf(lastUpdateCount).booleanValue();
}
public void setLastUpdateCount(boolean lastUpdateCount) {
this.lastUpdateCount = String.valueOf(lastUpdateCount);
}
public boolean getXaEmulation() {
return Boolean.valueOf(xaEmulation).booleanValue();
}
public void setXaEmulation(boolean xaEmulation) {
this.xaEmulation = String.valueOf(xaEmulation);
}
public String getCharset() {
return charset;
}
public void setCharset(String charset) {
this.charset = charset;
}
public String getLanguage() {
return language;
}
public void setLanguage(String language) {
this.language = language;
}
public String getMacAddress() {
return macAddress;
}
public void setMacAddress(String macAddress) {
this.macAddress = macAddress;
}
public void setPacketSize(int packetSize) {
this.packetSize = String.valueOf(packetSize);
}
public int getPacketSize() {
if (packetSize == null) {
return 0;
}
return Integer.parseInt(packetSize);
}
public boolean getTcpNoDelay() {
return Boolean.valueOf(tcpNoDelay).booleanValue();
}
public void setTcpNoDelay(boolean tcpNoDelay) {
this.tcpNoDelay = String.valueOf(tcpNoDelay);
}
public void setPrepareSql(int prepareSql) {
this.prepareSql = String.valueOf(prepareSql);
}
public int getPrepareSql() {
if (prepareSql == null) {
return 0;
}
return Integer.parseInt(prepareSql);
}
public void setLobBuffer(long lobBuffer) {
this.lobBuffer = String.valueOf(lobBuffer);
}
public long getLobBuffer() {
if (lobBuffer == null) {
return 0;
}
return Long.parseLong(lobBuffer);
}
public void setMaxStatements(int maxStatements) {
this.maxStatements = String.valueOf(maxStatements);
}
public int getMaxStatements() {
if (maxStatements == null) {
return 0;
}
return Integer.parseInt(maxStatements);
}
public void setAppName(String appName) {
this.appName = appName;
}
public String getAppName() {
return appName;
}
public void setProgName(String progName) {
this.progName = progName;
}
public String getProgName() {
return progName;
}
public void setWsid(String wsid) {
this.wsid = wsid;
}
public String getWsid() {
return wsid;
}
public void setLogFile(String logFile) {
this.logFile = logFile;
}
public String getLogFile() {
return logFile;
}
public void setSsl(String ssl) {
this.ssl = ssl;
}
public String getSsl() {
return ssl;
}
public void setBatchSize(int batchSize) {
this.batchSize = String.valueOf(batchSize);
}
public int getBatchSize() {
if (batchSize == null) {
return 0;
}
return Integer.parseInt(batchSize);
}
public String getBufferDir() {
if (bufferDir == null) {
return System.getProperty("java.io.tmpdir");
}
return bufferDir;
}
public void setBufferDir(String bufferDir) {
this.bufferDir = bufferDir;
}
public int getBufferMaxMemory() {
if (bufferMaxMemory == null) {
return 0;
}
return Integer.parseInt(bufferMaxMemory);
}
public void setBufferMaxMemory(int bufferMaxMemory) {
this.bufferMaxMemory = String.valueOf(bufferMaxMemory);
}
public int getBufferMinPackets() {
if (bufferMinPackets == null) {
return 0;
}
return Integer.parseInt(bufferMinPackets);
}
public void setBufferMinPackets(int bufferMinPackets) {
this.bufferMinPackets = String.valueOf(bufferMinPackets);
}
public boolean getCacheMetaData() {
return Boolean.valueOf(cacheMetaData).booleanValue();
}
public void setCacheMetaData(boolean cacheMetaData) {
this.cacheMetaData = String.valueOf(cacheMetaData);
}
public boolean getUseCursors() {
return Boolean.valueOf(useCursors).booleanValue();
}
public void setUseCursors(boolean useCursors) {
this.useCursors = String.valueOf(useCursors);
}
public boolean getUseLOBs() {
return Boolean.valueOf(useLOBs).booleanValue();
}
public void setUseLOBs(boolean useLOBs) {
this.useLOBs = String.valueOf(useLOBs);
}
public String getBindAddress() {
return bindAddress;
}
public void setBindAddress(String bindAddress) {
this.bindAddress = bindAddress;
}
public boolean getUseJCIFS() {
return Boolean.valueOf(useJCIFS).booleanValue();
}
public void setUseJCIFS(boolean useJCIFS) {
this.useJCIFS = String.valueOf(useJCIFS);
}
private void addNonNullProperties(Properties props, String user, String password) {
props.setProperty(Messages.get(Driver.SERVERNAME), serverName);
if (serverType != null) {
props.setProperty(Messages.get(Driver.SERVERTYPE), serverType);
}
if (portNumber != null) {
props.setProperty(Messages.get(Driver.PORTNUMBER), portNumber);
}
if (databaseName != null) {
props.setProperty(Messages.get(Driver.DATABASENAME), databaseName);
}
if (tdsVersion != null) {
props.setProperty(Messages.get(Driver.TDS), tdsVersion);
}
if (charset != null) {
props.setProperty(Messages.get(Driver.CHARSET), charset);
}
if (language != null) {
props.setProperty(Messages.get(Driver.LANGUAGE), language);
}
if (domain != null) {
props.setProperty(Messages.get(Driver.DOMAIN), domain);
}
if(useNTLMV2 != null) {
props.setProperty(Messages.get(Driver.USENTLMV2), useNTLMV2);
}
if (instance != null) {
props.setProperty(Messages.get(Driver.INSTANCE), instance);
}
if (lastUpdateCount != null) {
props.setProperty(Messages.get(Driver.LASTUPDATECOUNT), lastUpdateCount);
}
if (sendStringParametersAsUnicode != null) {
props.setProperty(Messages.get(Driver.SENDSTRINGPARAMETERSASUNICODE), sendStringParametersAsUnicode);
}
if (namedPipe != null) {
props.setProperty(Messages.get(Driver.NAMEDPIPE), namedPipe);
}
if (macAddress != null) {
props.setProperty(Messages.get(Driver.MACADDRESS), macAddress);
}
if (prepareSql != null) {
props.setProperty(Messages.get(Driver.PREPARESQL), prepareSql);
}
if (packetSize != null) {
props.setProperty(Messages.get(Driver.PACKETSIZE), packetSize);
}
if (tcpNoDelay != null) {
props.setProperty(Messages.get(Driver.TCPNODELAY), tcpNoDelay);
}
if (xaEmulation != null) {
props.setProperty(Messages.get(Driver.XAEMULATION), xaEmulation);
}
if (user != null) {
props.setProperty(Messages.get(Driver.USER), user);
}
if (password != null) {
props.setProperty(Messages.get(Driver.PASSWORD), password);
}
if (loginTimeout != null) {
props.setProperty(Messages.get(Driver.LOGINTIMEOUT), loginTimeout);
}
if (socketTimeout != null) {
props.setProperty(Messages.get(Driver.SOTIMEOUT), socketTimeout);
}
if (lobBuffer != null) {
props.setProperty(Messages.get(Driver.LOBBUFFER), lobBuffer);
}
if (maxStatements != null) {
props.setProperty(Messages.get(Driver.MAXSTATEMENTS), maxStatements);
}
if (appName != null) {
props.setProperty(Messages.get(Driver.APPNAME), appName);
}
if (progName != null) {
props.setProperty(Messages.get(Driver.PROGNAME), progName);
}
if (wsid != null) {
props.setProperty(Messages.get(Driver.WSID), wsid);
}
if (ssl != null) {
props.setProperty(Messages.get(Driver.SSL), ssl);
}
if (batchSize != null) {
props.setProperty(Messages.get(Driver.BATCHSIZE), batchSize);
}
if (bufferDir != null) {
props.setProperty(Messages.get(Driver.BUFFERDIR), bufferDir);
}
if (bufferMaxMemory != null) {
props.setProperty(Messages.get(Driver.BUFFERMAXMEMORY), bufferMaxMemory);
}
if (bufferMinPackets != null) {
props.setProperty(Messages.get(Driver.BUFFERMINPACKETS), bufferMinPackets);
}
if (cacheMetaData != null) {
props.setProperty(Messages.get(Driver.CACHEMETA), cacheMetaData);
}
if (useCursors != null) {
props.setProperty(Messages.get(Driver.USECURSORS), useCursors);
}
if (useLOBs != null) {
props.setProperty(Messages.get(Driver.USELOBS), useLOBs);
}
if (bindAddress != null) {
props.setProperty(Messages.get(Driver.BINDADDRESS), bindAddress);
}
if (useJCIFS != null) {
props.setProperty(Messages.get(Driver.USEJCIFS), useJCIFS);
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -