daoexamples.movie
Class MovieUtil
java.lang.Object
daoexamples.movie.MovieUtil
- public final class MovieUtil
- extends java.lang.Object
utilities for the Movie DAO package
- Author:
- Sean C. Sullivan
Field Summary |
private static org.apache.commons.logging.Log |
log
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
log
private static final org.apache.commons.logging.Log log
MovieUtil
private MovieUtil()
getUniqueMovieId
public static java.lang.String getUniqueMovieId(java.sql.Connection conn)
throws java.sql.SQLException
- Throws:
java.sql.SQLException
setupMovieTable
public static void setupMovieTable()
throws java.sql.SQLException
- Throws:
java.sql.SQLException
getNonXADBConnection
public static java.sql.Connection getNonXADBConnection()
getXADBConnection
public static java.sql.Connection getXADBConnection()
closeJDBCConnection
public static void closeJDBCConnection(java.sql.Connection conn)
closeStatement
public static void closeStatement(java.sql.Statement stmt)
closeResultSet
public static void closeResultSet(java.sql.ResultSet rs)
getUserTransaction
public static javax.transaction.UserTransaction getUserTransaction()
lookup
public static java.lang.Object lookup(java.lang.String name)
getInitialContext
public static javax.naming.Context getInitialContext()
narrow
public static java.lang.Object narrow(java.lang.Object obj,
java.lang.Class clazz)
makeMovieObjectsFromResultSet
public static java.util.Collection makeMovieObjectsFromResultSet(java.sql.ResultSet rs)
throws java.sql.SQLException
- Parameters:
rs
- must be non-null
- Returns:
- a Collection containing zero or more
Movie
objects
- Throws:
java.sql.SQLException
Copyright © 2003-2004 daoexamples.sourceforge.net. All Rights Reserved.