LibreOffice Module dbaccess (master) 1
Public Member Functions | Private Member Functions | Private Attributes | List of all members
dbaui::NamedTableCopySource Class Reference

#include <WCopyTable.hxx>

Inheritance diagram for dbaui::NamedTableCopySource:
[legend]
Collaboration diagram for dbaui::NamedTableCopySource:
[legend]

Public Member Functions

 NamedTableCopySource (const css::uno::Reference< css::sdbc::XConnection > &_rxConnection, OUString _sTableName)
 
virtual OUString getQualifiedObjectName () const override
 retrieves the fully qualified name of the object to copy More...
 
virtual bool isView () const override
 determines whether the object is a view More...
 
virtual void copyUISettingsTo (const css::uno::Reference< css::beans::XPropertySet > &_rxObject) const override
 copies the UI settings of the object to the given target object. More...
 
virtual void copyFilterAndSortingTo (const css::uno::Reference< css::sdbc::XConnection > &_xConnection, const css::uno::Reference< css::beans::XPropertySet > &_rxObject) const override
 copies the filter and sorting More...
 
virtual css::uno::Sequence< OUString > getColumnNames () const override
 retrieves the column names of the to-be-copied object More...
 
virtual css::uno::Sequence< OUString > getPrimaryKeyColumnNames () const override
 retrieves the names of the primary keys of the to-be-copied object More...
 
virtual OFieldDescriptioncreateFieldDescription (const OUString &_rColumnName) const override
 creates a OFieldDescription for the given column of the to-be-copied object More...
 
virtual OUString getSelectStatement () const override
 returns the SELECT statement which can be used to retrieve the data of the to-be-copied object More...
 
virtual ::utl::SharedUNOComponent< css::sdbc::XPreparedStatement > getPreparedSelectStatement () const override
 returns the prepared statement which can be used to retrieve the data of the to-be-copied object More...
 
- Public Member Functions inherited from dbaui::ICopyTableSourceObject
virtual OUString getQualifiedObjectName () const =0
 retrieves the fully qualified name of the object to copy More...
 
virtual bool isView () const =0
 determines whether the object is a view More...
 
virtual void copyUISettingsTo (const css::uno::Reference< css::beans::XPropertySet > &_rxObject) const =0
 copies the UI settings of the object to the given target object. More...
 
virtual css::uno::Sequence< OUString > getColumnNames () const =0
 retrieves the column names of the to-be-copied object More...
 
virtual css::uno::Sequence< OUString > getPrimaryKeyColumnNames () const =0
 retrieves the names of the primary keys of the to-be-copied object More...
 
virtual OFieldDescriptioncreateFieldDescription (const OUString &_rColumnName) const =0
 creates a OFieldDescription for the given column of the to-be-copied object More...
 
virtual OUString getSelectStatement () const =0
 returns the SELECT statement which can be used to retrieve the data of the to-be-copied object More...
 
virtual void copyFilterAndSortingTo (const css::uno::Reference< css::sdbc::XConnection > &_xConnection, const css::uno::Reference< css::beans::XPropertySet > &_rxObject) const =0
 copies the filter and sorting More...
 
virtual ::utl::SharedUNOComponent< css::sdbc::XPreparedStatement > getPreparedSelectStatement () const =0
 returns the prepared statement which can be used to retrieve the data of the to-be-copied object More...
 
virtual ~ICopyTableSourceObject ()
 

Private Member Functions

void impl_ensureColumnInfo_throw ()
 
::utl::SharedUNOComponent< css::sdbc::XPreparedStatement > const & impl_ensureStatement_throw ()
 

Private Attributes

css::uno::Reference< css::sdbc::XConnection > m_xConnection
 
css::uno::Reference< css::sdbc::XDatabaseMetaData > m_xMetaData
 
OUString m_sTableName
 
OUString m_sTableCatalog
 
OUString m_sTableSchema
 
OUString m_sTableBareName
 
std::vector< OFieldDescriptionm_aColumnInfo
 
::utl::SharedUNOComponent< css::sdbc::XPreparedStatement > m_xStatement
 

Detailed Description

Definition at line 171 of file WCopyTable.hxx.

Constructor & Destructor Documentation

◆ NamedTableCopySource()

NamedTableCopySource::NamedTableCopySource ( const css::uno::Reference< css::sdbc::XConnection > &  _rxConnection,
OUString  _sTableName 
)

Member Function Documentation

◆ copyFilterAndSortingTo()

void NamedTableCopySource::copyFilterAndSortingTo ( const css::uno::Reference< css::sdbc::XConnection > &  _xConnection,
const css::uno::Reference< css::beans::XPropertySet > &  _rxObject 
) const
overridevirtual

copies the filter and sorting

Returns

Implements dbaui::ICopyTableSourceObject.

Definition at line 291 of file WCopyTable.cxx.

◆ copyUISettingsTo()

