diff options
author | Alexander Wilms <f.alexander.wilms@gmail.com> | 2014-02-22 21:20:15 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-02-23 03:38:49 +0000 |
commit | 0ce0c369aa8880dff9fe874ba85ec6f52ee37ddf (patch) | |
tree | 5024cba9f9ea5e3b23ea26025323f6aef39488d0 /odk/examples | |
parent | b81ac16e65b311d6e43c05c22c65d2040c9d7e04 (diff) |
Remove unneccessary comments
Change-Id: I939160ae72fecbe3d4a60ce755730bd4c38497fb
Reviewed-on: https://gerrit.libreoffice.org/8182
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'odk/examples')
13 files changed, 404 insertions, 404 deletions
diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SConnection.cxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SConnection.cxx index 3d6a5ef16d59..6cf87bb1651a 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SConnection.cxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SConnection.cxx @@ -46,12 +46,12 @@ using namespace connectivity::skeleton; -//------------------------------------------------------------------------------ + using namespace com::sun::star::uno; using namespace com::sun::star::lang; using namespace com::sun::star::beans; using namespace com::sun::star::sdbc; -// -------------------------------------------------------------------------------- + OConnection::OConnection(SkeletonDriver* _pDriver) : OSubComponent<OConnection, OConnection_BASE>((::cppu::OWeakObject*)_pDriver, this), OMetaConnection_BASE(m_aMutex), @@ -63,7 +63,7 @@ OConnection::OConnection(SkeletonDriver* _pDriver) { m_pDriver->acquire(); } -//----------------------------------------------------------------------------- + OConnection::~OConnection() { if(!isClosed()) @@ -71,13 +71,13 @@ OConnection::~OConnection() m_pDriver->release(); m_pDriver = NULL; } -//----------------------------------------------------------------------------- + void SAL_CALL OConnection::release() throw() { relase_ChildImpl(); } -// ----------------------------------------------------------------------------- -//----------------------------------------------------------------------------- + + void OConnection::construct(const ::rtl::OUString& url,const Sequence< PropertyValue >& info) throw(SQLException) { osl_atomic_increment( &m_refCount ); @@ -132,10 +132,10 @@ void OConnection::construct(const ::rtl::OUString& url,const Sequence< PropertyV osl_atomic_decrement( &m_refCount ); } // XServiceInfo -// -------------------------------------------------------------------------------- + IMPLEMENT_SERVICE_INFO(OConnection, "com.sun.star.sdbc.drivers.skeleton.OConnection", "com.sun.star.sdbc.Connection") -// -------------------------------------------------------------------------------- + Reference< XStatement > SAL_CALL OConnection::createStatement( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -147,7 +147,7 @@ Reference< XStatement > SAL_CALL OConnection::createStatement( ) throw(SQLExcep m_aStatements.push_back(WeakReferenceHelper(xReturn)); return xReturn; } -// -------------------------------------------------------------------------------- + Reference< XPreparedStatement > SAL_CALL OConnection::prepareStatement( const ::rtl::OUString& _sSql ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -163,7 +163,7 @@ Reference< XPreparedStatement > SAL_CALL OConnection::prepareStatement( const :: m_aStatements.push_back(WeakReferenceHelper(xReturn)); return xReturn; } -// -------------------------------------------------------------------------------- + Reference< XPreparedStatement > SAL_CALL OConnection::prepareCall( const ::rtl::OUString& _sSql ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -172,7 +172,7 @@ Reference< XPreparedStatement > SAL_CALL OConnection::prepareCall( const ::rtl:: // not implemented yet :-) a task to do return NULL; } -// -------------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL OConnection::nativeSQL( const ::rtl::OUString& _sSql ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -180,14 +180,14 @@ Reference< XPreparedStatement > SAL_CALL OConnection::prepareCall( const ::rtl:: return _sSql; } -// -------------------------------------------------------------------------------- + void SAL_CALL OConnection::setAutoCommit( sal_Bool autoCommit ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OConnection_BASE::rBHelper.bDisposed); // here you have to set your commit mode please have a look at the jdbc documentation to get a clear explanation } -// -------------------------------------------------------------------------------- + sal_Bool SAL_CALL OConnection::getAutoCommit( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -197,7 +197,7 @@ sal_Bool SAL_CALL OConnection::getAutoCommit( ) throw(SQLException, RuntimeExce return sal_True; } -// -------------------------------------------------------------------------------- + void SAL_CALL OConnection::commit( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -205,7 +205,7 @@ void SAL_CALL OConnection::commit( ) throw(SQLException, RuntimeException) // when you database does support transactions you should commit here } -// -------------------------------------------------------------------------------- + void SAL_CALL OConnection::rollback( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -214,7 +214,7 @@ void SAL_CALL OConnection::rollback( ) throw(SQLException, RuntimeException) // same as commit but for the other case } -// -------------------------------------------------------------------------------- + sal_Bool SAL_CALL OConnection::isClosed( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -222,7 +222,7 @@ sal_Bool SAL_CALL OConnection::isClosed( ) throw(SQLException, RuntimeException // just simple -> we are close when we are disposed that means someone called dispose(); (XComponent) return OConnection_BASE::rBHelper.bDisposed; } -// -------------------------------------------------------------------------------- + Reference< XDatabaseMetaData > SAL_CALL OConnection::getMetaData( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -239,7 +239,7 @@ Reference< XDatabaseMetaData > SAL_CALL OConnection::getMetaData( ) throw(SQLEx return xMetaData; } -// -------------------------------------------------------------------------------- + void SAL_CALL OConnection::setReadOnly( sal_Bool readOnly ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -247,7 +247,7 @@ void SAL_CALL OConnection::setReadOnly( sal_Bool readOnly ) throw(SQLException, // set you connection to readonly } -// -------------------------------------------------------------------------------- + sal_Bool SAL_CALL OConnection::isReadOnly( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -256,7 +256,7 @@ sal_Bool SAL_CALL OConnection::isReadOnly( ) throw(SQLException, RuntimeExcepti // return if your connection to readonly return sal_False; } -// -------------------------------------------------------------------------------- + void SAL_CALL OConnection::setCatalog( const ::rtl::OUString& catalog ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -264,7 +264,7 @@ void SAL_CALL OConnection::setCatalog( const ::rtl::OUString& catalog ) throw(SQ // if your database doesn't work with catalogs you go to next method otherwise you kjnow what to do } -// -------------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL OConnection::getCatalog( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -274,7 +274,7 @@ void SAL_CALL OConnection::setCatalog( const ::rtl::OUString& catalog ) throw(SQ // return your current catalog return ::rtl::OUString(); } -// -------------------------------------------------------------------------------- + void SAL_CALL OConnection::setTransactionIsolation( sal_Int32 level ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -283,7 +283,7 @@ void SAL_CALL OConnection::setTransactionIsolation( sal_Int32 level ) throw(SQLE // set your isolation level // please have a look at @see com.sun.star.sdbc.TransactionIsolation } -// -------------------------------------------------------------------------------- + sal_Int32 SAL_CALL OConnection::getTransactionIsolation( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -293,7 +293,7 @@ sal_Int32 SAL_CALL OConnection::getTransactionIsolation( ) throw(SQLException, // please have a look at @see com.sun.star.sdbc.TransactionIsolation return TransactionIsolation::NONE; } -// -------------------------------------------------------------------------------- + Reference< ::com::sun::star::container::XNameAccess > SAL_CALL OConnection::getTypeMap( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -303,12 +303,12 @@ Reference< ::com::sun::star::container::XNameAccess > SAL_CALL OConnection::getT return NULL; } -// -------------------------------------------------------------------------------- + void SAL_CALL OConnection::setTypeMap( const Reference< ::com::sun::star::container::XNameAccess >& typeMap ) throw(SQLException, RuntimeException) { // the other way around } -// -------------------------------------------------------------------------------- + // XCloseable void SAL_CALL OConnection::close( ) throw(SQLException, RuntimeException) { @@ -320,19 +320,19 @@ void SAL_CALL OConnection::close( ) throw(SQLException, RuntimeException) } dispose(); } -// -------------------------------------------------------------------------------- + // XWarningsSupplier Any SAL_CALL OConnection::getWarnings( ) throw(SQLException, RuntimeException) { // when you collected some warnings -> return it return Any(); } -// -------------------------------------------------------------------------------- + void SAL_CALL OConnection::clearWarnings( ) throw(SQLException, RuntimeException) { // you should clear your collected warnings here } -//-------------------------------------------------------------------- + void OConnection::buildTypeInfo() throw( SQLException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -377,7 +377,7 @@ void OConnection::buildTypeInfo() throw( SQLException) Reference< XCloseable> xClose(xRs,UNO_QUERY); xClose->close(); } -//------------------------------------------------------------------------------ + void OConnection::disposing() { // we noticed that we should be destroied in near future so we have to dispose our statements @@ -397,7 +397,7 @@ void OConnection::disposing() dispose_ChildImpl(); OConnection_BASE::disposing(); } -// ----------------------------------------------------------------------------- + diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDatabaseMetaData.cxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDatabaseMetaData.cxx index 05c74a020ecb..017faf0650fa 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDatabaseMetaData.cxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDatabaseMetaData.cxx @@ -57,11 +57,11 @@ ODatabaseMetaData::ODatabaseMetaData(OConnection* _pCon) osl_atomic_decrement( &m_refCount ); } } -// ------------------------------------------------------------------------- + ODatabaseMetaData::~ODatabaseMetaData() { } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getCatalogSeparator( ) throw(SQLException, RuntimeException) { ::rtl::OUString aVal; @@ -71,136 +71,136 @@ ODatabaseMetaData::~ODatabaseMetaData() return aVal; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxBinaryLiteralLength( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxRowSize( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxCatalogNameLength( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxCharLiteralLength( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxColumnNameLength( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxColumnsInIndex( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxCursorNameLength( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxConnections( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxColumnsInTable( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxStatementLength( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxTableNameLength( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxTablesInSelect( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- -// ------------------------------------------------------------------------- + + sal_Bool SAL_CALL ODatabaseMetaData::doesMaxRowSizeIncludeBlobs( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::storesLowerCaseQuotedIdentifiers( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::storesLowerCaseIdentifiers( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::storesMixedCaseQuotedIdentifiers( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::storesMixedCaseIdentifiers( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::storesUpperCaseQuotedIdentifiers( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::storesUpperCaseIdentifiers( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsAlterTableWithAddColumn( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsAlterTableWithDropColumn( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxIndexLength( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsNonNullableColumns( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getCatalogTerm( ) throw(SQLException, RuntimeException) { ::rtl::OUString aVal; @@ -209,25 +209,25 @@ sal_Bool SAL_CALL ODatabaseMetaData::supportsNonNullableColumns( ) throw(SQLExc } return aVal; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getIdentifierQuoteString( ) throw(SQLException, RuntimeException) { // normally this is " ::rtl::OUString aVal("\""); return aVal; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getExtraNameCharacters( ) throw(SQLException, RuntimeException) { ::rtl::OUString aVal; return aVal; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsDifferentTableCorrelationNames( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::isCatalogAtStart( ) throw(SQLException, RuntimeException) { sal_Bool bValue = sal_False; @@ -236,638 +236,638 @@ sal_Bool SAL_CALL ODatabaseMetaData::isCatalogAtStart( ) throw(SQLException, Ru } return bValue; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::dataDefinitionIgnoredInTransactions( ) throw(SQLException, RuntimeException) { return sal_True; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::dataDefinitionCausesTransactionCommit( ) throw(SQLException, RuntimeException) { return sal_True; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsDataManipulationTransactionsOnly( ) throw(SQLException, RuntimeException) { return sal_True; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsDataDefinitionAndDataManipulationTransactions( ) throw(SQLException, RuntimeException) { return sal_True; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsPositionedDelete( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsPositionedUpdate( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsOpenStatementsAcrossRollback( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsOpenStatementsAcrossCommit( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsOpenCursorsAcrossCommit( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsOpenCursorsAcrossRollback( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsTransactionIsolationLevel( sal_Int32 level ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsSchemasInDataManipulation( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsANSI92FullSQL( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsANSI92EntryLevelSQL( ) throw(SQLException, RuntimeException) { return sal_True; // should be supported at least } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsIntegrityEnhancementFacility( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsSchemasInIndexDefinitions( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsSchemasInTableDefinitions( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsCatalogsInTableDefinitions( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsCatalogsInIndexDefinitions( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsCatalogsInDataManipulation( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsOuterJoins( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxStatements( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxProcedureNameLength( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxSchemaNameLength( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsTransactions( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::allProceduresAreCallable( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsStoredProcedures( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsSelectForUpdate( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::allTablesAreSelectable( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::isReadOnly( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::usesLocalFiles( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::usesLocalFilePerTable( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsTypeConversion( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::nullPlusNonNullIsNull( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsColumnAliasing( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsTableCorrelationNames( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsConvert( sal_Int32 fromType, sal_Int32 toType ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsExpressionsInOrderBy( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsGroupBy( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsGroupByBeyondSelect( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsGroupByUnrelated( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsMultipleTransactions( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsMultipleResultSets( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsLikeEscapeClause( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsOrderByUnrelated( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsUnion( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsUnionAll( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsMixedCaseIdentifiers( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsMixedCaseQuotedIdentifiers( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::nullsAreSortedAtEnd( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::nullsAreSortedAtStart( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::nullsAreSortedHigh( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::nullsAreSortedLow( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsSchemasInProcedureCalls( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsSchemasInPrivilegeDefinitions( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsCatalogsInProcedureCalls( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsCatalogsInPrivilegeDefinitions( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsCorrelatedSubqueries( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsSubqueriesInComparisons( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsSubqueriesInExists( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsSubqueriesInIns( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsSubqueriesInQuantifieds( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsANSI92IntermediateSQL( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getURL( ) throw(SQLException, RuntimeException) { ::rtl::OUString aValue("sdbc:skeleton:"); return aValue; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getUserName( ) throw(SQLException, RuntimeException) { ::rtl::OUString aValue; return aValue; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getDriverName( ) throw(SQLException, RuntimeException) { ::rtl::OUString aValue; return aValue; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getDriverVersion() throw(SQLException, RuntimeException) { ::rtl::OUString aValue; return aValue; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getDatabaseProductVersion( ) throw(SQLException, RuntimeException) { ::rtl::OUString aValue; return aValue; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getDatabaseProductName( ) throw(SQLException, RuntimeException) { ::rtl::OUString aValue; return aValue; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getProcedureTerm( ) throw(SQLException, RuntimeException) { ::rtl::OUString aValue; return aValue; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getSchemaTerm( ) throw(SQLException, RuntimeException) { ::rtl::OUString aValue; return aValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getDriverMajorVersion( ) throw(RuntimeException) { return 1; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getDefaultTransactionIsolation( ) throw(SQLException, RuntimeException) { return TransactionIsolation::NONE; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getDriverMinorVersion( ) throw(RuntimeException) { return 0; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getSQLKeywords( ) throw(SQLException, RuntimeException) { ::rtl::OUString aValue; return aValue; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getSearchStringEscape( ) throw(SQLException, RuntimeException) { ::rtl::OUString aValue; return aValue; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getStringFunctions( ) throw(SQLException, RuntimeException) { return ::rtl::OUString(); } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getTimeDateFunctions( ) throw(SQLException, RuntimeException) { return ::rtl::OUString(); } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getSystemFunctions( ) throw(SQLException, RuntimeException) { return ::rtl::OUString(); } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL ODatabaseMetaData::getNumericFunctions( ) throw(SQLException, RuntimeException) { return ::rtl::OUString(); } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsExtendedSQLGrammar( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsCoreSQLGrammar( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsMinimumSQLGrammar( ) throw(SQLException, RuntimeException) { return sal_True; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsFullOuterJoins( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsLimitedOuterJoins( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxColumnsInGroupBy( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxColumnsInOrderBy( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxColumnsInSelect( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL ODatabaseMetaData::getMaxUserNameLength( ) throw(SQLException, RuntimeException) { sal_Int32 nValue = 0; // 0 means no limit return nValue; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsResultSetType( sal_Int32 setType ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsResultSetConcurrency( sal_Int32 setType, sal_Int32 concurrency ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::ownUpdatesAreVisible( sal_Int32 setType ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::ownDeletesAreVisible( sal_Int32 setType ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::ownInsertsAreVisible( sal_Int32 setType ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::othersUpdatesAreVisible( sal_Int32 setType ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::othersDeletesAreVisible( sal_Int32 setType ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::othersInsertsAreVisible( sal_Int32 setType ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::updatesAreDetected( sal_Int32 setType ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::deletesAreDetected( sal_Int32 setType ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::insertsAreDetected( sal_Int32 setType ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL ODatabaseMetaData::supportsBatchUpdates( ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + Reference< XConnection > SAL_CALL ODatabaseMetaData::getConnection( ) throw(SQLException, RuntimeException) { return (Reference< XConnection >)m_pConnection;//new OConnection(m_aConnectionHandle); } -// ------------------------------------------------------------------------- + // here follow all methods which return a resultset // the first methods is an example implementation how to use this resultset // of course you could implement it on your and you should do this because // the general way is more memory expensive -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getTableTypes( ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getTypeInfo( ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getCatalogs( ) throw(SQLException, RuntimeException) { return NULL; } -// ----------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getSchemas( ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getColumnPrivileges( const Any& catalog, const ::rtl::OUString& schema, const ::rtl::OUString& table, const ::rtl::OUString& columnNamePattern ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getColumns( const Any& catalog, const ::rtl::OUString& schemaPattern, const ::rtl::OUString& tableNamePattern, const ::rtl::OUString& columnNamePattern ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getTables( const Any& catalog, const ::rtl::OUString& schemaPattern, const ::rtl::OUString& tableNamePattern, const Sequence< ::rtl::OUString >& types ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getProcedureColumns( const Any& catalog, const ::rtl::OUString& schemaPattern, const ::rtl::OUString& procedureNamePattern, const ::rtl::OUString& columnNamePattern ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getProcedures( const Any& catalog, const ::rtl::OUString& schemaPattern, const ::rtl::OUString& procedureNamePattern ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getVersionColumns( const Any& catalog, const ::rtl::OUString& schema, const ::rtl::OUString& table ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getExportedKeys( const Any& catalog, const ::rtl::OUString& schema, const ::rtl::OUString& table ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getImportedKeys( const Any& catalog, const ::rtl::OUString& schema, const ::rtl::OUString& table ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getPrimaryKeys( const Any& catalog, const ::rtl::OUString& schema, const ::rtl::OUString& table ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getIndexInfo( const Any& catalog, const ::rtl::OUString& schema, const ::rtl::OUString& table, sal_Bool unique, sal_Bool approximate ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getBestRowIdentifier( const Any& catalog, const ::rtl::OUString& schema, const ::rtl::OUString& table, sal_Int32 scope, sal_Bool nullable ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getTablePrivileges( const Any& catalog, const ::rtl::OUString& schemaPattern, const ::rtl::OUString& tableNamePattern ) throw(SQLException, RuntimeException) { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getCrossReference( const Any& primaryCatalog, const ::rtl::OUString& primarySchema, const ::rtl::OUString& primaryTable, const Any& foreignCatalog, @@ -875,14 +875,14 @@ Reference< XResultSet > SAL_CALL ODatabaseMetaData::getCrossReference( { return NULL; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL ODatabaseMetaData::getUDTs( const Any& catalog, const ::rtl::OUString& schemaPattern, const ::rtl::OUString& typeNamePattern, const Sequence< sal_Int32 >& types ) throw(SQLException, RuntimeException) { OSL_FAIL("Not implemented yet!"); throw SQLException(); return NULL; } -// ----------------------------------------------------------------------------- + diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDriver.cxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDriver.cxx index 78d8145f8cd5..4134c83aff47 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDriver.cxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SDriver.cxx @@ -53,12 +53,12 @@ namespace connectivity } } } -// -------------------------------------------------------------------------------- + SkeletonDriver::SkeletonDriver() : ODriver_BASE(m_aMutex) { } -// -------------------------------------------------------------------------------- + void SkeletonDriver::disposing() { ::osl::MutexGuard aGuard(m_aMutex); @@ -76,7 +76,7 @@ void SkeletonDriver::disposing() } // static ServiceInfo -//------------------------------------------------------------------------------ + rtl::OUString SkeletonDriver::getImplementationName_Static( ) throw(RuntimeException) { return rtl::OUString("com.sun.star.comp.sdbc.SkeletonDriver"); @@ -118,7 +118,7 @@ Reference< XConnection > SAL_CALL SkeletonDriver::connect( const ::rtl::OUString return xCon; } -// -------------------------------------------------------------------------------- + sal_Bool SAL_CALL SkeletonDriver::acceptsURL( const ::rtl::OUString& url ) throw(SQLException, RuntimeException) { @@ -126,23 +126,23 @@ sal_Bool SAL_CALL SkeletonDriver::acceptsURL( const ::rtl::OUString& url ) // change the URL format to your needs, but please aware that the first on who accepts the URl wins. return url.startsWith("sdbc:skeleton:"); } -// -------------------------------------------------------------------------------- + Sequence< DriverPropertyInfo > SAL_CALL SkeletonDriver::getPropertyInfo( const ::rtl::OUString& url, const Sequence< PropertyValue >& info ) throw(SQLException, RuntimeException) { // if you have something special to say, return it here :-) return Sequence< DriverPropertyInfo >(); } -// -------------------------------------------------------------------------------- + sal_Int32 SAL_CALL SkeletonDriver::getMajorVersion( ) throw(RuntimeException) { return 0; // depends on you } -// -------------------------------------------------------------------------------- + sal_Int32 SAL_CALL SkeletonDriver::getMinorVersion( ) throw(RuntimeException) { return 1; // depends on you } -// -------------------------------------------------------------------------------- + //......................................................................... namespace connectivity diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SPreparedStatement.cxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SPreparedStatement.cxx index 17217402462f..1e9563a55f23 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SPreparedStatement.cxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SPreparedStatement.cxx @@ -62,21 +62,21 @@ OPreparedStatement::OPreparedStatement( OConnection* _pConnection,const TTypeInf ,m_nNumParams(0) { } -// ----------------------------------------------------------------------------- + OPreparedStatement::~OPreparedStatement() { } -// ----------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::acquire() throw() { OStatement_BASE2::acquire(); } -// ----------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::release() throw() { OStatement_BASE2::release(); } -// ----------------------------------------------------------------------------- + Any SAL_CALL OPreparedStatement::queryInterface( const Type & rType ) throw(RuntimeException) { Any aRet = OStatement_BASE2::queryInterface(rType); @@ -84,12 +84,12 @@ Any SAL_CALL OPreparedStatement::queryInterface( const Type & rType ) throw(Runt aRet = OPreparedStatement_BASE::queryInterface(rType); return aRet; } -// ------------------------------------------------------------------------- + ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL OPreparedStatement::getTypes( ) throw(::com::sun::star::uno::RuntimeException) { return concatSequences(OPreparedStatement_BASE::getTypes(),OStatement_BASE2::getTypes()); } -// ------------------------------------------------------------------------- + Reference< XResultSetMetaData > SAL_CALL OPreparedStatement::getMetaData( ) throw(SQLException, RuntimeException) { @@ -100,7 +100,7 @@ Reference< XResultSetMetaData > SAL_CALL OPreparedStatement::getMetaData( ) thr m_xMetaData = new OResultSetMetaData(getOwnConnection()); return m_xMetaData; } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::close( ) throw(SQLException, RuntimeException) { @@ -121,7 +121,7 @@ void SAL_CALL OPreparedStatement::close( ) throw(SQLException, RuntimeException // Remove this Statement object from the Connection object's // list } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OPreparedStatement::execute( ) throw(SQLException, RuntimeException) { @@ -132,7 +132,7 @@ sal_Bool SAL_CALL OPreparedStatement::execute( ) throw(SQLException, RuntimeExc // same as in statement with the difference that this statement also can contain parameter return sal_False; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL OPreparedStatement::executeUpdate( ) throw(SQLException, RuntimeException) { @@ -142,14 +142,14 @@ sal_Int32 SAL_CALL OPreparedStatement::executeUpdate( ) throw(SQLException, Run // same as in statement with the difference that this statement also can contain parameter return 0; } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setString( sal_Int32 parameterIndex, const ::rtl::OUString& x ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + Reference< XConnection > SAL_CALL OPreparedStatement::getConnection( ) throw(SQLException, RuntimeException) { @@ -158,7 +158,7 @@ Reference< XConnection > SAL_CALL OPreparedStatement::getConnection( ) throw(SQ return (Reference< XConnection >)m_pConnection; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL OPreparedStatement::executeQuery( ) throw(SQLException, RuntimeException) { @@ -170,7 +170,7 @@ Reference< XResultSet > SAL_CALL OPreparedStatement::executeQuery( ) throw(SQLE return rs; } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setBoolean( sal_Int32 parameterIndex, sal_Bool x ) throw(SQLException, RuntimeException) { @@ -178,7 +178,7 @@ void SAL_CALL OPreparedStatement::setBoolean( sal_Int32 parameterIndex, sal_Bool checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setByte( sal_Int32 parameterIndex, sal_Int8 x ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -186,7 +186,7 @@ void SAL_CALL OPreparedStatement::setByte( sal_Int32 parameterIndex, sal_Int8 x } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setDate( sal_Int32 parameterIndex, const Date& aData ) throw(SQLException, RuntimeException) { @@ -194,7 +194,7 @@ void SAL_CALL OPreparedStatement::setDate( sal_Int32 parameterIndex, const Date& checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setTime( sal_Int32 parameterIndex, const Time& aVal ) throw(SQLException, RuntimeException) @@ -203,7 +203,7 @@ void SAL_CALL OPreparedStatement::setTime( sal_Int32 parameterIndex, const Time& checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setTimestamp( sal_Int32 parameterIndex, const DateTime& aVal ) throw(SQLException, RuntimeException) { @@ -211,7 +211,7 @@ void SAL_CALL OPreparedStatement::setTimestamp( sal_Int32 parameterIndex, const checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setDouble( sal_Int32 parameterIndex, double x ) throw(SQLException, RuntimeException) { @@ -220,7 +220,7 @@ void SAL_CALL OPreparedStatement::setDouble( sal_Int32 parameterIndex, double x } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setFloat( sal_Int32 parameterIndex, float x ) throw(SQLException, RuntimeException) { @@ -228,7 +228,7 @@ void SAL_CALL OPreparedStatement::setFloat( sal_Int32 parameterIndex, float x ) checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setInt( sal_Int32 parameterIndex, sal_Int32 x ) throw(SQLException, RuntimeException) { @@ -236,7 +236,7 @@ void SAL_CALL OPreparedStatement::setInt( sal_Int32 parameterIndex, sal_Int32 x checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setLong( sal_Int32 parameterIndex, sal_Int64 aVal ) throw(SQLException, RuntimeException) { @@ -244,7 +244,7 @@ void SAL_CALL OPreparedStatement::setLong( sal_Int32 parameterIndex, sal_Int64 a checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setNull( sal_Int32 parameterIndex, sal_Int32 sqlType ) throw(SQLException, RuntimeException) { @@ -252,7 +252,7 @@ void SAL_CALL OPreparedStatement::setNull( sal_Int32 parameterIndex, sal_Int32 s checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setClob( sal_Int32 parameterIndex, const Reference< XClob >& x ) throw(SQLException, RuntimeException) { @@ -260,7 +260,7 @@ void SAL_CALL OPreparedStatement::setClob( sal_Int32 parameterIndex, const Refer checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setBlob( sal_Int32 parameterIndex, const Reference< XBlob >& x ) throw(SQLException, RuntimeException) { @@ -268,7 +268,7 @@ void SAL_CALL OPreparedStatement::setBlob( sal_Int32 parameterIndex, const Refer checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setArray( sal_Int32 parameterIndex, const Reference< XArray >& x ) throw(SQLException, RuntimeException) { @@ -276,7 +276,7 @@ void SAL_CALL OPreparedStatement::setArray( sal_Int32 parameterIndex, const Refe checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setRef( sal_Int32 parameterIndex, const Reference< XRef >& x ) throw(SQLException, RuntimeException) { @@ -284,7 +284,7 @@ void SAL_CALL OPreparedStatement::setRef( sal_Int32 parameterIndex, const Refere checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setObjectWithInfo( sal_Int32 parameterIndex, const Any& x, sal_Int32 sqlType, sal_Int32 scale ) throw(SQLException, RuntimeException) { @@ -292,7 +292,7 @@ void SAL_CALL OPreparedStatement::setObjectWithInfo( sal_Int32 parameterIndex, c ::osl::MutexGuard aGuard( m_aMutex ); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setObjectNull( sal_Int32 parameterIndex, sal_Int32 sqlType, const ::rtl::OUString& typeName ) throw(SQLException, RuntimeException) { @@ -300,7 +300,7 @@ void SAL_CALL OPreparedStatement::setObjectNull( sal_Int32 parameterIndex, sal_I checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setObject( sal_Int32 parameterIndex, const Any& x ) throw(SQLException, RuntimeException) { @@ -308,7 +308,7 @@ void SAL_CALL OPreparedStatement::setObject( sal_Int32 parameterIndex, const Any checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setShort( sal_Int32 parameterIndex, sal_Int16 x ) throw(SQLException, RuntimeException) { @@ -316,7 +316,7 @@ void SAL_CALL OPreparedStatement::setShort( sal_Int32 parameterIndex, sal_Int16 checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setBytes( sal_Int32 parameterIndex, const Sequence< sal_Int8 >& x ) throw(SQLException, RuntimeException) { @@ -324,7 +324,7 @@ void SAL_CALL OPreparedStatement::setBytes( sal_Int32 parameterIndex, const Sequ checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setCharacterStream( sal_Int32 parameterIndex, const Reference< ::com::sun::star::io::XInputStream >& x, sal_Int32 length ) throw(SQLException, RuntimeException) @@ -333,7 +333,7 @@ void SAL_CALL OPreparedStatement::setCharacterStream( sal_Int32 parameterIndex, checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::setBinaryStream( sal_Int32 parameterIndex, const Reference< ::com::sun::star::io::XInputStream >& x, sal_Int32 length ) throw(SQLException, RuntimeException) { @@ -341,27 +341,27 @@ void SAL_CALL OPreparedStatement::setBinaryStream( sal_Int32 parameterIndex, con checkDisposed(OStatement_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::clearParameters( ) throw(SQLException, RuntimeException) { } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::clearBatch( ) throw(SQLException, RuntimeException) { } -// ------------------------------------------------------------------------- + void SAL_CALL OPreparedStatement::addBatch( ) throw(SQLException, RuntimeException) { } -// ------------------------------------------------------------------------- + Sequence< sal_Int32 > SAL_CALL OPreparedStatement::executeBatch( ) throw(SQLException, RuntimeException) { return Sequence< sal_Int32 > (); } -// ------------------------------------------------------------------------- + void OPreparedStatement::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any& rValue) throw (Exception) { switch(nHandle) @@ -378,13 +378,13 @@ void OPreparedStatement::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,cons OStatement_Base::setFastPropertyValue_NoBroadcast(nHandle,rValue); } } -// ----------------------------------------------------------------------------- + void OPreparedStatement::checkParameterIndex(sal_Int32 _parameterIndex) { if( !_parameterIndex || _parameterIndex > m_nNumParams) throw SQLException(); } -// ----------------------------------------------------------------------------- + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SResultSet.cxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SResultSet.cxx index 5399186f9e77..b8e688c886fe 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SResultSet.cxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SResultSet.cxx @@ -97,7 +97,7 @@ void OResultSet::disposing(void) m_aStatement = NULL; m_xMetaData = NULL; } -// ------------------------------------------------------------------------- + Any SAL_CALL OResultSet::queryInterface( const Type & rType ) throw(RuntimeException) { Any aRet = OPropertySetHelper::queryInterface(rType); @@ -105,7 +105,7 @@ Any SAL_CALL OResultSet::queryInterface( const Type & rType ) throw(RuntimeExcep aRet = OResultSet_BASE::queryInterface(rType); return aRet; } -// ------------------------------------------------------------------------- + Sequence< Type > SAL_CALL OResultSet::getTypes( ) throw( RuntimeException) { OTypeCollection aTypes( @@ -115,7 +115,7 @@ Any SAL_CALL OResultSet::queryInterface( const Type & rType ) throw(RuntimeExcep return concatSequences(aTypes.getTypes(),OResultSet_BASE::getTypes()); } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL OResultSet::findColumn( const ::rtl::OUString& columnName ) throw(SQLException, RuntimeException) { @@ -135,7 +135,7 @@ sal_Int32 SAL_CALL OResultSet::findColumn( const ::rtl::OUString& columnName ) t break; return i; } -// ------------------------------------------------------------------------- + Reference< XInputStream > SAL_CALL OResultSet::getBinaryStream( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -144,7 +144,7 @@ Reference< XInputStream > SAL_CALL OResultSet::getBinaryStream( sal_Int32 column return NULL; } -// ------------------------------------------------------------------------- + Reference< XInputStream > SAL_CALL OResultSet::getCharacterStream( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -154,7 +154,7 @@ Reference< XInputStream > SAL_CALL OResultSet::getCharacterStream( sal_Int32 col return NULL; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::getBoolean( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -162,7 +162,7 @@ sal_Bool SAL_CALL OResultSet::getBoolean( sal_Int32 columnIndex ) throw(SQLExcep return sal_False; } -// ------------------------------------------------------------------------- + sal_Int8 SAL_CALL OResultSet::getByte( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { @@ -173,7 +173,7 @@ sal_Int8 SAL_CALL OResultSet::getByte( sal_Int32 columnIndex ) throw(SQLExceptio sal_Int8 nRet = 0; return nRet; } -// ------------------------------------------------------------------------- + Sequence< sal_Int8 > SAL_CALL OResultSet::getBytes( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { @@ -183,7 +183,7 @@ Sequence< sal_Int8 > SAL_CALL OResultSet::getBytes( sal_Int32 columnIndex ) thro return Sequence< sal_Int8 >(); } -// ------------------------------------------------------------------------- + Date SAL_CALL OResultSet::getDate( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { @@ -194,7 +194,7 @@ Date SAL_CALL OResultSet::getDate( sal_Int32 columnIndex ) throw(SQLException, R Date nRet; return nRet; } -// ------------------------------------------------------------------------- + double SAL_CALL OResultSet::getDouble( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { @@ -205,7 +205,7 @@ double SAL_CALL OResultSet::getDouble( sal_Int32 columnIndex ) throw(SQLExceptio double nRet = 0; return nRet; } -// ------------------------------------------------------------------------- + float SAL_CALL OResultSet::getFloat( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { @@ -216,7 +216,7 @@ float SAL_CALL OResultSet::getFloat( sal_Int32 columnIndex ) throw(SQLException, float nVal(0); return nVal; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL OResultSet::getInt( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { @@ -226,7 +226,7 @@ sal_Int32 SAL_CALL OResultSet::getInt( sal_Int32 columnIndex ) throw(SQLExceptio sal_Int32 nRet=0; return nRet; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL OResultSet::getRow( ) throw(SQLException, RuntimeException) { @@ -236,7 +236,7 @@ sal_Int32 SAL_CALL OResultSet::getRow( ) throw(SQLException, RuntimeException) sal_Int32 nValue = 0; return nValue; } -// ------------------------------------------------------------------------- + sal_Int64 SAL_CALL OResultSet::getLong( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { @@ -245,7 +245,7 @@ sal_Int64 SAL_CALL OResultSet::getLong( sal_Int32 columnIndex ) throw(SQLExcepti return sal_Int64(); } -// ------------------------------------------------------------------------- + Reference< XResultSetMetaData > SAL_CALL OResultSet::getMetaData( ) throw(SQLException, RuntimeException) { @@ -257,7 +257,7 @@ Reference< XResultSetMetaData > SAL_CALL OResultSet::getMetaData( ) throw(SQLEx m_xMetaData = new OResultSetMetaData(m_pStatement->getOwnConnection()); return m_xMetaData; } -// ------------------------------------------------------------------------- + Reference< XArray > SAL_CALL OResultSet::getArray( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -266,7 +266,7 @@ Reference< XArray > SAL_CALL OResultSet::getArray( sal_Int32 columnIndex ) throw return NULL; } -// ------------------------------------------------------------------------- + Reference< XClob > SAL_CALL OResultSet::getClob( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { @@ -275,7 +275,7 @@ Reference< XClob > SAL_CALL OResultSet::getClob( sal_Int32 columnIndex ) throw(S return NULL; } -// ------------------------------------------------------------------------- + Reference< XBlob > SAL_CALL OResultSet::getBlob( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -283,7 +283,7 @@ Reference< XBlob > SAL_CALL OResultSet::getBlob( sal_Int32 columnIndex ) throw(S return NULL; } -// ------------------------------------------------------------------------- + Reference< XRef > SAL_CALL OResultSet::getRef( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { @@ -292,7 +292,7 @@ Reference< XRef > SAL_CALL OResultSet::getRef( sal_Int32 columnIndex ) throw(SQL return NULL; } -// ------------------------------------------------------------------------- + Any SAL_CALL OResultSet::getObject( sal_Int32 columnIndex, const Reference< ::com::sun::star::container::XNameAccess >& typeMap ) throw(SQLException, RuntimeException) { @@ -301,7 +301,7 @@ Any SAL_CALL OResultSet::getObject( sal_Int32 columnIndex, const Reference< ::co return Any(); } -// ------------------------------------------------------------------------- + sal_Int16 SAL_CALL OResultSet::getShort( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { @@ -312,7 +312,7 @@ sal_Int16 SAL_CALL OResultSet::getShort( sal_Int32 columnIndex ) throw(SQLExcept sal_Int16 nRet=0; return nRet; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL OResultSet::getString( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) @@ -324,7 +324,7 @@ sal_Int16 SAL_CALL OResultSet::getShort( sal_Int32 columnIndex ) throw(SQLExcept ::rtl::OUString nRet; return nRet; } -// ------------------------------------------------------------------------- + Time SAL_CALL OResultSet::getTime( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { @@ -335,7 +335,7 @@ Time SAL_CALL OResultSet::getTime( sal_Int32 columnIndex ) throw(SQLException, R Time nRet; return nRet; } -// ------------------------------------------------------------------------- + DateTime SAL_CALL OResultSet::getTimestamp( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) @@ -348,7 +348,7 @@ DateTime SAL_CALL OResultSet::getTimestamp( sal_Int32 columnIndex ) throw(SQLExc DateTime nRet; return nRet; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::isBeforeFirst( ) throw(SQLException, RuntimeException) { @@ -360,7 +360,7 @@ sal_Bool SAL_CALL OResultSet::isBeforeFirst( ) throw(SQLException, RuntimeExcep // return true means there is no data return sal_True; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::isAfterLast( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -368,7 +368,7 @@ sal_Bool SAL_CALL OResultSet::isAfterLast( ) throw(SQLException, RuntimeExcepti return sal_True; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::isFirst( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -377,7 +377,7 @@ sal_Bool SAL_CALL OResultSet::isFirst( ) throw(SQLException, RuntimeException) return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::isLast( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -386,7 +386,7 @@ sal_Bool SAL_CALL OResultSet::isLast( ) throw(SQLException, RuntimeException) return sal_False; } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::beforeFirst( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -395,13 +395,13 @@ void SAL_CALL OResultSet::beforeFirst( ) throw(SQLException, RuntimeException) // move before the first row so that isBeforeFirst returns false // the same for other movement methods } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::afterLast( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::close( ) throw(SQLException, RuntimeException) { @@ -412,7 +412,7 @@ void SAL_CALL OResultSet::close( ) throw(SQLException, RuntimeException) } dispose(); } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::first( ) throw(SQLException, RuntimeException) { @@ -421,7 +421,7 @@ sal_Bool SAL_CALL OResultSet::first( ) throw(SQLException, RuntimeException) return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::last( ) throw(SQLException, RuntimeException) { @@ -430,7 +430,7 @@ sal_Bool SAL_CALL OResultSet::last( ) throw(SQLException, RuntimeException) return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::absolute( sal_Int32 row ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -438,7 +438,7 @@ sal_Bool SAL_CALL OResultSet::absolute( sal_Int32 row ) throw(SQLException, Runt return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::relative( sal_Int32 row ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -446,7 +446,7 @@ sal_Bool SAL_CALL OResultSet::relative( sal_Int32 row ) throw(SQLException, Runt return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::previous( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -454,7 +454,7 @@ sal_Bool SAL_CALL OResultSet::previous( ) throw(SQLException, RuntimeException) return sal_False; } -// ------------------------------------------------------------------------- + Reference< XInterface > SAL_CALL OResultSet::getStatement( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -463,7 +463,7 @@ Reference< XInterface > SAL_CALL OResultSet::getStatement( ) throw(SQLException return m_aStatement.get(); } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::rowDeleted( ) throw(SQLException, RuntimeException) { @@ -473,7 +473,7 @@ sal_Bool SAL_CALL OResultSet::rowDeleted( ) throw(SQLException, RuntimeExceptio return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::rowInserted( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -482,7 +482,7 @@ sal_Bool SAL_CALL OResultSet::rowInserted( ) throw(SQLException, RuntimeExcepti return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::rowUpdated( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -491,7 +491,7 @@ sal_Bool SAL_CALL OResultSet::rowUpdated( ) throw(SQLException, RuntimeExceptio return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::next( ) throw(SQLException, RuntimeException) { @@ -501,7 +501,7 @@ sal_Bool SAL_CALL OResultSet::next( ) throw(SQLException, RuntimeException) return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::wasNull( ) throw(SQLException, RuntimeException) { @@ -511,7 +511,7 @@ sal_Bool SAL_CALL OResultSet::wasNull( ) throw(SQLException, RuntimeException) return m_bWasNull; } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::cancel( ) throw(RuntimeException) { @@ -519,16 +519,16 @@ void SAL_CALL OResultSet::cancel( ) throw(RuntimeException) checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::clearWarnings( ) throw(SQLException, RuntimeException) { } -// ------------------------------------------------------------------------- + Any SAL_CALL OResultSet::getWarnings( ) throw(SQLException, RuntimeException) { return Any(); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::insertRow( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -536,7 +536,7 @@ void SAL_CALL OResultSet::insertRow( ) throw(SQLException, RuntimeException) // you only have to implement this if you want to insert new rows } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateRow( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -545,20 +545,20 @@ void SAL_CALL OResultSet::updateRow( ) throw(SQLException, RuntimeException) // only when you allow updates } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::deleteRow( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::cancelRowUpdates( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::moveToInsertRow( ) throw(SQLException, RuntimeException) { @@ -568,21 +568,21 @@ void SAL_CALL OResultSet::moveToInsertRow( ) throw(SQLException, RuntimeExcepti // only when you allow insert's } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::moveToCurrentRow( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateNull( sal_Int32 columnIndex ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateBoolean( sal_Int32 columnIndex, sal_Bool x ) throw(SQLException, RuntimeException) { @@ -590,14 +590,14 @@ void SAL_CALL OResultSet::updateBoolean( sal_Int32 columnIndex, sal_Bool x ) thr checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateByte( sal_Int32 columnIndex, sal_Int8 x ) throw(SQLException, RuntimeException) { checkDisposed(OResultSet_BASE::rBHelper.bDisposed); ::osl::MutexGuard aGuard( m_aMutex ); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateShort( sal_Int32 columnIndex, sal_Int16 x ) throw(SQLException, RuntimeException) { @@ -605,28 +605,28 @@ void SAL_CALL OResultSet::updateShort( sal_Int32 columnIndex, sal_Int16 x ) thro checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateInt( sal_Int32 columnIndex, sal_Int32 x ) throw(SQLException, RuntimeException) { checkDisposed(OResultSet_BASE::rBHelper.bDisposed); ::osl::MutexGuard aGuard( m_aMutex ); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateLong( sal_Int32 columnIndex, sal_Int64 x ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ----------------------------------------------------------------------- + void SAL_CALL OResultSet::updateFloat( sal_Int32 columnIndex, float x ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateDouble( sal_Int32 columnIndex, double x ) throw(SQLException, RuntimeException) { @@ -634,28 +634,28 @@ void SAL_CALL OResultSet::updateDouble( sal_Int32 columnIndex, double x ) throw( checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateString( sal_Int32 columnIndex, const ::rtl::OUString& x ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateBytes( sal_Int32 columnIndex, const Sequence< sal_Int8 >& x ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateDate( sal_Int32 columnIndex, const Date& x ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateTime( sal_Int32 columnIndex, const Time& x ) throw(SQLException, RuntimeException) { @@ -663,7 +663,7 @@ void SAL_CALL OResultSet::updateTime( sal_Int32 columnIndex, const Time& x ) thr checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateTimestamp( sal_Int32 columnIndex, const DateTime& x ) throw(SQLException, RuntimeException) { @@ -671,7 +671,7 @@ void SAL_CALL OResultSet::updateTimestamp( sal_Int32 columnIndex, const DateTime checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateBinaryStream( sal_Int32 columnIndex, const Reference< XInputStream >& x, sal_Int32 length ) throw(SQLException, RuntimeException) { @@ -679,28 +679,28 @@ void SAL_CALL OResultSet::updateBinaryStream( sal_Int32 columnIndex, const Refer checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateCharacterStream( sal_Int32 columnIndex, const Reference< XInputStream >& x, sal_Int32 length ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::refreshRow( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateObject( sal_Int32 columnIndex, const Any& x ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + void SAL_CALL OResultSet::updateNumericObject( sal_Int32 columnIndex, const Any& x, sal_Int32 scale ) throw(SQLException, RuntimeException) { @@ -708,7 +708,7 @@ void SAL_CALL OResultSet::updateNumericObject( sal_Int32 columnIndex, const Any& checkDisposed(OResultSet_BASE::rBHelper.bDisposed); } -// ------------------------------------------------------------------------- + // XRowLocate Any SAL_CALL OResultSet::getBookmark( ) throw( SQLException, RuntimeException) { @@ -719,7 +719,7 @@ Any SAL_CALL OResultSet::getBookmark( ) throw( SQLException, RuntimeException) return Any(); } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::moveToBookmark( const Any& bookmark ) throw( SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -727,7 +727,7 @@ sal_Bool SAL_CALL OResultSet::moveToBookmark( const Any& bookmark ) throw( SQLE return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::moveRelativeToBookmark( const Any& bookmark, sal_Int32 rows ) throw( SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -735,7 +735,7 @@ sal_Bool SAL_CALL OResultSet::moveRelativeToBookmark( const Any& bookmark, sal_ return sal_False; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL OResultSet::compareBookmarks( const Any& first, const Any& second ) throw( SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -744,17 +744,17 @@ sal_Int32 SAL_CALL OResultSet::compareBookmarks( const Any& first, const Any& return CompareBookmark::NOT_EQUAL; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSet::hasOrderedBookmarks( ) throw( SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL OResultSet::hashBookmark( const Any& bookmark ) throw( SQLException, RuntimeException) { throw SQLException(); } -// ------------------------------------------------------------------------- + // XDeleteRows Sequence< sal_Int32 > SAL_CALL OResultSet::deleteRows( const Sequence< Any >& rows ) throw( SQLException, RuntimeException) { @@ -763,7 +763,7 @@ Sequence< sal_Int32 > SAL_CALL OResultSet::deleteRows( const Sequence< Any >& return Sequence< sal_Int32 >(); } -// ------------------------------------------------------------------------- + IPropertyArrayHelper* OResultSet::createArrayHelper( ) const { Sequence< Property > aProps(6); @@ -778,12 +778,12 @@ IPropertyArrayHelper* OResultSet::createArrayHelper( ) const return new OPropertyArrayHelper(aProps); } -// ------------------------------------------------------------------------- + IPropertyArrayHelper & OResultSet::getInfoHelper() { return *const_cast<OResultSet*>(this)->getArrayHelper(); } -// ------------------------------------------------------------------------- + sal_Bool OResultSet::convertFastPropertyValue( Any & rConvertedValue, Any & rOldValue, @@ -806,7 +806,7 @@ sal_Bool OResultSet::convertFastPropertyValue( } return sal_False; } -// ------------------------------------------------------------------------- + void OResultSet::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const Any& rValue @@ -829,7 +829,7 @@ void OResultSet::setFastPropertyValue_NoBroadcast( ; } } -// ------------------------------------------------------------------------- + void OResultSet::getFastPropertyValue( Any& rValue, sal_Int32 nHandle @@ -846,22 +846,22 @@ void OResultSet::getFastPropertyValue( ; } } -// ----------------------------------------------------------------------------- + void SAL_CALL OResultSet::acquire() throw() { OResultSet_BASE::acquire(); } -// ----------------------------------------------------------------------------- + void SAL_CALL OResultSet::release() throw() { OResultSet_BASE::release(); } -// ----------------------------------------------------------------------------- + ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL OResultSet::getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException) { return ::cppu::OPropertySetHelper::createPropertySetInfo(getInfoHelper()); } -// ----------------------------------------------------------------------------- + diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SResultSetMetaData.cxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SResultSetMetaData.cxx index 727abb91410b..5f061e58dd13 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SResultSetMetaData.cxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SResultSetMetaData.cxx @@ -40,132 +40,132 @@ using namespace com::sun::star::uno; using namespace com::sun::star::lang; using namespace com::sun::star::sdbc; -// ------------------------------------------------------------------------- + OResultSetMetaData::~OResultSetMetaData() { } -// ------------------------------------------------------------------------- -// ------------------------------------------------------------------------- + + sal_Int32 SAL_CALL OResultSetMetaData::getColumnDisplaySize( sal_Int32 column ) throw(SQLException, RuntimeException) { return 50; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL OResultSetMetaData::getColumnType( sal_Int32 column ) throw(SQLException, RuntimeException) { sal_Int32 nType = 0; return nType; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL OResultSetMetaData::getColumnCount( ) throw(SQLException, RuntimeException) { // this make no sense here so you have to change this return 0; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSetMetaData::isCaseSensitive( sal_Int32 column ) throw(SQLException, RuntimeException) { return sal_True; } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL OResultSetMetaData::getSchemaName( sal_Int32 column ) throw(SQLException, RuntimeException) { return ::rtl::OUString(); } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL OResultSetMetaData::getColumnName( sal_Int32 column ) throw(SQLException, RuntimeException) { return ::rtl::OUString("Column") + ::rtl::OUString::number(column); } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL OResultSetMetaData::getTableName( sal_Int32 column ) throw(SQLException, RuntimeException) { return ::rtl::OUString(); } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL OResultSetMetaData::getCatalogName( sal_Int32 column ) throw(SQLException, RuntimeException) { return ::rtl::OUString(); } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL OResultSetMetaData::getColumnTypeName( sal_Int32 column ) throw(SQLException, RuntimeException) { return ::rtl::OUString(); } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL OResultSetMetaData::getColumnLabel( sal_Int32 column ) throw(SQLException, RuntimeException) { return ::rtl::OUString(); } -// ------------------------------------------------------------------------- + ::rtl::OUString SAL_CALL OResultSetMetaData::getColumnServiceName( sal_Int32 column ) throw(SQLException, RuntimeException) { return ::rtl::OUString(); } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSetMetaData::isCurrency( sal_Int32 column ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSetMetaData::isAutoIncrement( sal_Int32 column ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSetMetaData::isSigned( sal_Int32 column ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL OResultSetMetaData::getPrecision( sal_Int32 column ) throw(SQLException, RuntimeException) { return 0; } -// ----------------------------------------------------------------------------- + sal_Int32 SAL_CALL OResultSetMetaData::getScale( sal_Int32 column ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException) { return 0; } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL OResultSetMetaData::isNullable( sal_Int32 column ) throw(SQLException, RuntimeException) { return 0; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSetMetaData::isSearchable( sal_Int32 column ) throw(SQLException, RuntimeException) { return sal_True; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSetMetaData::isReadOnly( sal_Int32 column ) throw(SQLException, RuntimeException) { return sal_True; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSetMetaData::isDefinitelyWritable( sal_Int32 column ) throw(SQLException, RuntimeException) { return sal_False; ; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OResultSetMetaData::isWritable( sal_Int32 column ) throw(SQLException, RuntimeException) { return sal_False; } -// ------------------------------------------------------------------------- + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SServices.cxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SServices.cxx index 4873522982b5..83c3870bae5f 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SServices.cxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SServices.cxx @@ -62,7 +62,7 @@ typedef Reference< XSingleServiceFactory > (SAL_CALL *createFactoryFunc) // It contains of 3 special functions that have to be exported. // -//--------------------------------------------------------------------------------------- + void REGISTER_PROVIDER( const OUString& aServiceImplName, const Sequence< OUString>& Services, @@ -80,7 +80,7 @@ void REGISTER_PROVIDER( } -//--------------------------------------------------------------------------------------- + struct ProviderRequest { Reference< XSingleServiceFactory > xRet; @@ -118,7 +118,7 @@ struct ProviderRequest void* getProvider() const { return xRet.get(); } }; -//--------------------------------------------------------------------------------------- + extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory( const sal_Char* pImplementationName, void* pServiceManager, diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SStatement.cxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SStatement.cxx index 040159c02611..b5faafbfaa8c 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/SStatement.cxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/SStatement.cxx @@ -47,7 +47,7 @@ #include "propertyids.hxx" using namespace connectivity::skeleton; -//------------------------------------------------------------------------------ + using namespace com::sun::star::uno; using namespace com::sun::star::lang; using namespace com::sun::star::beans; @@ -56,7 +56,7 @@ using namespace com::sun::star::sdbcx; using namespace com::sun::star::container; using namespace com::sun::star::io; using namespace com::sun::star::util; -//------------------------------------------------------------------------------ + OStatement_Base::OStatement_Base(OConnection* _pConnection ) : OStatement_BASE(m_aMutex), OPropertySetHelper(OStatement_BASE::rBHelper), @@ -65,11 +65,11 @@ OStatement_Base::OStatement_Base(OConnection* _pConnection ) { m_pConnection->acquire(); } -// ----------------------------------------------------------------------------- + OStatement_Base::~OStatement_Base() { } -//------------------------------------------------------------------------------ + void OStatement_Base::disposeResultSet() { // free the cursor if alive @@ -78,7 +78,7 @@ void OStatement_Base::disposeResultSet() xComp->dispose(); m_xResultSet.clear(); } -//------------------------------------------------------------------------------ + void OStatement_BASE2::disposing() { ::osl::MutexGuard aGuard(m_aMutex); @@ -92,12 +92,12 @@ void OStatement_BASE2::disposing() dispose_ChildImpl(); OStatement_Base::disposing(); } -//----------------------------------------------------------------------------- + void SAL_CALL OStatement_BASE2::release() throw() { relase_ChildImpl(); } -//----------------------------------------------------------------------------- + Any SAL_CALL OStatement_Base::queryInterface( const Type & rType ) throw(RuntimeException) { Any aRet = OStatement_BASE::queryInterface(rType); @@ -105,7 +105,7 @@ Any SAL_CALL OStatement_Base::queryInterface( const Type & rType ) throw(Runtime aRet = OPropertySetHelper::queryInterface(rType); return aRet; } -// ------------------------------------------------------------------------- + Sequence< Type > SAL_CALL OStatement_Base::getTypes( ) throw(RuntimeException) { ::cppu::OTypeCollection aTypes( @@ -115,7 +115,7 @@ Sequence< Type > SAL_CALL OStatement_Base::getTypes( ) throw(RuntimeException) return concatSequences(aTypes.getTypes(),OStatement_BASE::getTypes()); } -// ------------------------------------------------------------------------- + void SAL_CALL OStatement_Base::cancel( ) throw(RuntimeException) { @@ -123,7 +123,7 @@ void SAL_CALL OStatement_Base::cancel( ) throw(RuntimeException) checkDisposed(OStatement_BASE::rBHelper.bDisposed); // cancel the current sql statement } -// ------------------------------------------------------------------------- + void SAL_CALL OStatement_Base::close( ) throw(SQLException, RuntimeException) { @@ -134,13 +134,13 @@ void SAL_CALL OStatement_Base::close( ) throw(SQLException, RuntimeException) } dispose(); } -// ------------------------------------------------------------------------- + void SAL_CALL OStatement::clearBatch( ) throw(SQLException, RuntimeException) { // if you support batches clear it here } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OStatement_Base::execute( const ::rtl::OUString& sql ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -149,7 +149,7 @@ sal_Bool SAL_CALL OStatement_Base::execute( const ::rtl::OUString& sql ) throw(S // returns true when a resultset is available return sal_False; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL OStatement_Base::executeQuery( const ::rtl::OUString& sql ) throw(SQLException, RuntimeException) { @@ -163,7 +163,7 @@ Reference< XResultSet > SAL_CALL OStatement_Base::executeQuery( const ::rtl::OUS m_xResultSet = xRS; // we nedd a reference to it for later use return xRS; } -// ------------------------------------------------------------------------- + Reference< XConnection > SAL_CALL OStatement_Base::getConnection( ) throw(SQLException, RuntimeException) { @@ -173,12 +173,12 @@ Reference< XConnection > SAL_CALL OStatement_Base::getConnection( ) throw(SQLEx // just return our connection here return (Reference< XConnection >)m_pConnection; } -// ----------------------------------------------------------------------------- + sal_Int32 SAL_CALL OStatement_Base::getUpdateCount( ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException) { return 0; } -// ------------------------------------------------------------------------- + Any SAL_CALL OStatement::queryInterface( const Type & rType ) throw(RuntimeException) { @@ -187,7 +187,7 @@ Any SAL_CALL OStatement::queryInterface( const Type & rType ) throw(RuntimeExcep aRet = OStatement_Base::queryInterface(rType); return aRet; } -// ------------------------------------------------------------------------- + void SAL_CALL OStatement::addBatch( const ::rtl::OUString& sql ) throw(SQLException, RuntimeException) { @@ -197,7 +197,7 @@ void SAL_CALL OStatement::addBatch( const ::rtl::OUString& sql ) throw(SQLExcept m_aBatchList.push_back(sql); } -// ------------------------------------------------------------------------- + Sequence< sal_Int32 > SAL_CALL OStatement::executeBatch( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -205,7 +205,7 @@ Sequence< sal_Int32 > SAL_CALL OStatement::executeBatch( ) throw(SQLException, return Sequence< sal_Int32 >(); } -// ------------------------------------------------------------------------- + sal_Int32 SAL_CALL OStatement_Base::executeUpdate( const ::rtl::OUString& sql ) throw(SQLException, RuntimeException) @@ -217,7 +217,7 @@ sal_Int32 SAL_CALL OStatement_Base::executeUpdate( const ::rtl::OUString& sql ) return 0; } -// ------------------------------------------------------------------------- + Reference< XResultSet > SAL_CALL OStatement_Base::getResultSet( ) throw(SQLException, RuntimeException) { @@ -227,7 +227,7 @@ Reference< XResultSet > SAL_CALL OStatement_Base::getResultSet( ) throw(SQLExce // return our save resultset here return m_xResultSet; } -// ------------------------------------------------------------------------- + sal_Bool SAL_CALL OStatement_Base::getMoreResults( ) throw(SQLException, RuntimeException) { @@ -238,9 +238,9 @@ sal_Bool SAL_CALL OStatement_Base::getMoreResults( ) throw(SQLException, Runtim // and has one more at this moment return true return sal_False; } -// ------------------------------------------------------------------------- -// ------------------------------------------------------------------------- + + Any SAL_CALL OStatement_Base::getWarnings( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -249,9 +249,9 @@ Any SAL_CALL OStatement_Base::getWarnings( ) throw(SQLException, RuntimeExcepti return makeAny(m_aLastWarning); } -// ------------------------------------------------------------------------- -// ------------------------------------------------------------------------- + + void SAL_CALL OStatement_Base::clearWarnings( ) throw(SQLException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -260,7 +260,7 @@ void SAL_CALL OStatement_Base::clearWarnings( ) throw(SQLException, RuntimeExce m_aLastWarning = SQLWarning(); } -// ------------------------------------------------------------------------- + ::cppu::IPropertyArrayHelper* OStatement_Base::createArrayHelper( ) const { // this properties are define by the service statement @@ -282,12 +282,12 @@ void SAL_CALL OStatement_Base::clearWarnings( ) throw(SQLException, RuntimeExce return new ::cppu::OPropertyArrayHelper(aProps); } -// ------------------------------------------------------------------------- + ::cppu::IPropertyArrayHelper & OStatement_Base::getInfoHelper() { return *const_cast<OStatement_Base*>(this)->getArrayHelper(); } -// ------------------------------------------------------------------------- + sal_Bool OStatement_Base::convertFastPropertyValue( Any & rConvertedValue, Any & rOldValue, @@ -299,7 +299,7 @@ sal_Bool OStatement_Base::convertFastPropertyValue( // here we have to try to convert return bConverted; } -// ------------------------------------------------------------------------- + void OStatement_Base::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any& rValue) throw (Exception) { // set the value to what ever is necessary @@ -319,7 +319,7 @@ void OStatement_Base::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const A ; } } -// ------------------------------------------------------------------------- + void OStatement_Base::getFastPropertyValue(Any& rValue,sal_Int32 nHandle) const { switch(nHandle) @@ -338,33 +338,33 @@ void OStatement_Base::getFastPropertyValue(Any& rValue,sal_Int32 nHandle) const ; } } -// ------------------------------------------------------------------------- + IMPLEMENT_SERVICE_INFO(OStatement,"com.sun.star.sdbcx.OStatement","com.sun.star.sdbc.Statement"); -// ----------------------------------------------------------------------------- + void SAL_CALL OStatement_Base::acquire() throw() { OStatement_BASE::acquire(); } -// ----------------------------------------------------------------------------- + void SAL_CALL OStatement_Base::release() throw() { OStatement_BASE::release(); } -// ----------------------------------------------------------------------------- + void SAL_CALL OStatement::acquire() throw() { OStatement_BASE2::acquire(); } -// ----------------------------------------------------------------------------- + void SAL_CALL OStatement::release() throw() { OStatement_BASE2::release(); } -// ----------------------------------------------------------------------------- + Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL OStatement_Base::getPropertySetInfo( ) throw(RuntimeException) { return ::cppu::OPropertySetHelper::createPropertySetInfo(getInfoHelper()); } -// ----------------------------------------------------------------------------- + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/odk/examples/DevelopersGuide/Database/DriverSkeleton/propertyids.cxx b/odk/examples/DevelopersGuide/Database/DriverSkeleton/propertyids.cxx index 832f59757f34..9b69be270c2e 100644 --- a/odk/examples/DevelopersGuide/Database/DriverSkeleton/propertyids.cxx +++ b/odk/examples/DevelopersGuide/Database/DriverSkeleton/propertyids.cxx @@ -105,7 +105,7 @@ namespace skeleton if(aIter->second) rtl_uString_release(aIter->second); } - // ------------------------------------------------------------------------------ + ::rtl::OUString OPropertyMap::getNameByIndex(sal_Int32 _nIndex) const { ::rtl::OUString sRet; @@ -116,7 +116,7 @@ namespace skeleton sRet = aIter->second; return sRet; } - // ------------------------------------------------------------------------------ + ::rtl::OUString OPropertyMap::fillValue(sal_Int32 _nIndex) { rtl_uString* pStr = NULL; diff --git a/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/FlatXmlFilter_cpp/FlatXml.cxx b/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/FlatXmlFilter_cpp/FlatXml.cxx index dfb9f6b8850f..bfb662e758f5 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/FlatXmlFilter_cpp/FlatXml.cxx +++ b/odk/examples/DevelopersGuide/OfficeDev/FilterDevelopment/FlatXmlFilter_cpp/FlatXml.cxx @@ -286,9 +286,9 @@ void XFlatXml::setDocumentLocator(const Reference<XLocator>& doclocator) m_rDocumentHandler->setDocumentLocator(doclocator); } -// -------------------------------------- + // Component management -// -------------------------------------- + Reference< XInterface > SAL_CALL CreateInstance( const Reference< XMultiServiceFactory > &r) { return Reference< XInterface >(( OWeakObject *)new XFlatXml(r)); diff --git a/odk/examples/cpp/custompanel/ctp_factory.cxx b/odk/examples/cpp/custompanel/ctp_factory.cxx index 9c8d5c50ddb2..7ff959a47586 100644 --- a/odk/examples/cpp/custompanel/ctp_factory.cxx +++ b/odk/examples/cpp/custompanel/ctp_factory.cxx @@ -51,18 +51,18 @@ namespace sd { namespace colortoolpanel //================================================================================================================== //= ToolPanelFactory //================================================================================================================== - //------------------------------------------------------------------------------------------------------------------ + ToolPanelFactory::ToolPanelFactory( const Reference< XComponentContext >& i_rContext ) :m_xContext( i_rContext ) { } - //------------------------------------------------------------------------------------------------------------------ + ToolPanelFactory::~ToolPanelFactory() { } - //------------------------------------------------------------------------------------------------------------------ + Reference< XUIElement > SAL_CALL ToolPanelFactory::createUIElement( const OUString& i_rResourceURL, const Sequence< PropertyValue >& i_rArgs ) throw (NoSuchElementException, IllegalArgumentException, RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -127,7 +127,7 @@ namespace sd { namespace colortoolpanel return aServiceNames; } - //------------------------------------------------------------------------------------------------------------------ + Reference< XInterface > SAL_CALL ToolPanelFactory::Create( const Reference< XComponentContext >& i_rContext ) throw (RuntimeException) { return *( new ToolPanelFactory( i_rContext ) ); diff --git a/odk/examples/cpp/custompanel/ctp_panel.cxx b/odk/examples/cpp/custompanel/ctp_panel.cxx index c84c13c77a09..e486de7e4d79 100644 --- a/odk/examples/cpp/custompanel/ctp_panel.cxx +++ b/odk/examples/cpp/custompanel/ctp_panel.cxx @@ -100,7 +100,7 @@ namespace sd { namespace colortoolpanel //================================================================================================================== //= class SingleColorPanel //================================================================================================================== - //------------------------------------------------------------------------------------------------------------------ + SingleColorPanel::SingleColorPanel( const Reference< XComponentContext >& i_rContext, const Reference< XWindow >& i_rParentWindow, const ::sal_Int32 i_nPanelColor ) :SingleColorPanel_Base( m_aMutex ) ,m_xWindow() @@ -124,12 +124,12 @@ namespace sd { namespace colortoolpanel osl_atomic_decrement( &m_refCount ); } - //------------------------------------------------------------------------------------------------------------------ + SingleColorPanel::~SingleColorPanel() { } - //------------------------------------------------------------------------------------------------------------------ + Reference< XWindow > SAL_CALL SingleColorPanel::getWindow() throw (RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -138,7 +138,7 @@ namespace sd { namespace colortoolpanel return m_xWindow; } - //------------------------------------------------------------------------------------------------------------------ + Reference< XAccessible > SAL_CALL SingleColorPanel::createAccessible( const Reference< XAccessible >& i_rParentAccessible ) throw (RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -151,7 +151,7 @@ namespace sd { namespace colortoolpanel return Reference< XAccessible >( getWindow(), UNO_QUERY ); } - //------------------------------------------------------------------------------------------------------------------ + void SAL_CALL SingleColorPanel::windowPaint( const PaintEvent& i_rEvent ) throw (RuntimeException) { try @@ -170,13 +170,13 @@ namespace sd { namespace colortoolpanel } } - //------------------------------------------------------------------------------------------------------------------ + void SAL_CALL SingleColorPanel::disposing( const EventObject& i_rSource ) throw (RuntimeException) { (void)i_rSource; } - //------------------------------------------------------------------------------------------------------------------ + void SAL_CALL SingleColorPanel::disposing() { ::osl::MutexGuard aGuard( m_aMutex ); @@ -198,7 +198,7 @@ namespace sd { namespace colortoolpanel //================================================================================================================== //= PanelUIElement //================================================================================================================== - //------------------------------------------------------------------------------------------------------------------ + PanelUIElement::PanelUIElement( const Reference< XComponentContext >& i_rContext, const Reference< XWindow >& i_rParentWindow, const OUString& i_rResourceURL, const ::sal_Int32 i_nPanelColor ) :PanelUIElement_Base( m_aMutex ) @@ -207,31 +207,31 @@ namespace sd { namespace colortoolpanel { } - //------------------------------------------------------------------------------------------------------------------ + PanelUIElement::~PanelUIElement() { } - //------------------------------------------------------------------------------------------------------------------ + Reference< XFrame > SAL_CALL PanelUIElement::getFrame() throw (RuntimeException) { // TODO return NULL; } - //------------------------------------------------------------------------------------------------------------------ + OUString SAL_CALL PanelUIElement::getResourceURL() throw (RuntimeException) { return m_sResourceURL; } - //------------------------------------------------------------------------------------------------------------------ + ::sal_Int16 SAL_CALL PanelUIElement::getType() throw (RuntimeException) { return UIElementType::TOOLPANEL; } - //------------------------------------------------------------------------------------------------------------------ + Reference< XInterface > SAL_CALL PanelUIElement::getRealInterface( ) throw (RuntimeException) { ::osl::MutexGuard aGuard( m_aMutex ); @@ -240,7 +240,7 @@ namespace sd { namespace colortoolpanel return m_xToolPanel; } - //------------------------------------------------------------------------------------------------------------------ + void SAL_CALL PanelUIElement::disposing() { Reference< XComponent > xPanelComponent( m_xToolPanel, UNO_QUERY_THROW ); diff --git a/odk/examples/cpp/custompanel/ctp_services.cxx b/odk/examples/cpp/custompanel/ctp_services.cxx index a8f5702ea9c5..d67dddd1aa81 100644 --- a/odk/examples/cpp/custompanel/ctp_services.cxx +++ b/odk/examples/cpp/custompanel/ctp_services.cxx @@ -48,7 +48,7 @@ namespace sd { namespace colortoolpanel extern "C" { - //------------------------------------------------------------------------------------------------------------------ + SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory( const sal_Char * pImplName, void * pServiceManager, void * pRegistryKey ) { return ::cppu::component_getFactoryHelper( pImplName, pServiceManager, pRegistryKey , ::sd::colortoolpanel::s_aServiceEntries ); |