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

#include <tablecontainer.hxx>

Inheritance diagram for dbaccess::OTableContainer:
[legend]
Collaboration diagram for dbaccess::OTableContainer:
[legend]

Public Member Functions

virtual void SAL_CALL acquire () noexcept override
 
virtual void SAL_CALL release () noexcept override
 
 OTableContainer (::cppu::OWeakObject &_rParent, ::osl::Mutex &_rMutex, const css::uno::Reference< css::sdbc::XConnection > &_xCon, bool _bCase, const css::uno::Reference< css::container::XNameContainer > &_xTableDefinitions, IRefreshListener *_pRefreshListener, std::atomic< std::size_t > &_nInAppend)
 ctor of the container. More...
 
virtual ~OTableContainer () override
 
- Public Member Functions inherited from dbaccess::OFilteredContainer
 OFilteredContainer (::cppu::OWeakObject &_rParent, ::osl::Mutex &_rMutex, const css::uno::Reference< css::sdbc::XConnection > &_xCon, bool _bCase, IRefreshListener *_pRefreshListener, std::atomic< std::size_t > &_nInAppend)
 ctor of the container. More...
 
void dispose ()
 
void construct (const css::uno::Sequence< OUString > &_rTableFilter, const css::uno::Sequence< OUString > &_rTableTypeFilter)
 late ctor. More...
 
void construct (const css::uno::Reference< css::container::XNameAccess > &_rxMasterContainer, const css::uno::Sequence< OUString > &_rTableFilter, const css::uno::Sequence< OUString > &_rTableTypeFilter)
 late ctor. More...
 
bool isInitialized () const
 
- Public Member Functions inherited from connectivity::sdbcx::OCollection
virtual ~OCollection ()
 
 DECLARE_SERVICE_INFO ()
 
void reFill (const ::std::vector< OUString > &_rVector)
 
bool isCaseSensitive () const
 
void renameObject (const OUString &_sOldName, const OUString &_sNewName)
 
virtual void disposing ()
 
virtual void SAL_CALL acquire () noexcept override
 
virtual void SAL_CALL release () noexcept override
 
virtual css::uno::Any SAL_CALL queryInterface (const css::uno::Type &rType) override
 
virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes () override
 
virtual css::uno::Type SAL_CALL getElementType () override
 
virtual sal_Bool SAL_CALL hasElements () override
 
virtual sal_Int32 SAL_CALL getCount () override
 
virtual css::uno::Any SAL_CALL getByIndex (sal_Int32 Index) override
 
virtual css::uno::Any SAL_CALL getByName (const OUString &aName) override
 
virtual css::uno::Sequence< OUString > SAL_CALL getElementNames () override
 
virtual sal_Bool SAL_CALL hasByName (const OUString &aName) override
 
virtual css::uno::Reference< css::container::XEnumeration > SAL_CALL createEnumeration () override
 
virtual void SAL_CALL refresh () override
 
virtual void SAL_CALL addRefreshListener (const css::uno::Reference< css::util::XRefreshListener > &l) override
 
virtual void SAL_CALL removeRefreshListener (const css::uno::Reference< css::util::XRefreshListener > &l) override
 
virtual css::uno::Reference< css::beans::XPropertySet > SAL_CALL createDataDescriptor () override
 
virtual void SAL_CALL appendByDescriptor (const css::uno::Reference< css::beans::XPropertySet > &descriptor) override
 
virtual void SAL_CALL dropByName (const OUString &elementName) override
 
virtual void SAL_CALL dropByIndex (sal_Int32 index) override
 
virtual sal_Int32 SAL_CALL findColumn (const OUString &columnName) override
 
virtual void SAL_CALL addContainerListener (const css::uno::Reference< css::container::XContainerListener > &xListener) override
 
virtual void SAL_CALL removeContainerListener (const css::uno::Reference< css::container::XContainerListener > &xListener) override
 
- Public Member Functions inherited from cppu::ImplHelper1< css::container::XContainerListener >
virtual css::uno::Any SAL_CALL queryInterface (css::uno::Type const &rType) SAL_OVERRIDE
 
virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes () SAL_OVERRIDE
 
virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId () SAL_OVERRIDE
 

Private Member Functions

virtual void addMasterContainerListener () override
 
virtual void removeMasterContainerListener () override
 
virtual OUString getTableTypeRestriction () const override
 returns a string denoting the only type of tables allowed in this container, or an empty string if there is no such restriction More...
 
virtual connectivity::sdbcx::ObjectType createObject (const OUString &_rName) override
 
virtual css::uno::Reference< css::beans::XPropertySetcreateDescriptor () override
 
virtual connectivity::sdbcx::ObjectType appendObject (const OUString &_rForName, const css::uno::Reference< css::beans::XPropertySet > &descriptor) override
 
virtual void dropObject (sal_Int32 _nPos, const OUString &_sElementName) override
 
virtual void disposing () override
 tell the container to free all elements and all additional resources. More...
 
 DECLARE_SERVICE_INFO ()
 
virtual void SAL_CALL disposing (const css::lang::EventObject &Source) override
 
virtual void SAL_CALL elementInserted (const css::container::ContainerEvent &Event) override
 
virtual void SAL_CALL elementRemoved (const css::container::ContainerEvent &Event) override
 
virtual void SAL_CALL elementReplaced (const css::container::ContainerEvent &Event) override
 

Private Attributes

css::uno::Reference< css::container::XNameContainer > m_xTableDefinitions
 
::rtl::Reference< OContainerMediatorm_pTableMediator
 

Additional Inherited Members

- Protected Member Functions inherited from dbaccess::OFilteredContainer
virtual OUString getTableTypeRestriction () const =0
 returns a string denoting the only type of tables allowed in this container, or an empty string if there is no such restriction More...
 
virtual void addMasterContainerListener ()
 
virtual void removeMasterContainerListener ()
 
virtual void impl_refresh () override
 
virtual OUString getNameForObject (const ::connectivity::sdbcx::ObjectType &_xObject) override
 
virtual void disposing () override
 tell the container to free all elements and all additional resources. More...
 
void getAllTableTypeFilter (css::uno::Sequence< OUString > &_rFilter) const
 retrieve a table type filter to pass to <member scope="css::sdbc">XDatabaseMetaData::getTables</member>, according to the current data source settings More...
 
- Protected Member Functions inherited from connectivity::sdbcx::OCollection
virtual void impl_refresh ()=0
 
virtual ObjectType createObject (const OUString &_rName)=0
 
virtual css::uno::Reference< css::beans::XPropertySetcreateDescriptor ()
 
virtual ObjectType appendObject (const OUString &_rForName, const css::uno::Reference< css::beans::XPropertySet > &descriptor)
 
virtual void dropObject (sal_Int32 _nPos, const OUString &_sElementName)
 
virtual OUString getNameForObject (const ObjectType &_xObject)
 
ObjectType cloneDescriptor (const ObjectType &_descriptor)
 
 OCollection (::cppu::OWeakObject &_rParent, bool _bCase, ::osl::Mutex &_rMutex, const ::std::vector< OUString > &_rVector, bool _bUseIndexOnly=false, bool _bUseHardRef=true)
 
void clear_NoDispose ()
 
void insertElement (const OUString &_sElementName, const ObjectType &_xElement)
 
ObjectType getObject (sal_Int32 _nIndex)
 
- Protected Member Functions inherited from cppu::ImplHelper1< css::container::XContainerListener >
 ~ImplHelper1 () SAL_NOEXCEPT
 
- Protected Attributes inherited from dbaccess::OFilteredContainer
IRefreshListenerm_pRefreshListener
 
std::atomic< std::size_t > & m_nInAppend
 
css::uno::Reference< css::container::XNameAccess > m_xMasterContainer
 
css::uno::WeakReference< css::sdbc::XConnection > m_xConnection
 
css::uno::Reference< css::sdbc::XDatabaseMetaData > m_xMetaData
 
- Protected Attributes inherited from connectivity::sdbcx::OCollection
::std::unique_ptr< IObjectCollectionm_pElements
 
::comphelper::OInterfaceContainerHelper3< css::container::XContainerListener > m_aContainerListeners
 
::comphelper::OInterfaceContainerHelper3< css::util::XRefreshListener > m_aRefreshListeners
 
::cppu::OWeakObjectm_rParent
 
::osl::Mutex & m_rMutex
 
bool m_bUseIndexOnly
 

Detailed Description

Definition at line 41 of file tablecontainer.hxx.

Constructor & Destructor Documentation

◆ OTableContainer()

