20#include <PropertyForward.hxx>
22#include <com/sun/star/lang/DisposedException.hpp>
23#include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
24#include <com/sun/star/sdbcx/XAppend.hpp>
41 OUString _sName,
const std::vector< OUString>& _aPropertyList )
43 ,m_xDestContainer( _xDestContainer, UNO_SET_THROW )
51 if ( _aPropertyList.empty() )
52 _xSource->addPropertyChangeListener( OUString(),
this );
55 for (
auto const&
property : _aPropertyList)
56 _xSource->addPropertyChangeListener(
property,
this);
72 ::osl::MutexGuard aGuard(
m_aMutex );
75 throw DisposedException( OUString(), *
this );
94 xAppend->appendByDescriptor(
m_xDest );
101 if (
m_xDestInfo->hasPropertyByName( evt.PropertyName ) )
103 m_xDest->setPropertyValue( evt.PropertyName, evt.NewValue );
117 throw DisposedException( OUString(), *
this );
119 m_xSource->removePropertyChangeListener( OUString(),
this );
128 ::osl::MutexGuard aGuard(
m_aMutex );
132 OSL_ENSURE( !
m_xDest.is(),
"OPropertyForward::setDefinition: definition object is already set!" );
135 m_xDest.set( _xDest, UNO_SET_THROW );
mutable::osl::Mutex m_aMutex
css::uno::Reference< css::beans::XPropertySet > m_xDest
virtual void SAL_CALL propertyChange(const css::beans::PropertyChangeEvent &evt) override
void setDefinition(const css::uno::Reference< css::beans::XPropertySet > &_xDest)
virtual ~OPropertyForward() override
css::uno::Reference< css::beans::XPropertySetInfo > m_xDestInfo
css::uno::Reference< css::beans::XPropertySet > m_xSource
css::uno::Reference< css::container::XNameAccess > m_xDestContainer
OPropertyForward(const css::uno::Reference< css::beans::XPropertySet > &_xSource, const css::uno::Reference< css::container::XNameAccess > &_xDestContainer, OUString _sName, const std::vector< OUString > &_aPropertyList)
virtual void SAL_CALL disposing(const css::lang::EventObject &_rSource) override
const Reference< XRow > m_xSource
#define DBG_UNHANDLED_EXCEPTION(...)
Reference< XSingleServiceFactory > xFactory