Java Reference
In-Depth Information
finally
{
cleanup( conn, ps );
}
}
public String ejbFindByPrimaryKey( String clientID )
throws ObjectNotFoundException
{
Connection conn = null;
PreparedStatement ps = null;
try
{
conn = getConnection();
ps = conn.prepareStatement( "select state from workflows " +
" where clientid = ?" );
ps.setString( 1, clientID );
ps.executeQuery();
ResultSet rs = ps.getResultSet();
if( rs.next() )
{
state = rs.getInt( 1 );
}
else
{
throw new ObjectNotFoundException( "No EJB Found" );
}
}
catch( Exception e )
{
throw new EJBException ( e );
}
finally
{
cleanup( conn, ps );
}
return clientID;
}
public void setEntityContext( EntityContext ctx )
{
this.ctx = ctx;
}
public void unsetEntityContext()
{
this.ctx = null;
}
public void ejbActivate()
Search WWH ::




Custom Search