OTableContainer::OTableContainer ( ::cppu::OWeakObject _rParent,
::osl::Mutex &  _rMutex,
const css::uno::Reference< css::sdbc::XConnection > &  _xCon,
bool  _bCase,
const css::uno::Reference< css::container::XNameContainer > &  _xTableDefinitions,
IRefreshListener _pRefreshListener,
std::atomic< std::size_t > &  _nInAppend 
)

ctor of the container.

The parent has to support the <type scope="css::sdbc">XConnection</type> interface.

Parameters
_rParentthe object which acts as parent for the container. all refcounting is rerouted to this object
_rMutexthe access safety object of the parent
_rTableFilterrestricts the visible tables by name
_rTableTypeFilterrestricts the visible tables by type
See also
construct

Definition at line 88 of file tablecontainer.cxx.

◆ ~OTableContainer()

OTableContainer::~OTableContainer ( )
overridevirtual

Definition at line 100 of file tablecontainer.cxx.

Member Function Documentation

◆ acquire()

virtual void SAL_CALL dbaccess::OTableContainer::acquire ( )
inlineoverridevirtualnoexcept

Reimplemented from connectivity::sdbcx::OCollection.

Definition at line 71 of file tablecontainer.hxx.

References connectivity::sdbcx::OCollection::acquire().

◆ addMasterContainerListener()

void OTableContainer::addMasterContainerListener ( )
overrideprivatevirtual

◆ appendObject()

ObjectType OTableContainer::appendObject ( const OUString &  _rForName,
const css::uno::Reference< css::beans::XPropertySet > &  descriptor 
)
overrideprivatevirtual

◆ createDescriptor()

Reference< XPropertySet > OTableContainer::createDescriptor ( )
overrideprivatevirtual

◆ createObject()

connectivity::sdbcx::ObjectType OTableContainer::createObject ( const OUString &  _rName)
overrideprivatevirtual

◆ DECLARE_SERVICE_INFO()

dbaccess::OTableContainer::DECLARE_SERVICE_INFO ( )
private

◆ disposing() [1/2]

void OTableContainer::disposing ( )
overrideprivatevirtual

tell the container to free all elements and all additional resources.


After using this method the object may be reconstructed by calling one of the construct methods.

Reimplemented from dbaccess::OFilteredContainer.

Definition at line 431 of file tablecontainer.cxx.

References dbaccess::OFilteredContainer::disposing(), m_pTableMediator, and m_xTableDefinitions.

◆ disposing() [2/2]

void SAL_CALL OTableContainer::disposing ( const css::lang::EventObject &  Source)
overrideprivatevirtual

Definition at line 439 of file tablecontainer.cxx.

◆ dropObject()

void OTableContainer::dropObject ( sal_Int32  _nPos,
const OUString &  _sElementName 
)
overrideprivatevirtual

◆ elementInserted()

void SAL_CALL OTableContainer::elementInserted ( const css::container::ContainerEvent &  Event)
overrideprivatevirtual

◆ elementRemoved()

void SAL_CALL OTableContainer::elementRemoved ( const css::container::ContainerEvent &  Event)
overrideprivatevirtual

Definition at line 417 of file tablecontainer.cxx.

◆ elementReplaced()

void SAL_CALL OTableContainer::elementReplaced ( const css::container::ContainerEvent &  Event)
overrideprivatevirtual

◆ getTableTypeRestriction()

OUString OTableContainer::getTableTypeRestriction ( ) const
overrideprivatevirtual

returns a string denoting the only type of tables allowed in this container, or an empty string if there is no such restriction

Implements dbaccess::OFilteredContainer.

Definition at line 117 of file tablecontainer.cxx.

◆ release()

virtual void SAL_CALL dbaccess::OTableContainer::release ( )
inlineoverridevirtualnoexcept

Reimplemented from connectivity::sdbcx::OCollection.

Definition at line 72 of file tablecontainer.hxx.

References connectivity::sdbcx::OCollection::release().

◆ removeMasterContainerListener()

void OTableContainer::removeMasterContainerListener ( )
overrideprivatevirtual

Member Data Documentation

◆ m_pTableMediator

::rtl::Reference< OContainerMediator > dbaccess::OTableContainer::m_pTableMediator
private

Definition at line 45 of file tablecontainer.hxx.

Referenced by createObject(), and disposing().

◆ m_xTableDefinitions

css::uno::Reference< css::container::XNameContainer > dbaccess::OTableContainer::m_xTableDefinitions
private

Definition at line 44 of file tablecontainer.hxx.

Referenced by appendObject(), createObject(), disposing(), and dropObject().


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