void NamedTableCopySource::copyUISettingsTo ( const css::uno::Reference< css::beans::XPropertySet > &  _rxObject) const
overridevirtual

copies the UI settings of the object to the given target object.

Might be ignored by implementations which do not have Ui settings.

Implements dbaui::ICopyTableSourceObject.

Definition at line 286 of file WCopyTable.cxx.

◆ createFieldDescription()

OFieldDescription * NamedTableCopySource::createFieldDescription ( const OUString &  _rColumnName) const
overridevirtual

creates a OFieldDescription for the given column of the to-be-copied object

Implements dbaui::ICopyTableSourceObject.

Definition at line 361 of file WCopyTable.cxx.

References m_aColumnInfo.

◆ getColumnNames()

Sequence< OUString > NamedTableCopySource::getColumnNames ( ) const
overridevirtual

retrieves the column names of the to-be-copied object

Implements dbaui::ICopyTableSourceObject.

Definition at line 329 of file WCopyTable.cxx.

References m_aColumnInfo.

◆ getPreparedSelectStatement()

utl::SharedUNOComponent< XPreparedStatement > NamedTableCopySource::getPreparedSelectStatement ( ) const
overridevirtual

returns the prepared statement which can be used to retrieve the data of the to-be-copied object

The default implementation of this method will simply prepare a statement with the return value of ->getSelectStatement.

Implements dbaui::ICopyTableSourceObject.

Definition at line 376 of file WCopyTable.cxx.

References impl_ensureStatement_throw().

◆ getPrimaryKeyColumnNames()

Sequence< OUString > NamedTableCopySource::getPrimaryKeyColumnNames ( ) const
overridevirtual

retrieves the names of the primary keys of the to-be-copied object

Implements dbaui::ICopyTableSourceObject.

Definition at line 338 of file WCopyTable.cxx.

References Any, DBG_UNHANDLED_EXCEPTION, Exception, m_sTableBareName, m_sTableCatalog, m_sTableSchema, and m_xMetaData.

◆ getQualifiedObjectName()

OUString NamedTableCopySource::getQualifiedObjectName ( ) const
overridevirtual

retrieves the fully qualified name of the object to copy

Implements dbaui::ICopyTableSourceObject.

Definition at line 262 of file WCopyTable.cxx.

References m_sTableName.

◆ getSelectStatement()

OUString NamedTableCopySource::getSelectStatement ( ) const
overridevirtual

returns the SELECT statement which can be used to retrieve the data of the to-be-copied object

Implements dbaui::ICopyTableSourceObject.

Definition at line 370 of file WCopyTable.cxx.

References m_sTableBareName, m_sTableCatalog, m_sTableSchema, and m_xConnection.

Referenced by impl_ensureStatement_throw().

◆ impl_ensureColumnInfo_throw()

void NamedTableCopySource::impl_ensureColumnInfo_throw ( )
private

◆ impl_ensureStatement_throw()

utl::SharedUNOComponent< XPreparedStatement > const & NamedTableCopySource::impl_ensureStatement_throw ( )
private

◆ isView()

bool NamedTableCopySource::isView ( ) const
overridevirtual

determines whether the object is a view

Implements dbaui::ICopyTableSourceObject.

Definition at line 267 of file WCopyTable.cxx.

References Any, DBG_UNHANDLED_EXCEPTION, Exception, m_sTableBareName, m_sTableCatalog, m_sTableSchema, and m_xMetaData.

Member Data Documentation

◆ m_aColumnInfo

std::vector< OFieldDescription > dbaui::NamedTableCopySource::m_aColumnInfo
private

◆ m_sTableBareName

OUString dbaui::NamedTableCopySource::m_sTableBareName
private

◆ m_sTableCatalog

OUString dbaui::NamedTableCopySource::m_sTableCatalog
private

◆ m_sTableName

OUString dbaui::NamedTableCopySource::m_sTableName
private

Definition at line 176 of file WCopyTable.hxx.

Referenced by getQualifiedObjectName(), and NamedTableCopySource().

◆ m_sTableSchema

OUString dbaui::NamedTableCopySource::m_sTableSchema
private

◆ m_xConnection

css::uno::Reference< css::sdbc::XConnection > dbaui::NamedTableCopySource::m_xConnection
private

Definition at line 174 of file WCopyTable.hxx.

Referenced by getSelectStatement(), and impl_ensureStatement_throw().

◆ m_xMetaData

css::uno::Reference< css::sdbc::XDatabaseMetaData > dbaui::NamedTableCopySource::m_xMetaData
private

Definition at line 175 of file WCopyTable.hxx.

Referenced by getPrimaryKeyColumnNames(), isView(), and NamedTableCopySource().

◆ m_xStatement

::utl::SharedUNOComponent< css::sdbc::XPreparedStatement > dbaui::NamedTableCopySource::m_xStatement
private

Definition at line 181 of file WCopyTable.hxx.

Referenced by impl_ensureStatement_throw().


The documentation for this class was generated from the following files: