1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
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 .
20 #ifndef _CMDMAILMSG_HXX_
21 #define _CMDMAILMSG_HXX_
23 #include <cppuhelper/implbase2.hxx>
24 #include <com/sun/star/lang/IllegalArgumentException.hpp>
25 #include <com/sun/star/container/XNameAccess.hpp>
27 #include <com/sun/star/system/XSimpleMailMessage.hpp>
28 #include <com/sun/star/uno/XComponentContext.hpp>
29 #include <com/sun/star/uno/Reference.hxx>
31 //----------------------------------------------------------
33 //----------------------------------------------------------
36 public cppu::WeakImplHelper2
<
37 ::com::sun::star::system::XSimpleMailMessage
,
38 ::com::sun::star::container::XNameAccess
>
40 OUString m_aRecipient
;
41 OUString m_aOriginator
;
43 ::com::sun::star::uno::Sequence
< OUString
> m_CcRecipients
;
44 ::com::sun::star::uno::Sequence
< OUString
> m_BccRecipients
;
45 ::com::sun::star::uno::Sequence
< OUString
> m_Attachments
;
47 ::osl::Mutex m_aMutex
;
53 //------------------------------------------------
55 //------------------------------------------------
57 virtual void SAL_CALL
setRecipient( const OUString
& aRecipient
)
58 throw (::com::sun::star::uno::RuntimeException
);
60 virtual OUString SAL_CALL
getRecipient( )
61 throw (::com::sun::star::uno::RuntimeException
);
63 virtual void SAL_CALL
setCcRecipient( const ::com::sun::star::uno::Sequence
< OUString
>& aCcRecipient
)
64 throw (::com::sun::star::uno::RuntimeException
);
66 virtual ::com::sun::star::uno::Sequence
< OUString
> SAL_CALL
getCcRecipient( )
67 throw (::com::sun::star::uno::RuntimeException
);
69 virtual void SAL_CALL
setBccRecipient( const ::com::sun::star::uno::Sequence
< OUString
>& aBccRecipient
)
70 throw (::com::sun::star::uno::RuntimeException
);
72 virtual ::com::sun::star::uno::Sequence
< OUString
> SAL_CALL
getBccRecipient( )
73 throw (::com::sun::star::uno::RuntimeException
);
75 virtual void SAL_CALL
setOriginator( const OUString
& aOriginator
)
76 throw (::com::sun::star::uno::RuntimeException
);
78 virtual OUString SAL_CALL
getOriginator( )
79 throw (::com::sun::star::uno::RuntimeException
);
81 virtual void SAL_CALL
setSubject( const OUString
& aSubject
)
82 throw (::com::sun::star::uno::RuntimeException
);
84 virtual OUString SAL_CALL
getSubject( )
85 throw (::com::sun::star::uno::RuntimeException
);
87 virtual void SAL_CALL
setAttachement( const ::com::sun::star::uno::Sequence
< OUString
>& aAttachement
)
88 throw (::com::sun::star::lang::IllegalArgumentException
, ::com::sun::star::uno::RuntimeException
);
90 virtual ::com::sun::star::uno::Sequence
< OUString
> SAL_CALL
getAttachement( )
91 throw (::com::sun::star::uno::RuntimeException
);
93 //------------------------------------------------
95 //------------------------------------------------
97 virtual ::com::sun::star::uno::Any SAL_CALL
getByName( const OUString
& aName
)
98 throw (::com::sun::star::container::NoSuchElementException
, ::com::sun::star::lang::WrappedTargetException
, ::com::sun::star::uno::RuntimeException
);
100 virtual ::com::sun::star::uno::Sequence
< OUString
> SAL_CALL
getElementNames( )
101 throw (::com::sun::star::uno::RuntimeException
) ;
103 virtual sal_Bool SAL_CALL
hasByName( const OUString
& aName
)
104 throw (::com::sun::star::uno::RuntimeException
);
106 //------------------------------------------------
108 //------------------------------------------------
110 virtual ::com::sun::star::uno::Type SAL_CALL
getElementType( )
111 throw (::com::sun::star::uno::RuntimeException
);
113 virtual sal_Bool SAL_CALL
hasElements( )
114 throw (::com::sun::star::uno::RuntimeException
);
120 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */