Line data Source code
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_EXTENSIONS_SOURCE_ABPILOT_UNODIALOGABP_HXX
21 : #define INCLUDED_EXTENSIONS_SOURCE_ABPILOT_UNODIALOGABP_HXX
22 :
23 : #include <svtools/genericunodialog.hxx>
24 : #include <comphelper/proparrhlp.hxx>
25 : #include "componentmodule.hxx"
26 : #include <com/sun/star/task/XJob.hpp>
27 : #include <cppuhelper/implbase1.hxx>
28 :
29 :
30 : namespace abp
31 : {
32 :
33 : class OABSPilotUno;
34 : typedef ::svt::OGenericUnoDialog OABSPilotUno_DBase;
35 : typedef ::cppu::ImplHelper1< ::com::sun::star::task::XJob > OABSPilotUno_JBase;
36 : typedef ::comphelper::OPropertyArrayUsageHelper< OABSPilotUno > OABSPilotUno_PBase;
37 : /// the UNO wrapper for the address book source pilot
38 0 : class OABSPilotUno
39 : :public OModuleResourceClient
40 : ,public OABSPilotUno_DBase
41 : ,public OABSPilotUno_JBase
42 : ,public OABSPilotUno_PBase
43 : {
44 : OUString m_sDataSourceName;
45 : OABSPilotUno(const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& _rxORB);
46 :
47 : public:
48 : // XInterface (disambiguation)
49 : virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type& aType ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
50 : virtual void SAL_CALL acquire( ) throw () SAL_OVERRIDE;
51 : virtual void SAL_CALL release( ) throw () SAL_OVERRIDE;
52 :
53 : // XTypeProvider
54 : virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
55 : virtual ::com::sun::star::uno::Sequence<sal_Int8> SAL_CALL getImplementationId( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
56 :
57 : // XServiceInfo
58 : virtual OUString SAL_CALL getImplementationName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
59 : virtual ::comphelper::StringSequence SAL_CALL getSupportedServiceNames() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
60 :
61 : // XServiceInfo - static methods
62 : static ::com::sun::star::uno::Sequence< OUString > getSupportedServiceNames_Static() throw( ::com::sun::star::uno::RuntimeException );
63 : static OUString getImplementationName_Static() throw( ::com::sun::star::uno::RuntimeException );
64 : static ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >
65 : SAL_CALL Create(const ::com::sun::star::uno::Reference< com::sun::star::lang::XMultiServiceFactory >&);
66 :
67 : // XPropertySet
68 : virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo> SAL_CALL getPropertySetInfo() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
69 : virtual ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
70 :
71 : // OPropertyArrayUsageHelper
72 : virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const SAL_OVERRIDE;
73 :
74 : // XJob
75 : virtual ::com::sun::star::uno::Any SAL_CALL execute( const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::NamedValue >& lArgs ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
76 :
77 : // XInitialisation
78 : virtual void SAL_CALL initialize( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aArguments ) throw (::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
79 :
80 : using OABSPilotUno_DBase::execute;
81 : protected:
82 : // OGenericUnoDialog overridables
83 : virtual VclPtr<Dialog> createDialog(vcl::Window* _pParent) SAL_OVERRIDE;
84 : virtual void executedDialog(sal_Int16 _nExecutionResult) SAL_OVERRIDE;
85 : };
86 :
87 :
88 : } // namespace abp
89 :
90 : extern "C" void SAL_CALL createRegistryInfo_OABSPilotUno();
91 :
92 : #endif // INCLUDED_EXTENSIONS_SOURCE_ABPILOT_UNODIALOGABP_HXX
93 :
94 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|