source: src/main/java/weka/gui/sql/DbUtils.java @ 16

Last change on this file since 16 was 4, checked in by gnappo, 14 years ago

Import di weka.

File size: 1.9 KB
Line 
1/*
2 *    This program is free software; you can redistribute it and/or modify
3 *    it under the terms of the GNU General Public License as published by
4 *    the Free Software Foundation; either version 2 of the License, or
5 *    (at your option) any later version.
6 *
7 *    This program is distributed in the hope that it will be useful,
8 *    but WITHOUT ANY WARRANTY; without even the implied warranty of
9 *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
10 *    GNU General Public License for more details.
11 *
12 *    You should have received a copy of the GNU General Public License
13 *    along with this program; if not, write to the Free Software
14 *    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
15 */
16
17/*
18 * DbUtils.java
19 * Copyright (C) 2005 University of Waikato, Hamilton, New Zealand
20 *
21 */
22
23package weka.gui.sql;
24
25import weka.core.RevisionUtils;
26import weka.experiment.DatabaseUtils;
27
28import java.sql.Connection;
29
30/**
31 * A little bit extended DatabaseUtils class.
32 *
33 * @see       DatabaseUtils
34 * @see       #execute(String)
35 * @author    FracPete (fracpete at waikato dot ac dot nz)
36 * @version   $Revision: 1.4 $
37 */
38public class DbUtils
39  extends DatabaseUtils {
40
41  /** for serialization. */
42  private static final long serialVersionUID = 103748569037426479L;
43 
44  /**
45   * initializes the object.
46   *
47   * @throws Exception      in case something goes wrong in the init of the
48   *                        DatabaseUtils constructor
49   * @see     DatabaseUtils
50   */
51  public DbUtils() throws Exception {
52    super();
53  }
54 
55  /**
56   * returns the current database connection.
57   *
58   * @return        the current connection instance
59   */
60  public Connection getConnection() {
61    return m_Connection;
62  }
63 
64  /**
65   * Returns the revision string.
66   *
67   * @return            the revision
68   */
69  public String getRevision() {
70    return RevisionUtils.extract("$Revision: 1.4 $");
71  }
72}
Note: See TracBrowser for help on using the repository browser.