LCOV - code coverage report
Current view: top level - connectivity/source/drivers/postgresql - pq_fakedupdateableresultset.cxx (source / functions) Hit Total Coverage
Test: commit e02a6cb2c3e2b23b203b422e4e0680877f232636 Lines: 0 67 0.0 %
Date: 2014-04-14 Functions: 0 27 0.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2             : /*************************************************************************
       3             :  *
       4             :  *  Effective License of whole file:
       5             :  *
       6             :  *    This library is free software; you can redistribute it and/or
       7             :  *    modify it under the terms of the GNU Lesser General Public
       8             :  *    License version 2.1, as published by the Free Software Foundation.
       9             :  *
      10             :  *    This library is distributed in the hope that it will be useful,
      11             :  *    but WITHOUT ANY WARRANTY; without even the implied warranty of
      12             :  *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
      13             :  *    Lesser General Public License for more details.
      14             :  *
      15             :  *    You should have received a copy of the GNU Lesser General Public
      16             :  *    License along with this library; if not, write to the Free Software
      17             :  *    Foundation, Inc., 59 Temple Place, Suite 330, Boston,
      18             :  *    MA  02111-1307  USA
      19             :  *
      20             :  *  Parts "Copyright by Sun Microsystems, Inc" prior to August 2011:
      21             :  *
      22             :  *    The Contents of this file are made available subject to the terms of
      23             :  *    the GNU Lesser General Public License Version 2.1
      24             :  *
      25             :  *    Copyright: 2000 by Sun Microsystems, Inc.
      26             :  *
      27             :  *    Contributor(s): Joerg Budischewski
      28             :  *
      29             :  *  All parts contributed on or after August 2011:
      30             :  *
      31             :  *    This Source Code Form is subject to the terms of the Mozilla Public
      32             :  *    License, v. 2.0. If a copy of the MPL was not distributed with this
      33             :  *    file, You can obtain one at http://mozilla.org/MPL/2.0/.
      34             :  *
      35             :  ************************************************************************/
      36             : 
      37             : #include "pq_fakedupdateableresultset.hxx"
      38             : #include <cppuhelper/typeprovider.hxx>
      39             : #include <cppuhelper/queryinterface.hxx>
      40             : 
      41             : using osl::MutexGuard;
      42             : 
      43             : 
      44             : using com::sun::star::uno::Reference;
      45             : using com::sun::star::uno::makeAny;
      46             : using com::sun::star::uno::Sequence;
      47             : using com::sun::star::uno::UNO_QUERY;
      48             : using com::sun::star::uno::Any;
      49             : using com::sun::star::uno::Type;
      50             : using com::sun::star::uno::RuntimeException;
      51             : 
      52             : using com::sun::star::sdbc::SQLException;
      53             : using com::sun::star::sdbc::XResultSet;
      54             : using com::sun::star::sdbc::XResultSetUpdate;
      55             : using com::sun::star::sdbc::XRowUpdate;
      56             : using com::sun::star::sdbc::XRow;
      57             : using com::sun::star::sdbc::XStatement;
      58             : 
      59             : namespace pq_sdbc_driver
      60             : {
      61             : 
      62           0 : FakedUpdateableResultSet::FakedUpdateableResultSet(
      63             :         const ::rtl::Reference< RefCountedMutex > & mutex,
      64             :         const com::sun::star::uno::Reference< com::sun::star::uno::XInterface > &owner,
      65             :         ConnectionSettings **pSettings,
      66             :         PGresult *result,
      67             :         const OUString &schema,
      68             :         const OUString &table,
      69             :         const OUString &aReason )
      70             :     : ResultSet( mutex, owner, pSettings, result, schema, table ),
      71           0 :       m_aReason( aReason )
      72           0 : {}
      73             : 
      74             : 
      75           0 : com::sun::star::uno::Any  FakedUpdateableResultSet::queryInterface(
      76             :     const com::sun::star::uno::Type & reqType )
      77             :     throw (com::sun::star::uno::RuntimeException, std::exception)
      78             : {
      79           0 :     Any ret = ResultSet::queryInterface( reqType );
      80           0 :     if( ! ret.hasValue() )
      81           0 :         ret = ::cppu::queryInterface(
      82             :             reqType,
      83             :             static_cast< XResultSetUpdate * > ( this ),
      84           0 :             static_cast< XRowUpdate * > ( this ) );
      85           0 :     return ret;
      86             : }
      87             : 
      88             : 
      89           0 : com::sun::star::uno::Sequence< com::sun::star::uno::Type > FakedUpdateableResultSet::getTypes()
      90             :         throw( com::sun::star::uno::RuntimeException, std::exception )
      91             : {
      92             :     static cppu::OTypeCollection *pCollection;
      93           0 :     if( ! pCollection )
      94             :     {
      95           0 :         MutexGuard guard( osl::Mutex::getGlobalMutex() );
      96           0 :         if( !pCollection )
      97             :         {
      98             :             static cppu::OTypeCollection collection(
      99           0 :                 getCppuType( (Reference< XResultSetUpdate> *) 0 ),
     100           0 :                 getCppuType( (Reference< XRowUpdate> *) 0 ),
     101           0 :                 ResultSet::getTypes());
     102           0 :             pCollection = &collection;
     103           0 :         }
     104             :     }
     105           0 :     return pCollection->getTypes();
     106             : 
     107             : }
     108             : 
     109           0 : com::sun::star::uno::Sequence< sal_Int8> FakedUpdateableResultSet::getImplementationId()
     110             :         throw( com::sun::star::uno::RuntimeException, std::exception )
     111             : {
     112           0 :     return css::uno::Sequence<sal_Int8>();
     113             : }
     114             : 
     115           0 : void FakedUpdateableResultSet::insertRow(  ) throw (SQLException, RuntimeException, std::exception)
     116             : {
     117           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     118             : }
     119             : 
     120           0 : void FakedUpdateableResultSet::updateRow(  ) throw (SQLException, RuntimeException, std::exception)
     121             : {
     122           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     123             : }
     124             : 
     125           0 : void FakedUpdateableResultSet::deleteRow(  ) throw (SQLException, RuntimeException, std::exception)
     126             : {
     127           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     128             :  }
     129             : 
     130           0 : void FakedUpdateableResultSet::cancelRowUpdates(  ) throw (SQLException, RuntimeException, std::exception)
     131             : {
     132           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     133             : }
     134             : 
     135           0 : void FakedUpdateableResultSet::moveToInsertRow(  ) throw (SQLException, RuntimeException, std::exception)
     136             : {
     137           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     138             : }
     139             : 
     140           0 : void FakedUpdateableResultSet::moveToCurrentRow(  ) throw (SQLException, RuntimeException, std::exception)
     141             : {
     142           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     143             : }
     144             : 
     145             : 
     146           0 : void FakedUpdateableResultSet::updateNull( sal_Int32 /* columnIndex */ ) throw (SQLException, RuntimeException, std::exception)
     147             : {
     148           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     149             : }
     150             : 
     151           0 : void FakedUpdateableResultSet::updateBoolean( sal_Int32 /* columnIndex */, sal_Bool /* x */ ) throw (SQLException, RuntimeException, std::exception)
     152             : {
     153           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     154             : }
     155             : 
     156           0 : void FakedUpdateableResultSet::updateByte( sal_Int32 /* columnIndex */, sal_Int8 /* x */ ) throw (SQLException, RuntimeException, std::exception)
     157             : {
     158           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     159             : }
     160             : 
     161           0 : void FakedUpdateableResultSet::updateShort( sal_Int32 /* columnIndex */, sal_Int16 /* x */ ) throw (SQLException, RuntimeException, std::exception)
     162             : {
     163           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     164             : }
     165             : 
     166           0 : void FakedUpdateableResultSet::updateInt( sal_Int32 /* columnIndex */, sal_Int32 /* x */ ) throw (SQLException, RuntimeException, std::exception)
     167             : {
     168           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     169             : }
     170             : 
     171           0 : void FakedUpdateableResultSet::updateLong( sal_Int32 /* columnIndex */, sal_Int64 /* x */ ) throw (SQLException, RuntimeException, std::exception)
     172             : {
     173           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     174             : }
     175             : 
     176           0 : void FakedUpdateableResultSet::updateFloat( sal_Int32 /* columnIndex */, float /* x */ ) throw (SQLException, RuntimeException, std::exception)
     177             : {
     178           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     179             : }
     180             : 
     181           0 : void FakedUpdateableResultSet::updateDouble( sal_Int32 /* columnIndex */, double /* x */ ) throw (SQLException, RuntimeException, std::exception)
     182             : {
     183           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     184             : }
     185             : 
     186           0 : void FakedUpdateableResultSet::updateString( sal_Int32 /* columnIndex */, const OUString& /* x */ ) throw (SQLException, RuntimeException, std::exception)
     187             : {
     188           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     189             : }
     190             : 
     191           0 : void FakedUpdateableResultSet::updateBytes( sal_Int32 /* columnIndex */, const ::com::sun::star::uno::Sequence< sal_Int8 >& /* x */ ) throw (SQLException, RuntimeException, std::exception)
     192             : {
     193           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     194             : }
     195             : 
     196           0 : void FakedUpdateableResultSet::updateDate( sal_Int32 /* columnIndex */, const ::com::sun::star::util::Date& /* x */ ) throw (SQLException, RuntimeException, std::exception)
     197             : {
     198           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     199             : }
     200             : 
     201           0 : void FakedUpdateableResultSet::updateTime( sal_Int32 /* columnIndex */, const ::com::sun::star::util::Time& /* x */ ) throw (SQLException, RuntimeException, std::exception)
     202             : {
     203           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     204             : }
     205             : 
     206           0 : void FakedUpdateableResultSet::updateTimestamp( sal_Int32 /* columnIndex */, const ::com::sun::star::util::DateTime& /* x */ ) throw (SQLException, RuntimeException, std::exception)
     207             : {
     208           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     209             : }
     210             : 
     211           0 : void FakedUpdateableResultSet::updateBinaryStream( sal_Int32 /* columnIndex */, const ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >& /* x */, sal_Int32 /* length */ ) throw (SQLException, RuntimeException, std::exception)
     212             : {
     213           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     214             : }
     215             : 
     216           0 : void FakedUpdateableResultSet::updateCharacterStream( sal_Int32 /* columnIndex */, const ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >& /* x */, sal_Int32 /* length */ ) throw (SQLException, RuntimeException, std::exception)
     217             : {
     218           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     219             : }
     220             : 
     221           0 : void FakedUpdateableResultSet::updateObject( sal_Int32 /* columnIndex */, const ::com::sun::star::uno::Any& /* x */ ) throw (SQLException, RuntimeException, std::exception)
     222             : {
     223           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     224             : }
     225             : 
     226           0 : void FakedUpdateableResultSet::updateNumericObject( sal_Int32 /* columnIndex */, const ::com::sun::star::uno::Any& /* x */, sal_Int32 /* scale */ ) throw (SQLException, RuntimeException, std::exception)
     227             : {
     228           0 :     throw SQLException( m_aReason, *this, OUString(),1,Any() );
     229             : }
     230             : 
     231             : }
     232             : 
     233             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10