Tag: cws_src680_qiq User: fs Date: 06/05/10 07:22:28 Modified: /dba/dbaccess/source/core/api/ querycomposer.cxx
Log: no need to instantiate a SingleSelectQueryComposer directly File Changes: Directory: /dba/dbaccess/source/core/api/ ========================================= File [changed]: querycomposer.cxx Url: http://dba.openoffice.org/source/browse/dba/dbaccess/source/core/api/querycomposer.cxx?r1=1.63&r2=1.63.18.1 Delta lines: +6 -24 -------------------- --- querycomposer.cxx 7 Apr 2006 14:10:56 -0000 1.63 +++ querycomposer.cxx 10 May 2006 14:22:26 -0000 1.63.18.1 @@ -4,9 +4,9 @@ * * $RCSfile: querycomposer.cxx,v $ * - * $Revision: 1.63 $ + * $Revision: 1.63.18.1 $ * - * last change: $Author: vg $ $Date: 2006/04/07 14:10:56 $ + * last change: $Author: fs $ $Date: 2006/05/10 14:22:26 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -96,9 +96,6 @@ #ifndef DBA_HELPERCOLLECTIONS_HXX #include "HelperCollections.hxx" #endif -#ifndef DBACCESS_CORE_API_SINGLESELECTQUERYCOMPOSER_HXX -#include "SingleSelectQueryComposer.hxx" -#endif #ifndef DBACCESS_SOURCE_CORE_INC_COMPOSERTOOLS_HXX #include "composertools.hxx" #endif @@ -132,24 +129,9 @@ DBG_CTOR(OQueryComposer,NULL); OSL_ENSURE(_xConnection.is()," Connection cant be null!"); - try - { - Reference<XMultiServiceFactory> xFac(_xConnection,UNO_QUERY); - if ( xFac.is() ) - { - m_xComposer.set( xFac->createInstance( SERVICE_NAME_SINGLESELECTQUERYCOMPOSER ), UNO_QUERY ); - m_xComposerHelper.set( xFac->createInstance( SERVICE_NAME_SINGLESELECTQUERYCOMPOSER ), UNO_QUERY ); - } - else - { - m_xComposer = new OSingleSelectQueryComposer(_xTableSupplier,_xConnection, _xServiceFactory ); - m_xComposerHelper = new OSingleSelectQueryComposer(_xTableSupplier,_xConnection, _xServiceFactory ); - } - } - catch(Exception) - { - } - OSL_ENSURE( m_xComposer.is(), "OQueryComposer::OQueryComposer: Composer copuld be created!" ); + Reference<XMultiServiceFactory> xFac( _xConnection, UNO_QUERY_THROW ); + m_xComposer.set( xFac->createInstance( SERVICE_NAME_SINGLESELECTQUERYCOMPOSER ), UNO_QUERY_THROW ); + m_xComposerHelper.set( xFac->createInstance( SERVICE_NAME_SINGLESELECTQUERYCOMPOSER ), UNO_QUERY_THROW ); } // ------------------------------------------------------------------------- OQueryComposer::~OQueryComposer() --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
