LibreOffice Module dbaccess (master) 1
IController.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
20#ifndef INCLUDED_DBACCESS_ICONTROLLER_HXX
21#define INCLUDED_DBACCESS_ICONTROLLER_HXX
22
23#include <com/sun/star/uno/Reference.hxx>
24#include <com/sun/star/uno/Sequence.hxx>
26#include <rtl/ustring.hxx>
27#include <sal/types.h>
28
29namespace com::sun::star {
30 namespace beans {
31 struct PropertyValue;
32 }
33 namespace util {
34 struct URL;
35 }
36 namespace frame {
37 class XController;
38 }
39}
40
41class NotifyEvent;
42
43namespace dbaui
44{
45 // interface for controller depended calls like commands
47 {
48 public:
52 virtual void executeUnChecked(const css::util::URL& _rCommand, const css::uno::Sequence< css::beans::PropertyValue>& aArgs) = 0;
53
58 virtual void executeChecked(const css::util::URL& _rCommand, const css::uno::Sequence< css::beans::PropertyValue>& aArgs) = 0;
59
64 virtual void executeUnChecked(sal_uInt16 _nCommandId, const css::uno::Sequence< css::beans::PropertyValue>& aArgs) = 0;
65
70 virtual void executeChecked(sal_uInt16 _nCommandId, const css::uno::Sequence< css::beans::PropertyValue>& aArgs) = 0;
71
72
80 virtual bool isCommandEnabled(sal_uInt16 _nCommandId) const = 0;
81
89 virtual bool isCommandEnabled( const OUString& _rCompleteCommandURL ) const = 0;
90
95 virtual bool isDataSourceReadOnly() const = 0;
96
104 virtual css::uno::Reference< css::frame::XController >
106
109 virtual bool interceptUserInput( const NotifyEvent& _rEvent ) = 0;
110
111 virtual void SAL_CALL acquire( ) noexcept = 0;
112 virtual void SAL_CALL release( ) noexcept = 0;
113
114 protected:
116 };
117}
118#endif // INCLUDED_DBACCESS_ICONTROLLER_HXX
119
120/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual void executeUnChecked(const css::util::URL &_rCommand, const css::uno::Sequence< css::beans::PropertyValue > &aArgs)=0
executes the given command without checking if it is allowed
virtual void executeChecked(sal_uInt16 _nCommandId, const css::uno::Sequence< css::beans::PropertyValue > &aArgs)=0
executes the given command only when it is allowed
virtual css::uno::Reference< css::frame::XController > getXController()=0
provides access to the model of the controller
virtual bool isCommandEnabled(sal_uInt16 _nCommandId) const =0
checks if the given Command is enabled
virtual void executeChecked(const css::util::URL &_rCommand, const css::uno::Sequence< css::beans::PropertyValue > &aArgs)=0
executes the given command only when it is allowed
virtual void executeUnChecked(sal_uInt16 _nCommandId, const css::uno::Sequence< css::beans::PropertyValue > &aArgs)=0
executes the given command without checking if it is allowed
virtual bool isCommandEnabled(const OUString &_rCompleteCommandURL) const =0
checks if the given Command is enabled
virtual void SAL_CALL acquire() noexcept=0
virtual bool interceptUserInput(const NotifyEvent &_rEvent)=0
allows interception of user input, aka mouse clicks and key events
virtual bool isDataSourceReadOnly() const =0
checks if the selected data source is read only
#define DBACCESS_DLLPUBLIC