Skip to Content.
Sympa Menu

freetds - DriverInfo class updated

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Edson Richter - Via Ápia <richter AT viaapia.com.br>
  • To: "TDS Development Group" <freetds AT franklin.oit.unc.edu>
  • Subject: DriverInfo class updated
  • Date: Wed, 2 Aug 2000 13:03:23 -0300

To easy the life of our users, I had updated this class, so this generates a output.txt file with all info...
 
Edson Richter
 
//
// Copyright 1998, 1999 CDS Networks, Inc., Medford Oregon
//
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are met:
// 1. Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// 2. Redistributions in binary form must reproduce the above copyright
// notice, this list of conditions and the following disclaimer in the
// documentation and/or other materials provided with the distribution.
// 3. All advertising materials mentioning features or use of this software
// must display the following acknowledgement:
// This product includes software developed by CDS Networks, Inc.
// 4. The name of CDS Networks, Inc. may not be used to endorse or promote
// products derived from this software without specific prior
// written permission.
//
// THIS SOFTWARE IS PROVIDED BY CDS NETWORKS, INC. ``AS IS'' AND
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
// ARE DISCLAIMED. IN NO EVENT SHALL CDS NETWORKS, INC. BE LIABLE
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
// SUCH DAMAGE.
//

package com.internetcds.jdbc.tds;

/**
* Print out informations about FreeTDS driver, and other usefull information
*
* @version $Revision: $
* @author Edson Carlos Ericksson Richter
*/

public class DriverInfo {
public static void main( String [] args ) {

try {
java.io.BufferedReader br = new
java.io.BufferedReader( new java.io.FileReader( "version_info.txt" ) );

try {
while( true )
System.out.println( br.readLine( ) );
} catch( java.io.IOException ioE ) {};
} catch( java.io.FileNotFoundException ioFNF ) {
System.err.println( "Info file cannot be found!!!" );
ioFNF.printStackTrace( System.err );
}

System.getProperties( ).list( System.out );

String outFile = "output.txt";
java.io.PrintWriter outObj;

try {
outObj = new java.io.PrintWriter( new
java.io.FileWriter( outFile, true ), true );
System.err.println( );
System.err.println( " *** All this info can be
found into " + outFile + " file." );
} catch( java.io.IOException e ) {
System.err.println( "Cannot open output file: " +
outFile );
e.printStackTrace( );
System.err.println( "Log redirecionado para o
System.err.");
outObj = new java.io.PrintWriter( System.err );
}

System.getProperties( ).list( outObj );
}
}


  • DriverInfo class updated, Edson Richter - Via Ápia, 08/02/2000

Archive powered by MHonArc 2.6.24.

Top of Page