LibreOffice Module dbaccess (master) 1
|
encapsulates access to the view of a database object. More...
#include <databaseobjectview.hxx>
Public Member Functions | |
DatabaseObjectView (const css::uno::Reference< css::uno::XComponentContext > &_rxORB, const css::uno::Reference< css::sdb::application::XDatabaseDocumentUI > &_rxApplication, const css::uno::Reference< css::frame::XFrame > &_rxParentFrame, OUString _sComponentURL) | |
virtual | ~DatabaseObjectView () |
void | setTargetFrame (const css::uno::Reference< css::frame::XFrame > &_rxFrame) |
sets the target frame into which the view should be loaded. More... | |
css::uno::Reference< css::lang::XComponent > | createNew (const css::uno::Reference< css::sdbc::XDataSource > &_xDataSource, const ::comphelper::NamedValueCollection &i_rDispatchArgs=::comphelper::NamedValueCollection()) |
opens a view for a to-be-created object More... | |
css::uno::Reference< css::lang::XComponent > | openExisting (const css::uno::Any &_aDataSource, const OUString &_rName, const ::comphelper::NamedValueCollection &i_rDispatchArgs) |
opens a view for an existent object More... | |
Protected Member Functions | |
virtual css::uno::Reference< css::lang::XComponent > | doCreateView (const css::uno::Any &_rDataSource, const OUString &_rObjectName, const ::comphelper::NamedValueCollection &i_rCreationArgs) |
creates the desired view More... | |
virtual void | fillDispatchArgs (::comphelper::NamedValueCollection &i_rDispatchArgs, const css::uno::Any &_rDataSource, const OUString &_rObjectName) |
const css::uno::Reference< css::sdb::application::XDatabaseDocumentUI > & | getApplicationUI () const |
css::uno::Reference< css::sdbc::XConnection > | getConnection () const |
Private Member Functions | |
css::uno::Reference< css::lang::XComponent > | doDispatch (const ::comphelper::NamedValueCollection &i_rDispatchArgs) |
Private Attributes | |
css::uno::Reference< css::uno::XComponentContext > | m_xORB |
css::uno::Reference< css::frame::XFrame > | m_xParentFrame |
css::uno::Reference< css::frame::XComponentLoader > | m_xFrameLoader |
css::uno::Reference< css::sdb::application::XDatabaseDocumentUI > | m_xApplication |
OUString | m_sComponentURL |
encapsulates access to the view of a database object.
Definition at line 39 of file databaseobjectview.hxx.
dbaui::DatabaseObjectView::DatabaseObjectView | ( | const css::uno::Reference< css::uno::XComponentContext > & | _rxORB, |
const css::uno::Reference< css::sdb::application::XDatabaseDocumentUI > & | _rxApplication, | ||
const css::uno::Reference< css::frame::XFrame > & | _rxParentFrame, | ||
OUString | _sComponentURL | ||
) |
Definition at line 52 of file databaseobjectview.cxx.
References m_xApplication, and m_xORB.
|
inlinevirtual |
Definition at line 96 of file databaseobjectview.hxx.
Reference< XComponent > dbaui::DatabaseObjectView::createNew | ( | const css::uno::Reference< css::sdbc::XDataSource > & | _xDataSource, |
const ::comphelper::NamedValueCollection & | i_rDispatchArgs = ::comphelper::NamedValueCollection() |
||
) |
opens a view for a to-be-created object
_xDataSource | the data source for which a new object is to be created |
Definition at line 73 of file databaseobjectview.cxx.
References Any, and doCreateView().
Referenced by dbaui::OApplicationController::Execute().
|
protectedvirtual |
creates the desired view
The default implementation will call <member>fillDispatchArgs</member>, followed by <member>doDispatch</member>.
_rDataSource | the data source, as passed to the <member>createNew</member> or <member>openExisting</member> method. |
_rObjectName | the name of the object for which the view is to be opened, or an empty string if a view for a new object should be created. |
_rCreationArgs | the arguments for the view's creation |
Reimplemented in dbaui::TableDesigner.
Definition at line 84 of file databaseobjectview.cxx.
References doDispatch(), fillDispatchArgs(), and comphelper::NamedValueCollection::merge().
Referenced by createNew(), dbaui::TableDesigner::doCreateView(), and openExisting().
|
private |
Definition at line 96 of file databaseobjectview.cxx.
References Any, DBG_UNHANDLED_EXCEPTION, ENSURE_OR_THROW, Exception, VCLUnoHelper::GetWindow(), m_sComponentURL, m_xFrameLoader, m_xORB, m_xParentFrame, and xFrame.
Referenced by doCreateView().
|
protectedvirtual |
Reimplemented in dbaui::QueryDesigner, dbaui::TableDesigner, and dbaui::ResultSetBrowser.
Definition at line 140 of file databaseobjectview.cxx.
References getConnection(), PROPERTY_ACTIVE_CONNECTION(), PROPERTY_DATASOURCE(), PROPERTY_DATASOURCENAME(), and comphelper::NamedValueCollection::put().
Referenced by doCreateView(), dbaui::QueryDesigner::fillDispatchArgs(), dbaui::TableDesigner::fillDispatchArgs(), and dbaui::ResultSetBrowser::fillDispatchArgs().
|
inlineprotected |
Definition at line 85 of file databaseobjectview.hxx.
References m_xApplication.
Referenced by dbaui::TableDesigner::impl_getConnectionProvidedDesigner_nothrow().
|
protected |
Definition at line 65 of file databaseobjectview.cxx.
References m_xApplication.
Referenced by dbaui::ResultSetBrowser::fillDispatchArgs(), fillDispatchArgs(), and dbaui::TableDesigner::impl_getConnectionProvidedDesigner_nothrow().
Reference< XComponent > dbaui::DatabaseObjectView::openExisting | ( | const css::uno::Any & | _aDataSource, |
const OUString & | _rName, | ||
const ::comphelper::NamedValueCollection & | i_rDispatchArgs | ||
) |
opens a view for an existent object
_xDataSource | the data source for which a new object is to be created |
_rObjectName | the name of the object to be edited |
_rArgs | Additional settings which should be forwarded to the frame |
Definition at line 78 of file databaseobjectview.cxx.
References doCreateView().
|
inline |
sets the target frame into which the view should be loaded.
By default, the view is loaded into a top-level frame not being part of the Desktop.
Definition at line 103 of file databaseobjectview.hxx.
References m_xFrameLoader.
|
private |
Definition at line 50 of file databaseobjectview.hxx.
Referenced by doDispatch().
|
private |
Definition at line 49 of file databaseobjectview.hxx.
Referenced by DatabaseObjectView(), getApplicationUI(), and getConnection().
|
private |
Definition at line 47 of file databaseobjectview.hxx.
Referenced by doDispatch(), and setTargetFrame().
|
private |
Definition at line 43 of file databaseobjectview.hxx.
Referenced by DatabaseObjectView(), and doDispatch().
|
private |
Definition at line 45 of file databaseobjectview.hxx.
Referenced by doDispatch().