1f8e2c85aSAndrew Rist /************************************************************** 2*ae77b8caSAriel Constenla-Haile * 3f8e2c85aSAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one 4f8e2c85aSAndrew Rist * or more contributor license agreements. See the NOTICE file 5f8e2c85aSAndrew Rist * distributed with this work for additional information 6f8e2c85aSAndrew Rist * regarding copyright ownership. The ASF licenses this file 7f8e2c85aSAndrew Rist * to you under the Apache License, Version 2.0 (the 8f8e2c85aSAndrew Rist * "License"); you may not use this file except in compliance 9f8e2c85aSAndrew Rist * with the License. You may obtain a copy of the License at 10*ae77b8caSAriel Constenla-Haile * 11f8e2c85aSAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0 12*ae77b8caSAriel Constenla-Haile * 13f8e2c85aSAndrew Rist * Unless required by applicable law or agreed to in writing, 14f8e2c85aSAndrew Rist * software distributed under the License is distributed on an 15f8e2c85aSAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16f8e2c85aSAndrew Rist * KIND, either express or implied. See the License for the 17f8e2c85aSAndrew Rist * specific language governing permissions and limitations 18f8e2c85aSAndrew Rist * under the License. 19*ae77b8caSAriel Constenla-Haile * 20f8e2c85aSAndrew Rist *************************************************************/ 21f8e2c85aSAndrew Rist 22cdf0e10cSrcweir // MARKER(update_precomp.py): autogen include statement, do not remove 23cdf0e10cSrcweir #include "precompiled_shell.hxx" 24cdf0e10cSrcweir 25cdf0e10cSrcweir #include "cmdmailmsg.hxx" 26cdf0e10cSrcweir 27cdf0e10cSrcweir using com::sun::star::lang::IllegalArgumentException; 28cdf0e10cSrcweir using rtl::OUString; 29cdf0e10cSrcweir using osl::MutexGuard; 30cdf0e10cSrcweir 31cdf0e10cSrcweir using namespace cppu; 32cdf0e10cSrcweir using namespace com::sun::star::uno; 33cdf0e10cSrcweir 34*ae77b8caSAriel Constenla-Haile namespace shell 35*ae77b8caSAriel Constenla-Haile { 36*ae77b8caSAriel Constenla-Haile CmdMailMsg()37*ae77b8caSAriel Constenla-HaileCmdMailMsg::CmdMailMsg() 38*ae77b8caSAriel Constenla-Haile { 39*ae77b8caSAriel Constenla-Haile } 40cdf0e10cSrcweir setBody(const OUString & aBody)4133bc51b9SAriel Constenla-Hailevoid SAL_CALL CmdMailMsg::setBody( const OUString& aBody ) 4233bc51b9SAriel Constenla-Haile throw (RuntimeException) 4333bc51b9SAriel Constenla-Haile { 4433bc51b9SAriel Constenla-Haile MutexGuard aGuard( m_aMutex ); 4533bc51b9SAriel Constenla-Haile m_aBody = aBody; 4633bc51b9SAriel Constenla-Haile } 47cdf0e10cSrcweir getBody()4833bc51b9SAriel Constenla-HaileOUString SAL_CALL CmdMailMsg::getBody( ) 49cdf0e10cSrcweir throw (RuntimeException) 50cdf0e10cSrcweir { 51cdf0e10cSrcweir MutexGuard aGuard( m_aMutex ); 5233bc51b9SAriel Constenla-Haile return m_aBody; 53cdf0e10cSrcweir } 54cdf0e10cSrcweir setRecipient(const OUString & aRecipient)5533bc51b9SAriel Constenla-Hailevoid SAL_CALL CmdMailMsg::setRecipient( const OUString& aRecipient ) 5633bc51b9SAriel Constenla-Haile throw (RuntimeException) 5733bc51b9SAriel Constenla-Haile { 5833bc51b9SAriel Constenla-Haile MutexGuard aGuard( m_aMutex ); 5933bc51b9SAriel Constenla-Haile m_aRecipient = aRecipient; 6033bc51b9SAriel Constenla-Haile } 61cdf0e10cSrcweir getRecipient()6233bc51b9SAriel Constenla-HaileOUString SAL_CALL CmdMailMsg::getRecipient( ) 63cdf0e10cSrcweir throw (RuntimeException) 64cdf0e10cSrcweir { 65cdf0e10cSrcweir MutexGuard aGuard( m_aMutex ); 66cdf0e10cSrcweir return m_aRecipient; 67cdf0e10cSrcweir } 68cdf0e10cSrcweir setCcRecipient(const Sequence<OUString> & aCcRecipient)69*ae77b8caSAriel Constenla-Hailevoid SAL_CALL CmdMailMsg::setCcRecipient( const Sequence< OUString >& aCcRecipient ) 70cdf0e10cSrcweir throw (RuntimeException) 71cdf0e10cSrcweir { 72cdf0e10cSrcweir MutexGuard aGuard( m_aMutex ); 73cdf0e10cSrcweir m_CcRecipients = aCcRecipient; 74cdf0e10cSrcweir } 75cdf0e10cSrcweir getCcRecipient()76*ae77b8caSAriel Constenla-HaileSequence< OUString > SAL_CALL CmdMailMsg::getCcRecipient( ) 77cdf0e10cSrcweir throw (RuntimeException) 78cdf0e10cSrcweir { 79cdf0e10cSrcweir MutexGuard aGuard( m_aMutex ); 80cdf0e10cSrcweir return m_CcRecipients; 81cdf0e10cSrcweir } 82cdf0e10cSrcweir setBccRecipient(const Sequence<OUString> & aBccRecipient)83*ae77b8caSAriel Constenla-Hailevoid SAL_CALL CmdMailMsg::setBccRecipient( const Sequence< OUString >& aBccRecipient ) 84cdf0e10cSrcweir throw (RuntimeException) 85cdf0e10cSrcweir { 86cdf0e10cSrcweir MutexGuard aGuard( m_aMutex ); 87cdf0e10cSrcweir m_BccRecipients = aBccRecipient; 88cdf0e10cSrcweir } 89cdf0e10cSrcweir getBccRecipient()90*ae77b8caSAriel Constenla-HaileSequence< OUString > SAL_CALL CmdMailMsg::getBccRecipient( ) 91cdf0e10cSrcweir throw (RuntimeException) 92cdf0e10cSrcweir { 93cdf0e10cSrcweir MutexGuard aGuard( m_aMutex ); 94cdf0e10cSrcweir return m_BccRecipients; 95cdf0e10cSrcweir } 96cdf0e10cSrcweir setOriginator(const OUString & aOriginator)97*ae77b8caSAriel Constenla-Hailevoid SAL_CALL CmdMailMsg::setOriginator( const OUString& aOriginator ) 98cdf0e10cSrcweir throw (RuntimeException) 99cdf0e10cSrcweir { 100cdf0e10cSrcweir MutexGuard aGuard( m_aMutex ); 101cdf0e10cSrcweir m_aOriginator = aOriginator; 102cdf0e10cSrcweir } 103cdf0e10cSrcweir getOriginator()104*ae77b8caSAriel Constenla-HaileOUString SAL_CALL CmdMailMsg::getOriginator( ) 105cdf0e10cSrcweir throw (RuntimeException) 106cdf0e10cSrcweir { 107cdf0e10cSrcweir MutexGuard aGuard( m_aMutex ); 108cdf0e10cSrcweir return m_aOriginator; 109cdf0e10cSrcweir } 110cdf0e10cSrcweir setSubject(const OUString & aSubject)111*ae77b8caSAriel Constenla-Hailevoid SAL_CALL CmdMailMsg::setSubject( const OUString& aSubject ) 112cdf0e10cSrcweir throw (RuntimeException) 113cdf0e10cSrcweir { 114cdf0e10cSrcweir MutexGuard aGuard( m_aMutex ); 115cdf0e10cSrcweir m_aSubject = aSubject; 116cdf0e10cSrcweir } 117cdf0e10cSrcweir getSubject()118*ae77b8caSAriel Constenla-HaileOUString SAL_CALL CmdMailMsg::getSubject( ) 119cdf0e10cSrcweir throw (RuntimeException) 120cdf0e10cSrcweir { 121cdf0e10cSrcweir MutexGuard aGuard( m_aMutex ); 122cdf0e10cSrcweir return m_aSubject; 123cdf0e10cSrcweir } 124cdf0e10cSrcweir setAttachement(const Sequence<OUString> & aAttachment)12533bc51b9SAriel Constenla-Hailevoid SAL_CALL CmdMailMsg::setAttachement( const Sequence< OUString >& aAttachment ) 126cdf0e10cSrcweir throw (IllegalArgumentException, RuntimeException) 127cdf0e10cSrcweir { 128cdf0e10cSrcweir MutexGuard aGuard( m_aMutex ); 129cdf0e10cSrcweir m_Attachments = aAttachment; 130cdf0e10cSrcweir } 131cdf0e10cSrcweir getAttachement()132*ae77b8caSAriel Constenla-HaileSequence< OUString > SAL_CALL CmdMailMsg::getAttachement( ) 133cdf0e10cSrcweir throw (RuntimeException) 134cdf0e10cSrcweir { 135cdf0e10cSrcweir MutexGuard aGuard( m_aMutex ); 136cdf0e10cSrcweir return m_Attachments; 137cdf0e10cSrcweir } 138cdf0e10cSrcweir 139cdf0e10cSrcweir } 140