com.acme
Class MockDataSource

java.lang.Object
  extended by com.acme.MockDataSource
All Implemented Interfaces:
DataSource

public class MockDataSource
extends Object
implements DataSource

MockDataSource


Constructor Summary
MockDataSource()
           
 
Method Summary
 Connection getConnection()
           
 Connection getConnection(String username, String password)
           
 int getLoginTimeout()
           
 PrintWriter getLogWriter()
           
 void setLoginTimeout(int seconds)
           
 void setLogWriter(PrintWriter out)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MockDataSource

public MockDataSource()
Method Detail

getConnection

public Connection getConnection()
                         throws SQLException
Specified by:
getConnection in interface DataSource
Throws:
SQLException
See Also:
DataSource.getConnection()

getConnection

public Connection getConnection(String username,
                                String password)
                         throws SQLException
Specified by:
getConnection in interface DataSource
Throws:
SQLException
See Also:
DataSource.getConnection(java.lang.String, java.lang.String)

getLogWriter

public PrintWriter getLogWriter()
                         throws SQLException
Specified by:
getLogWriter in interface DataSource
Throws:
SQLException
See Also:
DataSource.getLogWriter()

getLoginTimeout

public int getLoginTimeout()
                    throws SQLException
Specified by:
getLoginTimeout in interface DataSource
Throws:
SQLException
See Also:
DataSource.getLoginTimeout()

setLogWriter

public void setLogWriter(PrintWriter out)
                  throws SQLException
Specified by:
setLogWriter in interface DataSource
Throws:
SQLException
See Also:
DataSource.setLogWriter(java.io.PrintWriter)

setLoginTimeout

public void setLoginTimeout(int seconds)
                     throws SQLException
Specified by:
setLoginTimeout in interface DataSource
Throws:
SQLException
See Also:
DataSource.setLoginTimeout(int)


Copyright © 2008 Mort Bay Consulting. All Rights Reserved.