LibreOffice Module svx (master) 1
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | List of all members
svx::ODataAccessObjectTransferable Class Reference

class for transferring data access objects (tables, queries, statements ...) More...

#include <dbaexchange.hxx>

Inheritance diagram for svx::ODataAccessObjectTransferable:
[legend]
Collaboration diagram for svx::ODataAccessObjectTransferable:
[legend]

Public Member Functions

void Update (const OUString &_rDatasource, const sal_Int32 _nCommandType, const OUString &_rCommand, const css::uno::Reference< css::sdbc::XConnection > &_rxConnection)
 should be used copying and the connection is needed. More...
 
void Update (const OUString &_rDatasource, const sal_Int32 _nCommandType, const OUString &_rCommand)
 should be used when copying a query object and no connection is available. More...
 
 ODataAccessObjectTransferable (const css::uno::Reference< css::beans::XPropertySet > &_rxLivingForm)
 with this ctor, only the object descriptor format will be provided More...
 
 ODataAccessObjectTransferable ()
 
- Public Member Functions inherited from TransferDataContainer
 TransferDataContainer ()
 
virtual ~TransferDataContainer () override
 
void CopyINetBookmark (const INetBookmark &rBkmk)
 
void CopyString (const OUString &rStr)
 
void CopyString (SotClipboardFormatId nFmt, const OUString &rStr)
 
void CopyByteString (SotClipboardFormatId nFormatId, const OString &rStr)
 
void CopyAnyData (SotClipboardFormatId nFormatId, const char *pData, sal_uLong nLen)
 
bool HasAnyData () const
 
void StartDrag (vcl::Window *pWindow, sal_Int8 nDragSourceActions, const Link< sal_Int8, void > &rCallback)
 
virtual void DragFinished (sal_Int8 nDropAction) override
 
void StartDrag (vcl::Window *pWindow, sal_Int8 nDragSourceActions)
 
- Public Member Functions inherited from TransferableHelper
virtual css::uno::Any SAL_CALL getTransferData (const css::datatransfer::DataFlavor &rFlavor) override
 
virtual css::uno::Sequence< css::datatransfer::DataFlavor > SAL_CALL getTransferDataFlavors () override
 
virtual sal_Bool SAL_CALL isDataFlavorSupported (const css::datatransfer::DataFlavor &rFlavor) override
 
virtual css::uno::Any SAL_CALL getTransferData2 (const css::datatransfer::DataFlavor &rFlavor, const OUString &rDestDoc) override
 
virtual sal_Bool SAL_CALL isComplex () override
 
void PrepareOLE (const TransferableObjectDescriptor &rObjDesc)
 
void CopyToClipboard (const css::uno::Reference< css::datatransfer::clipboard::XClipboard > &rClipboard) const
 
void CopyToClipboard (vcl::Window *pWindow) const
 
void CopyToPrimarySelection () const
 
void StartDrag (vcl::Window *pWindow, sal_Int8 nDragSourceActions)
 

Static Public Member Functions

static bool canExtractObjectDescriptor (const DataFlavorExVector &_rFlavors)
 checks whether or not an object descriptor can be extracted from the data flavor vector given More...
 
static ODataAccessDescriptor extractObjectDescriptor (const TransferableDataHelper &_rData)
 extracts an object descriptor from the transferable given More...
 
- Static Public Member Functions inherited from TransferableHelper
static void ClearPrimarySelection ()
 

Protected Member Functions

virtual void AddSupportedFormats () override
 
virtual bool GetData (const css::datatransfer::DataFlavor &rFlavor, const OUString &rDestDoc) override
 
virtual void ObjectReleased () override
 
const ODataAccessDescriptorgetDescriptor () const
 
ODataAccessDescriptorgetDescriptor ()
 
void addCompatibleSelectionDescription (const css::uno::Sequence< css::uno::Any > &_rSelRows)
 
- Protected Member Functions inherited from TransferableHelper
 ~TransferableHelper ()
 
const css::uno::Reference< css::datatransfer::clipboard::XClipboard > & getOwnClipboard () const
 
void implCallOwnLostOwnership (const css::uno::Reference< css::datatransfer::clipboard::XClipboard > &_rxClipboard, const css::uno::Reference< css::datatransfer::XTransferable > &_rxTrans)
 
void AddFormat (SotClipboardFormatId nFormat)
 
void AddFormat (const css::datatransfer::DataFlavor &rFlavor)
 
void RemoveFormat (SotClipboardFormatId nFormat)
 
void RemoveFormat (const css::datatransfer::DataFlavor &rFlavor)
 
bool HasFormat (SotClipboardFormatId nFormat)
 
void ClearFormats ()
 
bool SetAny (const css::uno::Any &rAny)
 
bool SetString (const OUString &rString)
 
bool SetBitmapEx (const BitmapEx &rBitmap, const css::datatransfer::DataFlavor &rFlavor)
 
bool SetGDIMetaFile (const GDIMetaFile &rMtf)
 
bool SetGraphic (const Graphic &rGraphic)
 
bool SetImageMap (const ImageMap &rIMap)
 
bool SetTransferableObjectDescriptor (const TransferableObjectDescriptor &rDesc)
 
bool SetINetBookmark (const INetBookmark &rBmk, const css::datatransfer::DataFlavor &rFlavor)
 
bool SetINetImage (const INetImage &rINtImg, const css::datatransfer::DataFlavor &rFlavor)
 
bool SetObject (void *pUserObject, sal_uInt32 nUserObjectId, const css::datatransfer::DataFlavor &rFlavor)
 
virtual void AddSupportedFormats ()=0
 
virtual bool GetData (const css::datatransfer::DataFlavor &rFlavor, const OUString &rDestDoc)=0
 
