public PooledObject activateInstance()
	throws SQLException
	{
		PooledObject instance;
		PooledObjectHandle handle = m_providerPool;
		if(handle != null)
		{
			m_providerPool = handle.m_next;
			instance = handle.m_instance;

			// Return the handle to the unused handle pool.
			//
			handle.m_instance = null;
			handle.m_next = s_handlePool;
			s_handlePool = handle;
		}
		else
		{
			try
			{
				instance = (PooledObject)m_ctor.newInstance(new Object[] { this });
			}
			catch(InvocationTargetException e)
			{
				Throwable t = e.getTargetException();
				if(t instanceof SQLException)
					throw (SQLException)t;
				if(t instanceof RuntimeException)
					throw (RuntimeException)t;
				if(t instanceof Error)
					throw (Error)t;
				throw new SQLException(e.getMessage());
			}
			catch(RuntimeException e)
			{
				throw e;
			}
			catch(Exception e)
			{
				throw new SQLException("Failed to create an instance of: " +
					m_ctor.getDeclaringClass() + " :" + e.getMessage());
			}
		}
		try
		{
			instance.activate();
		}
		catch(SQLException e)
		{
			instance.remove();
			throw e;
		}
		return instance;
	}