db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From arm...@apache.org
Subject cvs commit: db-ojb/src/java/org/apache/ojb/broker/accesslayer StatementManager.java
Date Wed, 12 Mar 2003 22:35:40 GMT
arminw      2003/03/12 14:35:40

  Modified:    src/java/org/apache/ojb/broker/accesslayer
                        StatementManager.java
  Log:
  restore version 1.25
  
  Revision  Changes    Path
  1.27      +658 -693  db-ojb/src/java/org/apache/ojb/broker/accesslayer/StatementManager.java
  
  Index: StatementManager.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/broker/accesslayer/StatementManager.java,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -r1.26 -r1.27
  --- StatementManager.java	12 Mar 2003 12:40:17 -0000	1.26
  +++ StatementManager.java	12 Mar 2003 22:35:40 -0000	1.27
  @@ -54,6 +54,17 @@
    * <http://www.apache.org/>.
    */
   
  +import java.sql.PreparedStatement;
  +import java.sql.ResultSet;
  +import java.sql.SQLException;
  +import java.sql.Statement;
  +import java.sql.Types;
  +import java.util.Collection;
  +import java.util.Enumeration;
  +import java.util.Iterator;
  +import java.util.Map;
  +import java.util.WeakHashMap;
  +
   import org.apache.ojb.broker.Identity;
   import org.apache.ojb.broker.PersistenceBroker;
   import org.apache.ojb.broker.PersistenceBrokerException;
  @@ -77,17 +88,6 @@
   import org.apache.ojb.broker.util.logging.Logger;
   import org.apache.ojb.broker.util.logging.LoggerFactory;
   
  -import java.sql.PreparedStatement;
  -import java.sql.ResultSet;
  -import java.sql.SQLException;
  -import java.sql.Statement;
  -import java.sql.Types;
  -import java.util.Collection;
  -import java.util.Enumeration;
  -import java.util.Iterator;
  -import java.util.Map;
  -import java.util.WeakHashMap;
  -
   /**
    * manages JDBC Connection and Statement resources.
    *
  @@ -96,702 +96,667 @@
    */
   public class StatementManager implements StatementManagerIF
   {
  -    private Logger log = LoggerFactory.getLogger(StatementManager.class);
  +	private Logger log = LoggerFactory.getLogger(StatementManager.class);
   
  -    /** internal table of StatementForClass objects */
  -    private Map statementTable = new WeakHashMap();
  -    /** the associated broker */
  -    private final PersistenceBroker broker;
  -    private Platform platform;
  -    /**
  -     * Used when OJB run in JBoss
  -     * @todo Find a better solution to handle OJB within JBoss
  -     * --> the JCA implementation should solve this problem
  -     */
  -    private boolean m_eagerRelease;
  -    private ConnectionManagerIF conMan;
  -
  -    public StatementManager(final PersistenceBroker pBroker)
  -    {
  -        this.broker = pBroker;
  -        this.conMan = broker.serviceConnectionManager();
  -        m_eagerRelease = conMan.getConnectionDescriptor().getEagerRelease();
  -        platform = PlatformFactory.getPlatformFor(conMan.getConnectionDescriptor());
  -    }
  +	/** internal table of StatementForClass objects */
  +	private Map statementTable = new WeakHashMap();
  +	/** the associated broker */
  +	private final PersistenceBroker broker;
  +	private Platform platform;
  +	/**
  +	 * Used when OJB run in JBoss
  +	 * @todo Find a better solution to handle OJB within JBoss
  +	 * --> the JCA implementation should solve this problem
  +	 */
  +	private boolean m_eagerRelease;
  +	private ConnectionManagerIF conMan;
  +
  +	public StatementManager(final PersistenceBroker pBroker)
  +	{
  +		this.broker = pBroker;
  +		this.conMan = broker.serviceConnectionManager();
  +		m_eagerRelease = conMan.getConnectionDescriptor().getEagerRelease();
  +		platform = PlatformFactory.getPlatformFor(conMan.getConnectionDescriptor());
  +	}
  +
  +	/**
  +	 * return a StatementsForClass object for the given ClassDescriptor\
  +	 * Note; not important to synchronize completely as a threading issue in this code
  +	 * will only result in a little extra code being executed
  +	 */
  +	protected StatementsForClassIF getStatementsForClass(ClassDescriptor cds) throws PersistenceBrokerException
  +	{
  +		StatementsForClassIF sfc = (StatementsForClassIF) statementTable.get(cds);
  +		if (sfc == null)
  +		{
  +			synchronized (statementTable)
  +			{
  +				sfc = (StatementsForClassIF) new StatementsForClassImpl(conMan.getConnectionDescriptor(),
cds);
  +				statementTable.put(cds, sfc);
  +			}
  +		}
  +		return sfc;
  +	}
  +
  +	public void closeResources(Statement stmt, ResultSet rs)
  +	{
  +		if (log.isDebugEnabled())
  +			log.debug("closeResources was called");
  +		try
  +		{
  +			platform.beforeStatementClose(stmt, rs);
  +			//close statement on wrapped statement class, or real statement
  +			if (stmt != null)
  +			{
  +				//log.info("## close: "+stmt);
  +				stmt.close();
   
  -    /**
  -     * return a StatementsForClass object for the given ClassDescriptor\
  -     * Note; not important to synchronize completely as a threading issue in this code
  -     * will only result in a little extra code being executed
  -     */
  -    protected StatementsForClassIF getStatementsForClass(ClassDescriptor cds) throws PersistenceBrokerException
  -    {
  -        StatementsForClassIF sfc = (StatementsForClassIF) statementTable.get(cds);
  -        if (sfc == null)
  -        {
  -            synchronized (statementTable)
  -            {
  -                sfc = (StatementsForClassIF) new StatementsForClassImpl(conMan.getConnectionDescriptor(),
cds);
  -                statementTable.put(cds, sfc);
  -            }
  -        }
  -        return sfc;
  -    }
  -
  -    public void closeResources(Statement stmt, ResultSet rs)
  -    {
  -        if (log.isDebugEnabled())
  -            log.debug("closeResources was called");
  -        try
  -        {
  -            platform.beforeStatementClose(stmt, rs);
  -            //close statement on wrapped statement class, or real statement
  -            if (stmt != null)
  -            {
  -                //log.info("## close: "+stmt);
  -                stmt.close();
  -
  -                /*
  +				/*
   				*********************************************
   				special stuff for OJB within JBoss
   				********************************************
   				*/
  -                if (m_eagerRelease)
  -                {
  -                    conMan.releaseConnection();
  -                }
  -
  -            }
  -            platform.afterStatementClose(stmt, rs);
  -        }
  -        catch (PlatformException e)
  -        {
  -            log.error("Platform dependent operation failed", e);
  -        }
  -        catch (SQLException ignored)
  -        {
  -            if (log.isDebugEnabled())
  -                log.debug("Statement closing failed", ignored);
  -        }
  -    }
  -
  -    /**
  -     * binds the Identities Primary key values to the statement
  -     */
  -    public void bindDelete(PreparedStatement stmt, Identity oid, ClassDescriptor cld) throws
java.sql.SQLException
  -    {
  -        Object[] values = null;
  -        int i = 0;
  -
  -        if (cld == null)
  -        {
  -            cld = broker.getClassDescriptor(oid.getObjectsClass());
  -        }
  -
  -        values = getKeyValues(broker, cld, oid);
  -
  -        try
  -        {
  -            for (i = 0; i < values.length; i++)
  -            {
  -                platform.setObjectForStatement(stmt, i + 1, values[i], SqlHelper.getSqlTypePk(cld,
i));
  -            }
  -        }
  -        catch (SQLException e)
  -        {
  -            log.error("bindDelete failed for: " + oid.toString() + ", PK: " + i + ", value:
" + values[i]);
  -            throw e;
  -        }
  -    }
  -
  -    /**
  -     * binds the objects primary key and locking values to the statement, BRJ
  -     */
  -    public void bindDelete(PreparedStatement stmt, ClassDescriptor cld, Object obj) throws
java.sql.SQLException
  -    {
  -        int index = 1;
  -        Object[] values, currentLockingValues;
  -
  -        currentLockingValues = cld.getCurrentLockingValues(obj);
  -
  -        // parameters for WHERE-clause pk
  -        values = getKeyValues(broker, cld, obj);
  -        for (int i = 0; i < values.length; i++)
  -        {
  -            platform.setObjectForStatement(stmt, index, values[i], SqlHelper.getSqlTypePk(cld,
i));
  -            index++;
  -        }
  -
  -        // parameters for WHERE-clause locking
  -        values = currentLockingValues;
  -        for (int i = 0; i < values.length; i++)
  -        {
  -            platform.setObjectForStatement(stmt, index, values[i], SqlHelper.getSqlTypeLocking(cld,
i));
  -            index++;
  -        }
  -    }
  -
  -    /**
  -     * bind a value
  -     * @param stmt the PreparedStatement
  -     * @param index the position of the parameter to bind
  -     * @param attributeName the query attribute to bind
  -     * @param value the value to bind
  -     * @param cld the ClassDescriptor
  -     * @return next index for PreparedStatement
  -     */
  -    private int bindStatementValue(PreparedStatement stmt, int index, Object value, ClassDescriptor
cld, FieldDescriptor fld)
  -            throws SQLException
  -    {
  -        // if value is a subQuery bind it
  -        if (value instanceof Query)
  -        {
  -            Query subQuery = (Query) value;
  -            if (subQuery.getCriteria() != null && !subQuery.getCriteria().isEmpty())
  -            {
  -                return bindStatement(stmt, subQuery.getCriteria(), cld.getRepository().getDescriptorFor(subQuery.getSearchClass()),
index);
  -            }
  -            return index;
  -        }
  -
  -        // if query has criteria, bind them
  -        if (fld != null)
  -        {
  -            // BRJ: use field conversions and platform
  -            if (value != null)
  -            {
  -                platform.setObjectForStatement(stmt, index, fld.getFieldConversion().javaToSql(value),
fld.getColumnJdbcType());
  -            }
  -            else
  -            {
  -                platform.setNullForStatement(stmt, index, fld.getColumnJdbcType());
  -            }
  -        }
  -        else
  -        {
  -            // BRJ: No FieldDescriptor found
  -            if (value != null)
  -            {
  -                stmt.setObject(index, value);
  -            }
  -            else
  -            {
  -                stmt.setNull(index, Types.NULL);
  -            }
  -        }
  -
  -        return ++index; // increment before return
  -    }
  -
  -    /**
  -     * bind SelectionCriteria
  -     * @param stmt the PreparedStatement
  -     * @param index the position of the parameter to bind
  -     * @param crit the Criteria containing the parameter
  -     * @param cld the ClassDescriptor
  -     * @return next index for PreparedStatement
  -     */
  -    private int bindStatement(PreparedStatement stmt, int index, SelectionCriteria crit,
ClassDescriptor cld) throws SQLException
  -    {
  -        FieldDescriptor fld = cld.getFieldDescriptorForPath(crit.getAttribute());
  -        return bindStatementValue(stmt, index, crit.getValue(), cld, fld);
  -    }
  -
  -    /**
  -     * bind NullCriteria
  -     * @param stmt the PreparedStatement
  -     * @param index the position of the parameter to bind
  -     * @param crit the Criteria containing the parameter
  -     * @return next index for PreparedStatement
  -     */
  -    private int bindStatement(PreparedStatement stmt, int index, NullCriteria crit) throws
SQLException
  -    {
  -        return index;
  -    }
  -
  -    /**
  -     * bind FieldCriteria
  -     * @param stmt , the PreparedStatement
  -     * @param index , the position of the parameter to bind
  -     * @param crit , the Criteria containing the parameter
  -     * @return next index for PreparedStatement
  -     */
  -    private int bindStatement(PreparedStatement stmt, int index, FieldCriteria crit) throws
SQLException
  -    {
  -        return index;
  -    }
  -
  -    /**
  -     * bind ColumnCriteria
  -     * @param stmt , the PreparedStatement
  -     * @param index , the position of the parameter to bind
  -     * @param crit , the Criteria containing the parameter
  -     * @return next index for PreparedStatement
  -     */
  -    private int bindStatement(PreparedStatement stmt, int index, ColumnCriteria crit) throws
SQLException
  -    {
  -        return index;
  -    }
  -
  -    /**
  -     * bind SqlCriteria
  -     * @param stmt the PreparedStatement
  -     * @param index the position of the parameter to bind
  -     * @param crit the Criteria containing the parameter
  -     * @return next index for PreparedStatement
  -     */
  -    private int bindStatement(PreparedStatement stmt, int index, SqlCriteria crit) throws
SQLException
  -    {
  -        return index;
  -    }
  -
  -    /**
  -     * bind BetweenCriteria
  -     * @param stmt the PreparedStatement
  -     * @param index the position of the parameter to bind
  -     * @param crit the Criteria containing the parameter
  -     * @param cld the ClassDescriptor
  -     * @return next index for PreparedStatement
  -     */
  -    private int bindStatement(PreparedStatement stmt, int index, BetweenCriteria crit,
ClassDescriptor cld) throws SQLException
  -    {
  -        FieldDescriptor fld = cld.getFieldDescriptorForPath(crit.getAttribute());
  -        index = bindStatementValue(stmt, index, crit.getValue(), cld, fld);
  -        return bindStatementValue(stmt, index, crit.getValue2(), cld, fld);
  -    }
  -
  -    /**
  -     * bind InCriteria
  -     * @param stmt the PreparedStatement
  -     * @param index the position of the parameter to bind
  -     * @param crit the Criteria containing the parameter
  -     * @param cld the ClassDescriptor
  -     * @return next index for PreparedStatement
  -     */
  -    private int bindStatement(PreparedStatement stmt, int index, InCriteria crit, ClassDescriptor
cld) throws SQLException
  -    {
  -        FieldDescriptor fld = cld.getFieldDescriptorForPath(crit.getAttribute());
  -        if (crit.getValue() instanceof Collection)
  -        {
  -            Collection values = (Collection) crit.getValue();
  -            Iterator iter = values.iterator();
  -
  -            while (iter.hasNext())
  -            {
  -                index = bindStatementValue(stmt, index, iter.next(), cld, fld);
  -            }
  -        }
  -        else
  -        {
  -            index = bindStatementValue(stmt, index, crit.getValue(), cld, fld);
  -        }
  -        return index;
  -    }
  -
  -    /**
  -     * bind ExistsCriteria
  -     * @param stmt the PreparedStatement
  -     * @param index the position of the parameter to bind
  -     * @param crit the Criteria containing the parameter
  -     * @param cld the ClassDescriptor
  -     * @return next index for PreparedStatement
  -     */
  -    private int bindStatement(PreparedStatement stmt, int index, ExistsCriteria crit, ClassDescriptor
cld) throws SQLException
  -    {
  -        Query subQuery = (Query) crit.getValue();
  -
  -        // if query has criteria, bind them
  -        if (subQuery.getCriteria() != null && !subQuery.getCriteria().isEmpty())
  -        {
  -            return bindStatement(stmt, subQuery.getCriteria(), cld.getRepository().getDescriptorFor(subQuery.getSearchClass()),
index);
  -
  -            // otherwise, just ignore it
  -        }
  -        else
  -        {
  -            return index;
  -        }
  -    }
  +				if (m_eagerRelease)
  +				{
  +					conMan.releaseConnection();
  +				}
  +
  +			}
  +			platform.afterStatementClose(stmt, rs);
  +		}
  +		catch (PlatformException e)
  +		{
  +			log.error("Platform dependent operation failed", e);
  +		}
  +		catch (SQLException ignored)
  +		{
  +			if (log.isDebugEnabled())
  +				log.debug("Statement closing failed", ignored);
  +		}
  +	}
  +
  +	/**
  +	 * binds the Identities Primary key values to the statement
  +	 */
  +	public void bindDelete(PreparedStatement stmt, Identity oid, ClassDescriptor cld) throws
java.sql.SQLException
  +	{
  +		Object[] values = null;
  +		int i = 0;
  +
  +		if (cld == null)
  +		{
  +			cld = broker.getClassDescriptor(oid.getObjectsClass());
  +		}
  +
  +		values = getKeyValues(broker, cld, oid);
  +
  +		try
  +		{
  +			for (i = 0; i < values.length; i++)
  +			{
  +				platform.setObjectForStatement(stmt, i + 1, values[i], SqlHelper.getSqlTypePk(cld,
i));
  +			}
  +		}
  +		catch (SQLException e)
  +		{
  +			log.error("bindDelete failed for: " + oid.toString() + ", PK: " + i + ", value: " +
values[i]);
  +			throw e;
  +		}
  +	}
  +
  +	/**
  +	 * binds the objects primary key and locking values to the statement, BRJ
  +	 */
  +	public void bindDelete(PreparedStatement stmt, ClassDescriptor cld, Object obj) throws
java.sql.SQLException
  +	{
  +		int index = 1;
  +		Object[] values, currentLockingValues;
  +
  +		currentLockingValues = cld.getCurrentLockingValues(obj);
  +
  +		// parameters for WHERE-clause pk
  +		values = getKeyValues(broker, cld, obj);
  +		for (int i = 0; i < values.length; i++)
  +		{
  +			platform.setObjectForStatement(stmt, index, values[i], SqlHelper.getSqlTypePk(cld, i));
  +			index++;
  +		}
  +
  +		// parameters for WHERE-clause locking
  +		values = currentLockingValues;
  +		for (int i = 0; i < values.length; i++)
  +		{
  +			platform.setObjectForStatement(stmt, index, values[i], SqlHelper.getSqlTypeLocking(cld,
i));
  +			index++;
  +		}
  +	}
  +
  +	/**
  +	 * bind a value
  +	 * @param stmt the PreparedStatement
  +	 * @param index the position of the parameter to bind
  +	 * @param attributeName the query attribute to bind
  +	 * @param value the value to bind
  +	 * @param cld the ClassDescriptor
  +	 * @return next index for PreparedStatement
  +	 */
  +	private int bindStatementValue(PreparedStatement stmt, int index, Object value, ClassDescriptor
cld, FieldDescriptor fld)
  +		throws SQLException
  +	{
  +		// if value is a subQuery bind it
  +		if (value instanceof Query)
  +		{
  +			Query subQuery = (Query) value;
  +			if (subQuery.getCriteria() != null && !subQuery.getCriteria().isEmpty())
  +			{
  +				return bindStatement(stmt, subQuery.getCriteria(), cld.getRepository().getDescriptorFor(subQuery.getSearchClass()),
index);
  +			}
  +			return index;
  +		}
  +
  +		// if query has criteria, bind them
  +		if (fld != null)
  +		{
  +			// BRJ: use field conversions and platform
  +			if (value != null)
  +			{
  +				platform.setObjectForStatement(stmt, index, fld.getFieldConversion().javaToSql(value),
fld.getColumnJdbcType());
  +			}
  +			else
  +			{
  +				platform.setNullForStatement(stmt, index, fld.getColumnJdbcType());
  +			}
  +		}
  +		else
  +		{
  +			// BRJ: No FieldDescriptor found
  +			if (value != null)
  +			{
  +				stmt.setObject(index, value);
  +			}
  +			else
  +			{
  +				stmt.setNull(index, Types.NULL);
  +			}
  +		}
  +
  +		return ++index; // increment before return
  +	}
  +
  +	/**
  +	 * bind SelectionCriteria
  +	 * @param stmt the PreparedStatement
  +	 * @param index the position of the parameter to bind
  +	 * @param crit the Criteria containing the parameter
  +	 * @param cld the ClassDescriptor
  +	 * @return next index for PreparedStatement
  +	 */
  +	private int bindStatement(PreparedStatement stmt, int index, SelectionCriteria crit, ClassDescriptor
cld) throws SQLException
  +	{
  +		FieldDescriptor fld = cld.getFieldDescriptorForPath(crit.getAttribute());
  +		return bindStatementValue(stmt, index, crit.getValue(), cld, fld);
  +	}
  +
  +	/**
  +	 * bind NullCriteria
  +	 * @param stmt the PreparedStatement
  +	 * @param index the position of the parameter to bind
  +	 * @param crit the Criteria containing the parameter
  +	 * @return next index for PreparedStatement
  +	 */
  +	private int bindStatement(PreparedStatement stmt, int index, NullCriteria crit) throws
SQLException
  +	{
  +		return index;
  +	}
  +
  +	/**
  +	 * bind FieldCriteria
  +	 * @param stmt , the PreparedStatement
  +	 * @param index , the position of the parameter to bind
  +	 * @param crit , the Criteria containing the parameter
  +	 * @return next index for PreparedStatement
  +	 */
  +	private int bindStatement(PreparedStatement stmt, int index, FieldCriteria crit) throws
SQLException
  +	{
  +		return index;
  +	}
  +
  +	/**
  +	 * bind ColumnCriteria
  +	 * @param stmt , the PreparedStatement
  +	 * @param index , the position of the parameter to bind
  +	 * @param crit , the Criteria containing the parameter
  +	 * @return next index for PreparedStatement
  +	 */
  +	private int bindStatement(PreparedStatement stmt, int index, ColumnCriteria crit) throws
SQLException
  +	{
  +		return index;
  +	}
  +
  +	/**
  +	 * bind SqlCriteria
  +	 * @param stmt the PreparedStatement
  +	 * @param index the position of the parameter to bind
  +	 * @param crit the Criteria containing the parameter
  +	 * @return next index for PreparedStatement
  +	 */
  +	private int bindStatement(PreparedStatement stmt, int index, SqlCriteria crit) throws
SQLException
  +	{
  +		return index;
  +	}
  +
  +	/**
  +	 * bind BetweenCriteria
  +	 * @param stmt the PreparedStatement
  +	 * @param index the position of the parameter to bind
  +	 * @param crit the Criteria containing the parameter
  +	 * @param cld the ClassDescriptor
  +	 * @return next index for PreparedStatement
  +	 */
  +	private int bindStatement(PreparedStatement stmt, int index, BetweenCriteria crit, ClassDescriptor
cld) throws SQLException
  +	{
  +		FieldDescriptor fld = cld.getFieldDescriptorForPath(crit.getAttribute());
  +		index = bindStatementValue(stmt, index, crit.getValue(), cld, fld);
  +		return bindStatementValue(stmt, index, crit.getValue2(), cld, fld);
  +	}
  +
  +	/**
  +	 * bind InCriteria
  +	 * @param stmt the PreparedStatement
  +	 * @param index the position of the parameter to bind
  +	 * @param crit the Criteria containing the parameter
  +	 * @param cld the ClassDescriptor
  +	 * @return next index for PreparedStatement
  +	 */
  +	private int bindStatement(PreparedStatement stmt, int index, InCriteria crit, ClassDescriptor
cld) throws SQLException
  +	{
  +		FieldDescriptor fld = cld.getFieldDescriptorForPath(crit.getAttribute());
  +		if (crit.getValue() instanceof Collection)
  +		{
  +			Collection values = (Collection) crit.getValue();
  +			Iterator iter = values.iterator();
  +
  +			while (iter.hasNext())
  +			{
  +				index = bindStatementValue(stmt, index, iter.next(), cld, fld);
  +			}
  +		}
  +		else
  +		{
  +			index = bindStatementValue(stmt, index, crit.getValue(), cld, fld);
  +		}
  +		return index;
  +	}
  +
  +	/**
  +	 * bind ExistsCriteria
  +	 * @param stmt the PreparedStatement
  +	 * @param index the position of the parameter to bind
  +	 * @param crit the Criteria containing the parameter
  +	 * @param cld the ClassDescriptor
  +	 * @return next index for PreparedStatement
  +	 */
  +	private int bindStatement(PreparedStatement stmt, int index, ExistsCriteria crit, ClassDescriptor
cld) throws SQLException
  +	{
  +		Query subQuery = (Query) crit.getValue();
  +
  +		// if query has criteria, bind them
  +		if (subQuery.getCriteria() != null && !subQuery.getCriteria().isEmpty())
  +		{
  +			return bindStatement(stmt, subQuery.getCriteria(), cld.getRepository().getDescriptorFor(subQuery.getSearchClass()),
index);
  +
  +			// otherwise, just ignore it
  +		}
  +		else
  +		{
  +			return index;
  +		}
  +	}
   
       /**
        * bind a Query based Select Statement
        */
  -    public int bindStatement(PreparedStatement stmt, Criteria crit, ClassDescriptor cld,
int param) throws SQLException
  -    {
  -        if (crit != null)
  -        {
  -            Enumeration e = crit.getElements();
  -
  -            while (e.hasMoreElements())
  -            {
  -                Object o = e.nextElement();
  -                if (o instanceof Criteria)
  -                {
  -                    Criteria pc = (Criteria) o;
  -                    param = bindStatement(stmt, pc, cld, param);
  -                }
  -                else
  -                {
  -                    SelectionCriteria c = (SelectionCriteria) o;
  -
  -                    // BRJ : bind once for the criterion's main class
  -                    param = bindSelectionCriteria(stmt, param, c, cld);
  -
  -                    // BRJ : and once for each extent
  -                    for (int i = 0; i < c.getNumberOfExtentsToBind(); i++)
  -                    {
  -                        param = bindSelectionCriteria(stmt, param, c, cld);
  -                    }
  -                }
  -            }
  -        }
  -        return param;
  -    }
  -
  -    /**
  -     * bind SelectionCriteria
  -     * @param stmt the PreparedStatement
  -     * @param index the position of the parameter to bind
  -     * @param crit the Criteria containing the parameter
  -     * @param cld the ClassDescriptor
  -     * @return next index for PreparedStatement
  -     */
  -    private int bindSelectionCriteria(PreparedStatement stmt, int index, SelectionCriteria
crit, ClassDescriptor cld) throws SQLException
  -    {
  -        if (crit instanceof NullCriteria)
  -            index = bindStatement(stmt, index, (NullCriteria) crit);
  -        else if (crit instanceof BetweenCriteria)
  -            index = bindStatement(stmt, index, (BetweenCriteria) crit, cld);
  -        else if (crit instanceof InCriteria)
  -            index = bindStatement(stmt, index, (InCriteria) crit, cld);
  -        else if (crit instanceof SqlCriteria)
  -            index = bindStatement(stmt, index, (SqlCriteria) crit);
  -        else if (crit instanceof FieldCriteria)
  -            index = bindStatement(stmt, index, (FieldCriteria) crit);
  -        else if (crit instanceof ColumnCriteria)
  -            index = bindStatement(stmt, index, (ColumnCriteria) crit);
  -        else if (crit instanceof ExistsCriteria)
  -            index = bindStatement(stmt, index, (ExistsCriteria) crit, cld);
  -        else
  -            index = bindStatement(stmt, index, crit, cld);
  -
  -        return index;
  -    }
  -
  -    /**
  -     * binds the values of the object obj to the statements parameters
  -     */
  -    public void bindInsert(PreparedStatement stmt, ClassDescriptor cld, Object obj) throws
java.sql.SQLException
  -    {
  -        Object[] values;
  -        cld.updateLockingValues(obj); // BRJ : provide useful defaults for locking fields
  -        int i = 0;
  -        values = getAllValues(cld, obj);
  -        try
  -        {
  -            for (i = 0; i < values.length; i++)
  -            {
  -                Object val = values[i];
  -                if (val != null)
  -                {
  -                    platform.setObjectForStatement(stmt, i + 1, val, SqlHelper.getSqlTypeAll(cld,
i));
  -                }
  -                else
  -                {
  -                    platform.setNullForStatement(stmt, i + 1, SqlHelper.getSqlTypeAll(cld,
i));
  -                }
  -            }
  -        }
  -        catch (SQLException e)
  -        {
  -            log.error("bindInsert failed, insert value " + values[i] + " of type " + values[i].getClass().getName()
+
  -                    " using class-descriptor " + cld.getClassNameOfObject());
  -            throw e;
  -        }
  -    }
  -
  -    /**
  -     * binds the Identities Primary key values to the statement
  -     */
  -    public void bindSelect(PreparedStatement stmt, Identity oid, ClassDescriptor cld) throws
SQLException
  -    {
  -        Object[] values = null;
  -        int i = 0;
  -
  -        if (cld == null)
  -        {
  -            cld = broker.getClassDescriptor(oid.getObjectsClass());
  -        }
  -        try
  -        {
  -            values = getKeyValues(broker, cld, oid);
  -            for (i = 0; i < values.length; i++)
  -            {
  -                Object val = values[i];
  -                if (val != null)
  -                {
  -                    platform.setObjectForStatement(stmt, i + 1, val, SqlHelper.getSqlTypePk(cld,
i));
  -                }
  -                else
  -                {
  -                    platform.setNullForStatement(stmt, i + 1, SqlHelper.getSqlTypePk(cld,
i));
  -                }
  -            }
  -        }
  -        catch (SQLException e)
  -        {
  -            log.error("bindSelect failed for: " + oid.toString() + ", PK: " + i + ", value:
" + values[i]);
  -            throw e;
  -        }
  -    }
  -
  -    /**
  -     * binds the values of the object obj to the statements parameters
  -     */
  -    public void bindUpdate(PreparedStatement stmt, ClassDescriptor cld, Object obj) throws
java.sql.SQLException
  -    {
  -        int index = 1;
  -        int i = 0;
  -        Object[] values, currentLockingValues;
  -
  -        currentLockingValues = cld.getCurrentLockingValues(obj);
  -        cld.updateLockingValues(obj); // BRJ
  -        values = getNonKeyValues(broker, cld, obj);
  -
  -        // parameters for SET-clause
  -        try
  -        {
  -            for (i = 0; i < values.length; i++)
  -            {
  -                Object val = values[i];
  -                if (val != null)
  -                    platform.setObjectForStatement(stmt, index, val, SqlHelper.getSqlTypeNonPk(cld,
i));
  -                else
  -                    platform.setNullForStatement(stmt, index, SqlHelper.getSqlTypeNonPk(cld,
i));
  -                index++;
  -            }
  -        }
  -        catch (SQLException e)
  -        {
  -            log.error("bindUpdate failed (parameter building set-clause), set value " +
  -                    values[i] + " of type " + values[i].getClass().getName() +
  -                    " using class-descriptor " + cld.getClassNameOfObject());
  -            throw e;
  -        }
  -        // parameters for WHERE-clause pk
  -        values = getKeyValues(broker, cld, obj);
  -        try
  -        {
  -            for (i = 0; i < values.length; i++)
  -            {
  -                Object val = values[i];
  -                if (val != null)
  -                    stmt.setObject(index, values[i]);
  -                else
  -                    stmt.setNull(index, SqlHelper.getSqlTypePk(cld, i));
  -
  -                index++;
  -            }
  -        }
  -        catch (SQLException e)
  -        {
  -            log.error("bindUpdate failed (parameter building where-clause), set value "
+
  -                    values[i] + " of type " + values[i].getClass().getName() +
  -                    " using class-descriptor " + cld.getClassNameOfObject());
  -            throw e;
  -        }
  -        // parameters for WHERE-clause locking
  -        values = currentLockingValues;
  -        try
  -        {
  -            for (i = 0; i < values.length; i++)
  -            {
  -                Object val = values[i];
  -                if (val != null)
  -                    stmt.setObject(index, values[i]);
  -                else
  -                    stmt.setNull(index, SqlHelper.getSqlTypeNonPk(cld, i));
  -
  -                index++;
  -            }
  -        }
  -        catch (SQLException e)
  -        {
  -            log.error("bindUpdate failed (parameter building where-clause locking), set
value " +
  -                    values[i] + " of type " + values[i].getClass().getName() +
  -                    " using class-descriptor " + cld.getClassNameOfObject());
  -            throw e;
  -        }
  -    }
  -
  -    /**
  -     * binds the given array of values (if not null) starting from the given
  -     * parameter index
  -     * @return the next parameter index
  -     */
  -    public int bindValues(PreparedStatement stmt, Object[] values, int index) throws SQLException
  -    {
  -        if (values != null)
  -        {
  -            int i=0;
  -            try
  -            {
  -                for (i = 0; i < values.length; i++)
  -                {
  -                    platform.setObjectForStatement(stmt, index, values[i], SqlHelper.getSqlTypeByValue(values[i]));
  -                    index++;
  -                }
  -            }
  -            catch (SQLException e)
  -            {
  -                log.error("bindValues failed, set value " +
  -                    values[i] + " of type " + values[i].getClass().getName());
  -                throw e;
  -            }
  -        }
  -        return index;
  -    }
  -
  -    /**
  -     * return a prepared DELETE Statement fitting for the given ClassDescriptor
  -     */
  -    public PreparedStatement getDeleteStatement(ClassDescriptor cld) throws PersistenceBrokerSQLException,
PersistenceBrokerException
  +    public int bindStatement(PreparedStatement stmt, Query query, ClassDescriptor cld,
int param) throws SQLException
       {
  -        try
  -        {
  -            return getStatementsForClass(cld).getDeleteStmt(broker.serviceConnectionManager().getConnection());
  -        }
  -        catch (SQLException e)
  -        {
  -            throw new PersistenceBrokerSQLException("Could not build statement ask for",
e);
  -        }
  -        catch (LookupException e)
  -        {
  -            throw new PersistenceBrokerException("Used ConnectionManager instance could
not obtain a connection", e);
  -        }
  -    }
  -
  -    /**
  -     * return a generic Statement for the given ClassDescriptor.
  -     * Never use this method for UPDATE/INSERT/DELETE if you want to use the batch mode.
  -     */
  -    public Statement getGenericStatement(ClassDescriptor cds, boolean scrollable) throws
PersistenceBrokerException
  -    {
  -        try
  -        {
  -            return getStatementsForClass(cds).getGenericStmt(conMan.getConnection(), scrollable);
  -        }
  -        catch (LookupException e)
  -        {
  -            throw new PersistenceBrokerException("Used ConnectionManager instance could
not obtain a connection", e);
  -        }
  -    }
  -
  -    /**
  -     * return a prepared Insert Statement fitting for the given ClassDescriptor
  -     */
  -    public PreparedStatement getInsertStatement(ClassDescriptor cds) throws PersistenceBrokerSQLException,
PersistenceBrokerException
  -    {
  -        try
  -        {
  -            return getStatementsForClass(cds).getInsertStmt(conMan.getConnection());
  -        }
  -        catch (SQLException e)
  -        {
  -            throw new PersistenceBrokerSQLException("Could not build statement ask for",
e);
  -        }
  -        catch (LookupException e)
  -        {
  -            throw new PersistenceBrokerException("Used ConnectionManager instance could
not obtain a connection", e);
  -        }
  -    }
  -
  -    /**
  -     * return a generic Statement for the given ClassDescriptor
  -     */
  -    public PreparedStatement getPreparedStatement(ClassDescriptor cds, String sql, boolean
scrollable) throws PersistenceBrokerException
  -    {
  -        try
  -        {
  -            return getStatementsForClass(cds).getPreparedStmt(conMan.getConnection(), sql,
scrollable);
  -        }
  -        catch (LookupException e)
  -        {
  -            throw new PersistenceBrokerException("Used ConnectionManager instance could
not obtain a connection", e);
  -        }
  -    }
  -
  -    /**
  -     * return a prepared Select Statement for the given ClassDescriptor
  -     */
  -    public PreparedStatement getSelectByPKStatement(ClassDescriptor cds) throws PersistenceBrokerSQLException,
PersistenceBrokerException
  -    {
  -        try
  -        {
  -            return getStatementsForClass(cds).getSelectByPKStmt(conMan.getConnection());
  -        }
  -        catch (SQLException e)
  -        {
  -            throw new PersistenceBrokerSQLException("Could not build statement ask for",
e);
  -        }
  -        catch (LookupException e)
  -        {
  -            throw new PersistenceBrokerException("Used ConnectionManager instance could
not obtain a connection", e);
  -        }
  -    }
  +        int result;
   
  -    /**
  -     * return a prepared Update Statement fitting to the given ClassDescriptor
  -     */
  -    public PreparedStatement getUpdateStatement(ClassDescriptor cds) throws PersistenceBrokerSQLException,
PersistenceBrokerException
  -    {
  -        try
  -        {
  -            return getStatementsForClass(cds).getUpdateStmt(conMan.getConnection());
  -        }
  -        catch (SQLException e)
  -        {
  -            throw new PersistenceBrokerSQLException("Could not build statement ask for",
e);
  -        }
  -        catch (LookupException e)
  -        {
  -            throw new PersistenceBrokerException("Used ConnectionManager instance could
not obtain a connection", e);
  -        }
  -    }
  +        result = bindStatement(stmt, query.getCriteria(), cld,  param);
  +        result = bindStatement(stmt, query.getHavingCriteria(), cld,  result);
   
  -    /**
  -     * returns an array containing values for all the Objects attribute
  -     * @throws MetadataException if tehre is an erros accessing obj field values
  -     */
  -    protected Object[] getAllValues(ClassDescriptor cld, Object obj) throws PersistenceBrokerException
  -    {
  -        return broker.serviceBrokerHelper().getAllValues(cld, obj);
  +        return result;
       }
   
  -    /**
  -     * returns an Array with an Objects PK VALUES
  -     * @throws MetadataException if there is an erros accessing o field values
  -     */
  -    protected Object[] getKeyValues(PersistenceBroker broker, ClassDescriptor cld, Object
obj) throws PersistenceBrokerException
  -    {
  -        return broker.serviceBrokerHelper().getKeyValues(cld, obj);
  -    }
  -
  -    /**
  -     * returns an Array with an Identities PK VALUES
  -     * @throws MetadataException if there is an erros accessing o field values
  -     */
  -    protected Object[] getKeyValues(PersistenceBroker broker, ClassDescriptor cld, Identity
oid) throws PersistenceBrokerException
  -    {
  +	/**
  +	 * bind a Query based Select Statement
  +	 */
  +	protected int bindStatement(PreparedStatement stmt, Criteria crit, ClassDescriptor cld,
int param) throws SQLException
  +	{
  +		if (crit != null)
  +		{
  +			Enumeration e = crit.getElements();
  +
  +			while (e.hasMoreElements())
  +			{
  +				Object o = e.nextElement();
  +				if (o instanceof Criteria)
  +				{
  +					Criteria pc = (Criteria) o;
  +					param = bindStatement(stmt, pc, cld, param);
  +				}
  +				else
  +				{
  +					SelectionCriteria c = (SelectionCriteria) o;
  +
  +					// BRJ : bind once for the criterion's main class
  +					param = bindSelectionCriteria(stmt, param, c, cld);
  +
  +					// BRJ : and once for each extent
  +					for (int i = 0; i < c.getNumberOfExtentsToBind(); i++)
  +					{
  +						param = bindSelectionCriteria(stmt, param, c, cld);
  +					}
  +				}
  +			}
  +		}
  +		return param;
  +	}
  +
  +	/**
  +	 * bind SelectionCriteria
  +	 * @param stmt the PreparedStatement
  +	 * @param index the position of the parameter to bind
  +	 * @param crit the Criteria containing the parameter
  +	 * @param cld the ClassDescriptor
  +	 * @return next index for PreparedStatement
  +	 */
  +	private int bindSelectionCriteria(PreparedStatement stmt, int index, SelectionCriteria
crit, ClassDescriptor cld) throws SQLException
  +	{
  +		if (crit instanceof NullCriteria)
  +			index = bindStatement(stmt, index, (NullCriteria) crit);
  +		else if (crit instanceof BetweenCriteria)
  +			index = bindStatement(stmt, index, (BetweenCriteria) crit, cld);
  +		else if (crit instanceof InCriteria)
  +			index = bindStatement(stmt, index, (InCriteria) crit, cld);
  +		else if (crit instanceof SqlCriteria)
  +			index = bindStatement(stmt, index, (SqlCriteria) crit);
  +		else if (crit instanceof FieldCriteria)
  +			index = bindStatement(stmt, index, (FieldCriteria) crit);
  +		else if (crit instanceof ColumnCriteria)
  +			index = bindStatement(stmt, index, (ColumnCriteria) crit);
  +		else if (crit instanceof ExistsCriteria)
  +			index = bindStatement(stmt, index, (ExistsCriteria) crit, cld);
  +		else
  +			index = bindStatement(stmt, index, crit, cld);
  +
  +		return index;
  +	}
  +
  +	/**
  +	 * binds the values of the object obj to the statements parameters
  +	 */
  +	public void bindInsert(PreparedStatement stmt, ClassDescriptor cld, Object obj) throws
java.sql.SQLException
  +	{
  +		Object[] values;
  +		cld.updateLockingValues(obj); // BRJ : provide useful defaults for locking fields
  +
  +		values = getAllValues(cld, obj);
  +		for (int i = 0; i < values.length; i++)
  +		{
  +			Object val = values[i];
  +			if (val != null)
  +			{
  +				platform.setObjectForStatement(stmt, i + 1, val, SqlHelper.getSqlTypeAll(cld, i));
  +			}
  +			else
  +			{
  +				platform.setNullForStatement(stmt, i + 1, SqlHelper.getSqlTypeAll(cld, i));
  +			}
  +
  +		}
  +	}
  +
  +	/**
  +	 * binds the Identities Primary key values to the statement
  +	 */
  +	public void bindSelect(PreparedStatement stmt, Identity oid, ClassDescriptor cld) throws
SQLException
  +	{
  +		Object[] values = null;
  +		int i = 0;
  +
  +		if (cld == null)
  +		{
  +			cld = broker.getClassDescriptor(oid.getObjectsClass());
  +		}
  +		try
  +		{
  +			values = getKeyValues(broker, cld, oid);
  +			for (i = 0; i < values.length; i++)
  +			{
  +				Object val = values[i];
  +				if (val != null)
  +				{
  +					platform.setObjectForStatement(stmt, i + 1, val, SqlHelper.getSqlTypePk(cld, i));
  +				}
  +				else
  +				{
  +					platform.setNullForStatement(stmt, i + 1, SqlHelper.getSqlTypePk(cld, i));
  +				}
  +			}
  +		}
  +		catch (SQLException e)
  +		{
  +			log.error("bindSelect failed for: " + oid.toString() + ", PK: " + i + ", value: " +
values[i]);
  +			throw e;
  +		}
  +	}
  +
  +	/**
  +	 * binds the values of the object obj to the statements parameters
  +	 */
  +	public void bindUpdate(PreparedStatement stmt, ClassDescriptor cld, Object obj) throws
java.sql.SQLException
  +	{
  +		int index = 1;
  +		Object[] values, currentLockingValues;
  +
  +		currentLockingValues = cld.getCurrentLockingValues(obj);
  +		cld.updateLockingValues(obj); // BRJ
  +		values = getNonKeyValues(broker, cld, obj);
  +
  +		// parameters for SET-clause
  +		for (int i = 0; i < values.length; i++)
  +		{
  +			Object val = values[i];
  +			if (val != null)
  +				platform.setObjectForStatement(stmt, index, val, SqlHelper.getSqlTypeNonPk(cld, i));
  +			else
  +				platform.setNullForStatement(stmt, index, SqlHelper.getSqlTypeNonPk(cld, i));
  +			index++;
  +		}
  +		// parameters for WHERE-clause pk
  +		values = getKeyValues(broker, cld, obj);
  +		for (int i = 0; i < values.length; i++)
  +		{
  +			Object val = values[i];
  +			if (val != null)
  +				stmt.setObject(index, values[i]);
  +			else
  +				stmt.setNull(index, SqlHelper.getSqlTypePk(cld, i));
  +
  +			index++;
  +		}
  +		// parameters for WHERE-clause locking
  +		values = currentLockingValues;
  +		for (int i = 0; i < values.length; i++)
  +		{
  +			Object val = values[i];
  +			if (val != null)
  +				stmt.setObject(index, values[i]);
  +			else
  +				stmt.setNull(index, SqlHelper.getSqlTypeNonPk(cld, i));
  +
  +			index++;
  +		}
  +	}
  +
  +	/**
  +	 * binds the given array of values (if not null) starting from the given
  +	 * parameter index
  +	 * @return the next parameter index
  +	 */
  +	public int bindValues(PreparedStatement stmt, Object[] values, int index) throws SQLException
  +	{
  +		if (values != null)
  +		{
  +			for (int i = 0; i < values.length; i++)
  +			{
  +				platform.setObjectForStatement(stmt, index, values[i], SqlHelper.getSqlTypeByValue(values[i]));
  +				index++;
  +			}
  +		}
  +		return index;
  +	}
  +
  +	/**
  +	 * return a prepared DELETE Statement fitting for the given ClassDescriptor
  +	 */
  +	public PreparedStatement getDeleteStatement(ClassDescriptor cld) throws PersistenceBrokerSQLException,
PersistenceBrokerException
  +	{
  +		try
  +		{
  +			return getStatementsForClass(cld).getDeleteStmt(broker.serviceConnectionManager().getConnection());
  +		}
  +		catch (SQLException e)
  +		{
  +			throw new PersistenceBrokerSQLException("Could not build statement ask for", e);
  +		}
  +		catch (LookupException e)
  +		{
  +			throw new PersistenceBrokerException("Used ConnectionManager instance could not obtain
a connection", e);
  +		}
  +	}
  +
  +	/**
  +	 * return a generic Statement for the given ClassDescriptor.
  +	 * Never use this method for UPDATE/INSERT/DELETE if you want to use the batch mode.
  +	 */
  +	public Statement getGenericStatement(ClassDescriptor cds, boolean scrollable) throws PersistenceBrokerException
  +	{
  +		try
  +		{
  +			return getStatementsForClass(cds).getGenericStmt(conMan.getConnection(), scrollable);
  +		}
  +		catch (LookupException e)
  +		{
  +			throw new PersistenceBrokerException("Used ConnectionManager instance could not obtain
a connection", e);
  +		}
  +	}
  +
  +	/**
  +	 * return a prepared Insert Statement fitting for the given ClassDescriptor
  +	 */
  +	public PreparedStatement getInsertStatement(ClassDescriptor cds) throws PersistenceBrokerSQLException,
PersistenceBrokerException
  +	{
  +		try
  +		{
  +			return getStatementsForClass(cds).getInsertStmt(conMan.getConnection());
  +		}
  +		catch (SQLException e)
  +		{
  +			throw new PersistenceBrokerSQLException("Could not build statement ask for", e);
  +		}
  +		catch (LookupException e)
  +		{
  +			throw new PersistenceBrokerException("Used ConnectionManager instance could not obtain
a connection", e);
  +		}
  +	}
  +
  +	/**
  +	 * return a generic Statement for the given ClassDescriptor
  +	 */
  +	public PreparedStatement getPreparedStatement(ClassDescriptor cds, String sql, boolean
scrollable) throws PersistenceBrokerException
  +	{
  +		try
  +		{
  +			return getStatementsForClass(cds).getPreparedStmt(conMan.getConnection(), sql, scrollable);
  +		}
  +		catch (LookupException e)
  +		{
  +			throw new PersistenceBrokerException("Used ConnectionManager instance could not obtain
a connection", e);
  +		}
  +	}
  +
  +	/**
  +	 * return a prepared Select Statement for the given ClassDescriptor
  +	 */
  +	public PreparedStatement getSelectByPKStatement(ClassDescriptor cds) throws PersistenceBrokerSQLException,
PersistenceBrokerException
  +	{
  +		try
  +		{
  +			return getStatementsForClass(cds).getSelectByPKStmt(conMan.getConnection());
  +		}
  +		catch (SQLException e)
  +		{
  +			throw new PersistenceBrokerSQLException("Could not build statement ask for", e);
  +		}
  +		catch (LookupException e)
  +		{
  +			throw new PersistenceBrokerException("Used ConnectionManager instance could not obtain
a connection", e);
  +		}
  +	}
  +
  +	/**
  +	 * return a prepared Update Statement fitting to the given ClassDescriptor
  +	 */
  +	public PreparedStatement getUpdateStatement(ClassDescriptor cds) throws PersistenceBrokerSQLException,
PersistenceBrokerException
  +	{
  +		try
  +		{
  +			return getStatementsForClass(cds).getUpdateStmt(conMan.getConnection());
  +		}
  +		catch (SQLException e)
  +		{
  +			throw new PersistenceBrokerSQLException("Could not build statement ask for", e);
  +		}
  +		catch (LookupException e)
  +		{
  +			throw new PersistenceBrokerException("Used ConnectionManager instance could not obtain
a connection", e);
  +		}
  +	}
  +
  +	/**
  +	 * returns an array containing values for all the Objects attribute
  +	 * @throws MetadataException if tehre is an erros accessing obj field values
  +	 */
  +	protected Object[] getAllValues(ClassDescriptor cld, Object obj) throws PersistenceBrokerException
  +	{
  +		return broker.serviceBrokerHelper().getAllValues(cld, obj);
  +	}
  +
  +	/**
  +	 * returns an Array with an Objects PK VALUES
  +	 * @throws MetadataException if there is an erros accessing o field values
  +	 */
  +	protected Object[] getKeyValues(PersistenceBroker broker, ClassDescriptor cld, Object
obj) throws PersistenceBrokerException
  +	{
  +		return broker.serviceBrokerHelper().getKeyValues(cld, obj);
  +	}
  +
  +	/**
  +	 * returns an Array with an Identities PK VALUES
  +	 * @throws MetadataException if there is an erros accessing o field values
  +	 */
  +	protected Object[] getKeyValues(PersistenceBroker broker, ClassDescriptor cld, Identity
oid) throws PersistenceBrokerException
  +	{
           return broker.serviceBrokerHelper().getKeyValues(cld, oid);
  -    }
  +	}
  +
  +	/**
  +	 * returns an Array with an Objects NON-PK VALUES
  +	 * @throws MetadataException if there is an erros accessing o field values
  +	 */
  +	protected Object[] getNonKeyValues(PersistenceBroker broker, ClassDescriptor cld, Object
obj) throws PersistenceBrokerException
  +	{
  +		return broker.serviceBrokerHelper().getNonKeyValues(cld, obj);
  +	}
   
  -    /**
  -     * returns an Array with an Objects NON-PK VALUES
  -     * @throws MetadataException if there is an erros accessing o field values
  -     */
  -    protected Object[] getNonKeyValues(PersistenceBroker broker, ClassDescriptor cld, Object
obj) throws PersistenceBrokerException
  -    {
  -        return broker.serviceBrokerHelper().getNonKeyValues(cld, obj);
  -    }
   }
  
  
  

Mime
View raw message