virtual bool WriteObject (tools::SvRef< SotTempStream > &rxOStm, void *pUserObject, sal_uInt32 nUserObjectId, const css::datatransfer::DataFlavor &rFlavor)
 
virtual void DragFinished (sal_Int8 nDropAction)
 
virtual void ObjectReleased ()
 
void CopyToSelection (const css::uno::Reference< css::datatransfer::clipboard::XClipboard > &rClipboard) const
 

Private Member Functions

SVX_DLLPRIVATE void construct (const OUString &_rDatasourceOrLocation, const OUString &_rConnectionResource, const sal_Int32 _nCommandType, const OUString &_rCommand, const css::uno::Reference< css::sdbc::XConnection > &_rxConnection, bool _bAddCommand, const OUString &_sActiveCommand)
 

Private Attributes

ODataAccessDescriptor m_aDescriptor
 
OUString m_sCompatibleObjectDescription
 

Detailed Description

class for transferring data access objects (tables, queries, statements ...)

Definition at line 155 of file dbaexchange.hxx.

Constructor & Destructor Documentation

◆ ODataAccessObjectTransferable() [1/2]

svx::ODataAccessObjectTransferable::ODataAccessObjectTransferable ( const css::uno::Reference< css::beans::XPropertySet > &  _rxLivingForm)

with this ctor, only the object descriptor format will be provided

References GetData.

◆ ODataAccessObjectTransferable() [2/2]

svx::ODataAccessObjectTransferable::ODataAccessObjectTransferable ( )

Definition at line 339 of file dbaexchange.cxx.

Member Function Documentation

◆ addCompatibleSelectionDescription()

void svx::ODataAccessObjectTransferable::addCompatibleSelectionDescription ( const css::uno::Sequence< css::uno::Any > &  _rSelRows)
protected

Definition at line 488 of file dbaexchange.cxx.

References Any, and m_sCompatibleObjectDescription.

◆ AddSupportedFormats()

void svx::ODataAccessObjectTransferable::AddSupportedFormats ( )
overrideprotectedvirtual

◆ canExtractObjectDescriptor()

bool svx::ODataAccessObjectTransferable::canExtractObjectDescriptor ( const DataFlavorExVector _rFlavors)
static

checks whether or not an object descriptor can be extracted from the data flavor vector given

Parameters
_rFlavorsavailable flavors
_nFormatsformats to accept

Definition at line 443 of file dbaexchange.cxx.

◆ construct()

void svx::ODataAccessObjectTransferable::construct ( const OUString &  _rDatasourceOrLocation,
const OUString &  _rConnectionResource,
const sal_Int32  _nCommandType,
const OUString &  _rCommand,
const css::uno::Reference< css::sdbc::XConnection > &  _rxConnection,
bool  _bAddCommand,
const OUString &  _sActiveCommand 
)
private

◆ extractObjectDescriptor()

ODataAccessDescriptor svx::ODataAccessObjectTransferable::extractObjectDescriptor ( const TransferableDataHelper _rData)
static

extracts an object descriptor from the transferable given

Definition at line 454 of file dbaexchange.cxx.

References Any, TransferableDataHelper::GetAny(), SotExchange::GetFormatDataFlavor(), and TransferableDataHelper::HasFormat().

◆ GetData()

bool svx::ODataAccessObjectTransferable::GetData ( const css::datatransfer::DataFlavor &  rFlavor,
const OUString &  rDestDoc 
)
overrideprotectedvirtual

◆ getDescriptor() [1/2]

ODataAccessDescriptor & svx::ODataAccessObjectTransferable::getDescriptor ( )
inlineprotected

Definition at line 219 of file dbaexchange.hxx.

◆ getDescriptor() [2/2]

const ODataAccessDescriptor & svx::ODataAccessObjectTransferable::getDescriptor ( ) const
inlineprotected

Definition at line 218 of file dbaexchange.hxx.

◆ ObjectReleased()

void svx::ODataAccessObjectTransferable::ObjectReleased ( )
overrideprotectedvirtual

Reimplemented from TransferableHelper.

Definition at line 504 of file dbaexchange.cxx.

References svx::ODataAccessDescriptor::clear(), and m_aDescriptor.

◆ Update() [1/2]

void svx::ODataAccessObjectTransferable::Update ( const OUString &  _rDatasource,
const sal_Int32  _nCommandType,
const OUString &  _rCommand 
)

should be used when copying a query object and no connection is available.

Parameters
_rDatasourceThe data source name.
_nCommandTypeThe kind of command.
See also
com.sun.star.sdbc.CommandType
Parameters
_rCommandThe command, either a name of a table or query or a SQL statement.

Definition at line 343 of file dbaexchange.cxx.

References construct().

◆ Update() [2/2]

void svx::ODataAccessObjectTransferable::Update ( const OUString &  _rDatasource,
const sal_Int32  _nCommandType,
const OUString &  _rCommand,
const css::uno::Reference< css::sdbc::XConnection > &  _rxConnection 
)

should be used copying and the connection is needed.

Parameters
_rDatasourceThe data source name.
_nCommandTypeThe kind of command.
See also
com.sun.star.sdbc.CommandType
Parameters
_rCommandThe command, either a name of a table or query or a SQL statement.

References Update.

Member Data Documentation

◆ m_aDescriptor

ODataAccessDescriptor svx::ODataAccessObjectTransferable::m_aDescriptor
private

Definition at line 157 of file dbaexchange.hxx.

Referenced by AddSupportedFormats(), construct(), GetData(), and ObjectReleased().

◆ m_sCompatibleObjectDescription

OUString svx::ODataAccessObjectTransferable::m_sCompatibleObjectDescription
private

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