Skip to content

Commit

Permalink
Add OlapDataSource interface.
Browse files Browse the repository at this point in the history
git-svn-id: https://olap4j.svn.sourceforge.net/svnroot/olap4j/trunk@81 c6a108a4-781c-0410-a6c6-c2d559e19af0
  • Loading branch information
julianhyde committed Mar 26, 2008
1 parent af33fc9 commit 6a62a7d
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 2 deletions.
8 changes: 6 additions & 2 deletions doc/olap4j_fs.html
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ <h1>olap4j Specification</h1>
Version: 0.9.5 (beta)<br>
Revision: $Id$
(<a href="http://olap4j.svn.sourceforge.net/viewvc/olap4j/trunk/doc/olap4j_fs.html?view=log">log</a>)<br>
Last modified: March 5<sup>th</sup>, 2008.</p>
Last modified: March 25<sup>th</sup>, 2008.</p>
<hr noshade="noshade">

<h2><a name="Contents">Contents</a></h2>
Expand All @@ -109,6 +109,7 @@ <h2><a name="Contents">Contents</a></h2>
<li><a href="#The_Driver_class">The Driver class</a></li>
<li><a href="#The_DriverManager_class">The DriverManager class</a></li>
<li><a href="#The_DataSource_interface">The DataSource interface</a></li>
<li><a href="#The_OlapDataSource_interface">The OlapDataSource interface</a></li>
<li><a href="#The_OlapException_class">The OlapException class</a></li>
</ol>
</li>
Expand Down Expand Up @@ -469,7 +470,10 @@ <h4>2.1.2. <a name="The_DriverManager_class">The DriverManager class</a></h4>
<p>Same functionality as JDBC.</p>
<h4>2.1.3. <a name="The_DataSource_interface">The DataSource interface</a></h4>
<p>Same functionality as JDBC.</p>
<h4>2.1.4 <a name="The_OlapException_class">The OlapException class</a></h4>
<h4>2.1.4. <a name="The_OlapDataSource_interface">The OlapDataSource interface</a></h4>
<p>Extension to <code>DataSource</code> that returns <code>OlapConnection</code>
objects rather than mere <code>java.sql.Connection</code> objects.</p>
<h4>2.1.5. <a name="The_OlapException_class">The OlapException class</a></h4>
<p><a class="javadoc" href="api/org/olap4j/OlapException.html">OlapException</a>
(extends
<a class="javadoc" href="http://java.sun.com/javase/6/docs/api/java/sql/SQLException.html">
Expand Down
39 changes: 39 additions & 0 deletions src/org/olap4j/OlapDataSource.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
/*
// This software is subject to the terms of the Common Public License
// Agreement, available at the following URL:
// http://www.opensource.org/licenses/cpl.html.
// Copyright (C) 2008-2008 Julian Hyde
// All Rights Reserved.
// You must accept the terms of that agreement to use this software.
*/
package org.olap4j;

import javax.sql.DataSource;
import java.sql.SQLException;

/**
* <p>A factory for connections to the physical OLAP data source that this
* <code>OlapDataSource</code> object represents.
*
* <p><code>OlapDataSource</code> is a refinement of
* {@link javax.sql.DataSource} whose <code>getConnection</code> methods
* return {@link org.olap4j.OlapConnection} objects rather than mere
* {@link java.sql.Connection}s.
*
* @author jhyde
* @version $Id: $
* @since Mar 25, 2008
*/
public interface OlapDataSource extends DataSource {

// override with more specific return type
OlapConnection getConnection() throws SQLException;

// override with more specific return type
OlapConnection getConnection(
String username,
String password)
throws SQLException;
}

// End OlapDataSource.java

0 comments on commit 6a62a7d

Please sign in to comment.