1*cdf0e10cSrcweir /************************************************************************* 2*cdf0e10cSrcweir * 3*cdf0e10cSrcweir * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4*cdf0e10cSrcweir * 5*cdf0e10cSrcweir * Copyright 2000, 2010 Oracle and/or its affiliates. 6*cdf0e10cSrcweir * 7*cdf0e10cSrcweir * OpenOffice.org - a multi-platform office productivity suite 8*cdf0e10cSrcweir * 9*cdf0e10cSrcweir * This file is part of OpenOffice.org. 10*cdf0e10cSrcweir * 11*cdf0e10cSrcweir * OpenOffice.org is free software: you can redistribute it and/or modify 12*cdf0e10cSrcweir * it under the terms of the GNU Lesser General Public License version 3 13*cdf0e10cSrcweir * only, as published by the Free Software Foundation. 14*cdf0e10cSrcweir * 15*cdf0e10cSrcweir * OpenOffice.org is distributed in the hope that it will be useful, 16*cdf0e10cSrcweir * but WITHOUT ANY WARRANTY; without even the implied warranty of 17*cdf0e10cSrcweir * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18*cdf0e10cSrcweir * GNU Lesser General Public License version 3 for more details 19*cdf0e10cSrcweir * (a copy is included in the LICENSE file that accompanied this code). 20*cdf0e10cSrcweir * 21*cdf0e10cSrcweir * You should have received a copy of the GNU Lesser General Public License 22*cdf0e10cSrcweir * version 3 along with OpenOffice.org. If not, see 23*cdf0e10cSrcweir * <http://www.openoffice.org/license.html> 24*cdf0e10cSrcweir * for a copy of the LGPLv3 License. 25*cdf0e10cSrcweir * 26*cdf0e10cSrcweir ************************************************************************/ 27*cdf0e10cSrcweir 28*cdf0e10cSrcweir // MARKER(update_precomp.py): autogen include statement, do not remove 29*cdf0e10cSrcweir #include "precompiled_ucbhelper.hxx" 30*cdf0e10cSrcweir 31*cdf0e10cSrcweir /************************************************************************** 32*cdf0e10cSrcweir TODO 33*cdf0e10cSrcweir ************************************************************************** 34*cdf0e10cSrcweir 35*cdf0e10cSrcweir *************************************************************************/ 36*cdf0e10cSrcweir #include <osl/mutex.hxx> 37*cdf0e10cSrcweir #include <cppuhelper/typeprovider.hxx> 38*cdf0e10cSrcweir #include <ucbhelper/interactionrequest.hxx> 39*cdf0e10cSrcweir 40*cdf0e10cSrcweir using namespace com::sun::star; 41*cdf0e10cSrcweir using namespace ucbhelper; 42*cdf0e10cSrcweir 43*cdf0e10cSrcweir //========================================================================= 44*cdf0e10cSrcweir //========================================================================= 45*cdf0e10cSrcweir // 46*cdf0e10cSrcweir // InteractionRequest Implementation. 47*cdf0e10cSrcweir // 48*cdf0e10cSrcweir //========================================================================= 49*cdf0e10cSrcweir //========================================================================= 50*cdf0e10cSrcweir 51*cdf0e10cSrcweir namespace ucbhelper 52*cdf0e10cSrcweir { 53*cdf0e10cSrcweir 54*cdf0e10cSrcweir struct InteractionRequest_Impl 55*cdf0e10cSrcweir { 56*cdf0e10cSrcweir rtl::Reference< InteractionContinuation > m_xSelection; 57*cdf0e10cSrcweir com::sun::star::uno::Any m_aRequest; 58*cdf0e10cSrcweir com::sun::star::uno::Sequence< 59*cdf0e10cSrcweir com::sun::star::uno::Reference< 60*cdf0e10cSrcweir com::sun::star::task::XInteractionContinuation > > m_aContinuations; 61*cdf0e10cSrcweir 62*cdf0e10cSrcweir InteractionRequest_Impl() {} 63*cdf0e10cSrcweir InteractionRequest_Impl( const uno::Any & rRequest ) 64*cdf0e10cSrcweir : m_aRequest( rRequest ) {} 65*cdf0e10cSrcweir }; 66*cdf0e10cSrcweir 67*cdf0e10cSrcweir } 68*cdf0e10cSrcweir 69*cdf0e10cSrcweir //========================================================================= 70*cdf0e10cSrcweir InteractionRequest::InteractionRequest() 71*cdf0e10cSrcweir : m_pImpl( new InteractionRequest_Impl ) 72*cdf0e10cSrcweir { 73*cdf0e10cSrcweir } 74*cdf0e10cSrcweir 75*cdf0e10cSrcweir //========================================================================= 76*cdf0e10cSrcweir InteractionRequest::InteractionRequest( const uno::Any & rRequest ) 77*cdf0e10cSrcweir : m_pImpl( new InteractionRequest_Impl( rRequest ) ) 78*cdf0e10cSrcweir { 79*cdf0e10cSrcweir } 80*cdf0e10cSrcweir 81*cdf0e10cSrcweir //========================================================================= 82*cdf0e10cSrcweir // virtual 83*cdf0e10cSrcweir InteractionRequest::~InteractionRequest() 84*cdf0e10cSrcweir { 85*cdf0e10cSrcweir delete m_pImpl; 86*cdf0e10cSrcweir } 87*cdf0e10cSrcweir 88*cdf0e10cSrcweir //========================================================================= 89*cdf0e10cSrcweir void InteractionRequest::setRequest( const uno::Any & rRequest ) 90*cdf0e10cSrcweir { 91*cdf0e10cSrcweir m_pImpl->m_aRequest = rRequest; 92*cdf0e10cSrcweir } 93*cdf0e10cSrcweir 94*cdf0e10cSrcweir //========================================================================= 95*cdf0e10cSrcweir void InteractionRequest::setContinuations( 96*cdf0e10cSrcweir const uno::Sequence< uno::Reference< 97*cdf0e10cSrcweir task::XInteractionContinuation > > & rContinuations ) 98*cdf0e10cSrcweir { 99*cdf0e10cSrcweir m_pImpl->m_aContinuations = rContinuations; 100*cdf0e10cSrcweir } 101*cdf0e10cSrcweir 102*cdf0e10cSrcweir //========================================================================= 103*cdf0e10cSrcweir rtl::Reference< InteractionContinuation > 104*cdf0e10cSrcweir InteractionRequest::getSelection() const 105*cdf0e10cSrcweir { 106*cdf0e10cSrcweir return m_pImpl->m_xSelection; 107*cdf0e10cSrcweir } 108*cdf0e10cSrcweir 109*cdf0e10cSrcweir //========================================================================= 110*cdf0e10cSrcweir void InteractionRequest::setSelection( 111*cdf0e10cSrcweir const rtl::Reference< InteractionContinuation > & rxSelection ) 112*cdf0e10cSrcweir { 113*cdf0e10cSrcweir m_pImpl->m_xSelection = rxSelection; 114*cdf0e10cSrcweir } 115*cdf0e10cSrcweir 116*cdf0e10cSrcweir //========================================================================= 117*cdf0e10cSrcweir // 118*cdf0e10cSrcweir // XInterface methods. 119*cdf0e10cSrcweir // 120*cdf0e10cSrcweir //========================================================================= 121*cdf0e10cSrcweir 122*cdf0e10cSrcweir // virtual 123*cdf0e10cSrcweir void SAL_CALL InteractionRequest::acquire() 124*cdf0e10cSrcweir throw() 125*cdf0e10cSrcweir { 126*cdf0e10cSrcweir OWeakObject::acquire(); 127*cdf0e10cSrcweir } 128*cdf0e10cSrcweir 129*cdf0e10cSrcweir //========================================================================= 130*cdf0e10cSrcweir // virtual 131*cdf0e10cSrcweir void SAL_CALL InteractionRequest::release() 132*cdf0e10cSrcweir throw() 133*cdf0e10cSrcweir { 134*cdf0e10cSrcweir OWeakObject::release(); 135*cdf0e10cSrcweir } 136*cdf0e10cSrcweir 137*cdf0e10cSrcweir //========================================================================= 138*cdf0e10cSrcweir // virtual 139*cdf0e10cSrcweir uno::Any SAL_CALL 140*cdf0e10cSrcweir InteractionRequest::queryInterface( const uno::Type & rType ) 141*cdf0e10cSrcweir throw ( uno::RuntimeException ) 142*cdf0e10cSrcweir { 143*cdf0e10cSrcweir uno::Any aRet = cppu::queryInterface( rType, 144*cdf0e10cSrcweir static_cast< lang::XTypeProvider * >( this ), 145*cdf0e10cSrcweir static_cast< task::XInteractionRequest * >( this ) ); 146*cdf0e10cSrcweir 147*cdf0e10cSrcweir return aRet.hasValue() ? aRet : OWeakObject::queryInterface( rType ); 148*cdf0e10cSrcweir } 149*cdf0e10cSrcweir 150*cdf0e10cSrcweir //========================================================================= 151*cdf0e10cSrcweir // 152*cdf0e10cSrcweir // XTypeProvider methods. 153*cdf0e10cSrcweir // 154*cdf0e10cSrcweir //========================================================================= 155*cdf0e10cSrcweir 156*cdf0e10cSrcweir // virtual 157*cdf0e10cSrcweir uno::Sequence< sal_Int8 > SAL_CALL InteractionRequest::getImplementationId() 158*cdf0e10cSrcweir throw( uno::RuntimeException ) 159*cdf0e10cSrcweir { 160*cdf0e10cSrcweir static cppu::OImplementationId* pId = NULL; 161*cdf0e10cSrcweir if ( !pId ) 162*cdf0e10cSrcweir { 163*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 164*cdf0e10cSrcweir if ( !pId ) 165*cdf0e10cSrcweir { 166*cdf0e10cSrcweir static cppu::OImplementationId id( sal_False ); 167*cdf0e10cSrcweir pId = &id; 168*cdf0e10cSrcweir } 169*cdf0e10cSrcweir } 170*cdf0e10cSrcweir return (*pId).getImplementationId(); 171*cdf0e10cSrcweir } 172*cdf0e10cSrcweir 173*cdf0e10cSrcweir //========================================================================= 174*cdf0e10cSrcweir // virtual 175*cdf0e10cSrcweir uno::Sequence< uno::Type > SAL_CALL InteractionRequest::getTypes() 176*cdf0e10cSrcweir throw( uno::RuntimeException ) 177*cdf0e10cSrcweir { 178*cdf0e10cSrcweir static cppu::OTypeCollection* pCollection = 0; 179*cdf0e10cSrcweir if ( !pCollection ) 180*cdf0e10cSrcweir { 181*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 182*cdf0e10cSrcweir if ( !pCollection ) 183*cdf0e10cSrcweir { 184*cdf0e10cSrcweir static cppu::OTypeCollection collection( 185*cdf0e10cSrcweir getCppuType( static_cast< 186*cdf0e10cSrcweir uno::Reference< lang::XTypeProvider > * >( 0 ) ), 187*cdf0e10cSrcweir getCppuType( static_cast< 188*cdf0e10cSrcweir uno::Reference< task::XInteractionRequest > * >( 0 ) ) ); 189*cdf0e10cSrcweir pCollection = &collection; 190*cdf0e10cSrcweir } 191*cdf0e10cSrcweir } 192*cdf0e10cSrcweir return (*pCollection).getTypes(); 193*cdf0e10cSrcweir } 194*cdf0e10cSrcweir 195*cdf0e10cSrcweir //========================================================================= 196*cdf0e10cSrcweir // 197*cdf0e10cSrcweir // XInteractionRequest methods. 198*cdf0e10cSrcweir // 199*cdf0e10cSrcweir //========================================================================= 200*cdf0e10cSrcweir 201*cdf0e10cSrcweir // virtual 202*cdf0e10cSrcweir uno::Any SAL_CALL InteractionRequest::getRequest() 203*cdf0e10cSrcweir throw( uno::RuntimeException ) 204*cdf0e10cSrcweir { 205*cdf0e10cSrcweir return m_pImpl->m_aRequest; 206*cdf0e10cSrcweir } 207*cdf0e10cSrcweir 208*cdf0e10cSrcweir //========================================================================= 209*cdf0e10cSrcweir // virtual 210*cdf0e10cSrcweir uno::Sequence< uno::Reference< task::XInteractionContinuation > > SAL_CALL 211*cdf0e10cSrcweir InteractionRequest::getContinuations() 212*cdf0e10cSrcweir throw( uno::RuntimeException ) 213*cdf0e10cSrcweir { 214*cdf0e10cSrcweir return m_pImpl->m_aContinuations; 215*cdf0e10cSrcweir } 216*cdf0e10cSrcweir 217*cdf0e10cSrcweir //========================================================================= 218*cdf0e10cSrcweir //========================================================================= 219*cdf0e10cSrcweir // 220*cdf0e10cSrcweir // InteractionContinuation Implementation. 221*cdf0e10cSrcweir // 222*cdf0e10cSrcweir //========================================================================= 223*cdf0e10cSrcweir //========================================================================= 224*cdf0e10cSrcweir 225*cdf0e10cSrcweir namespace ucbhelper 226*cdf0e10cSrcweir { 227*cdf0e10cSrcweir 228*cdf0e10cSrcweir struct InteractionContinuation_Impl 229*cdf0e10cSrcweir { 230*cdf0e10cSrcweir InteractionRequest * m_pRequest; 231*cdf0e10cSrcweir 232*cdf0e10cSrcweir InteractionContinuation_Impl( InteractionRequest * pRequest ) 233*cdf0e10cSrcweir : m_pRequest( pRequest ) {} 234*cdf0e10cSrcweir }; 235*cdf0e10cSrcweir 236*cdf0e10cSrcweir } 237*cdf0e10cSrcweir 238*cdf0e10cSrcweir //========================================================================= 239*cdf0e10cSrcweir InteractionContinuation::InteractionContinuation( 240*cdf0e10cSrcweir InteractionRequest * pRequest ) 241*cdf0e10cSrcweir : m_pImpl( new InteractionContinuation_Impl( pRequest ) ) 242*cdf0e10cSrcweir { 243*cdf0e10cSrcweir } 244*cdf0e10cSrcweir 245*cdf0e10cSrcweir //========================================================================= 246*cdf0e10cSrcweir // virtual 247*cdf0e10cSrcweir InteractionContinuation::~InteractionContinuation() 248*cdf0e10cSrcweir { 249*cdf0e10cSrcweir delete m_pImpl; 250*cdf0e10cSrcweir } 251*cdf0e10cSrcweir 252*cdf0e10cSrcweir //========================================================================= 253*cdf0e10cSrcweir void InteractionContinuation::recordSelection() 254*cdf0e10cSrcweir { 255*cdf0e10cSrcweir m_pImpl->m_pRequest->setSelection( this ); 256*cdf0e10cSrcweir } 257*cdf0e10cSrcweir 258*cdf0e10cSrcweir //========================================================================= 259*cdf0e10cSrcweir //========================================================================= 260*cdf0e10cSrcweir // 261*cdf0e10cSrcweir // InteractionAbort Implementation. 262*cdf0e10cSrcweir // 263*cdf0e10cSrcweir //========================================================================= 264*cdf0e10cSrcweir //========================================================================= 265*cdf0e10cSrcweir 266*cdf0e10cSrcweir //========================================================================= 267*cdf0e10cSrcweir // 268*cdf0e10cSrcweir // XInterface methods. 269*cdf0e10cSrcweir // 270*cdf0e10cSrcweir //========================================================================= 271*cdf0e10cSrcweir 272*cdf0e10cSrcweir // virtual 273*cdf0e10cSrcweir void SAL_CALL InteractionAbort::acquire() 274*cdf0e10cSrcweir throw() 275*cdf0e10cSrcweir { 276*cdf0e10cSrcweir OWeakObject::acquire(); 277*cdf0e10cSrcweir } 278*cdf0e10cSrcweir 279*cdf0e10cSrcweir //========================================================================= 280*cdf0e10cSrcweir // virtual 281*cdf0e10cSrcweir void SAL_CALL InteractionAbort::release() 282*cdf0e10cSrcweir throw() 283*cdf0e10cSrcweir { 284*cdf0e10cSrcweir OWeakObject::release(); 285*cdf0e10cSrcweir } 286*cdf0e10cSrcweir 287*cdf0e10cSrcweir //========================================================================= 288*cdf0e10cSrcweir // virtual 289*cdf0e10cSrcweir uno::Any SAL_CALL 290*cdf0e10cSrcweir InteractionAbort::queryInterface( const uno::Type & rType ) 291*cdf0e10cSrcweir throw ( uno::RuntimeException ) 292*cdf0e10cSrcweir { 293*cdf0e10cSrcweir uno::Any aRet = cppu::queryInterface( rType, 294*cdf0e10cSrcweir static_cast< lang::XTypeProvider * >( this ), 295*cdf0e10cSrcweir static_cast< task::XInteractionContinuation * >( this ), 296*cdf0e10cSrcweir static_cast< task::XInteractionAbort * >( this ) ); 297*cdf0e10cSrcweir 298*cdf0e10cSrcweir return aRet.hasValue() 299*cdf0e10cSrcweir ? aRet : InteractionContinuation::queryInterface( rType ); 300*cdf0e10cSrcweir } 301*cdf0e10cSrcweir 302*cdf0e10cSrcweir //========================================================================= 303*cdf0e10cSrcweir // 304*cdf0e10cSrcweir // XTypeProvider methods. 305*cdf0e10cSrcweir // 306*cdf0e10cSrcweir //========================================================================= 307*cdf0e10cSrcweir 308*cdf0e10cSrcweir // virtual 309*cdf0e10cSrcweir uno::Sequence< sal_Int8 > SAL_CALL InteractionAbort::getImplementationId() 310*cdf0e10cSrcweir throw( uno::RuntimeException ) 311*cdf0e10cSrcweir { 312*cdf0e10cSrcweir static cppu::OImplementationId* pId = NULL; 313*cdf0e10cSrcweir if ( !pId ) 314*cdf0e10cSrcweir { 315*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 316*cdf0e10cSrcweir if ( !pId ) 317*cdf0e10cSrcweir { 318*cdf0e10cSrcweir static cppu::OImplementationId id( sal_False ); 319*cdf0e10cSrcweir pId = &id; 320*cdf0e10cSrcweir } 321*cdf0e10cSrcweir } 322*cdf0e10cSrcweir return (*pId).getImplementationId(); 323*cdf0e10cSrcweir } 324*cdf0e10cSrcweir 325*cdf0e10cSrcweir //========================================================================= 326*cdf0e10cSrcweir // virtual 327*cdf0e10cSrcweir uno::Sequence< uno::Type > SAL_CALL InteractionAbort::getTypes() 328*cdf0e10cSrcweir throw( uno::RuntimeException ) 329*cdf0e10cSrcweir { 330*cdf0e10cSrcweir static cppu::OTypeCollection* pCollection = 0; 331*cdf0e10cSrcweir if ( !pCollection ) 332*cdf0e10cSrcweir { 333*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 334*cdf0e10cSrcweir if ( !pCollection ) 335*cdf0e10cSrcweir { 336*cdf0e10cSrcweir static cppu::OTypeCollection collection( 337*cdf0e10cSrcweir getCppuType( static_cast< 338*cdf0e10cSrcweir uno::Reference< lang::XTypeProvider > * >( 0 ) ), 339*cdf0e10cSrcweir getCppuType( static_cast< 340*cdf0e10cSrcweir uno::Reference< task::XInteractionAbort > * >( 0 ) ) ); 341*cdf0e10cSrcweir pCollection = &collection; 342*cdf0e10cSrcweir } 343*cdf0e10cSrcweir } 344*cdf0e10cSrcweir return (*pCollection).getTypes(); 345*cdf0e10cSrcweir } 346*cdf0e10cSrcweir 347*cdf0e10cSrcweir //========================================================================= 348*cdf0e10cSrcweir // 349*cdf0e10cSrcweir // XInteractionContinuation methods. 350*cdf0e10cSrcweir // 351*cdf0e10cSrcweir //========================================================================= 352*cdf0e10cSrcweir 353*cdf0e10cSrcweir // virtual 354*cdf0e10cSrcweir void SAL_CALL InteractionAbort::select() 355*cdf0e10cSrcweir throw( uno::RuntimeException ) 356*cdf0e10cSrcweir { 357*cdf0e10cSrcweir recordSelection(); 358*cdf0e10cSrcweir } 359*cdf0e10cSrcweir 360*cdf0e10cSrcweir //========================================================================= 361*cdf0e10cSrcweir //========================================================================= 362*cdf0e10cSrcweir // 363*cdf0e10cSrcweir // InteractionRetry Implementation. 364*cdf0e10cSrcweir // 365*cdf0e10cSrcweir //========================================================================= 366*cdf0e10cSrcweir //========================================================================= 367*cdf0e10cSrcweir 368*cdf0e10cSrcweir //========================================================================= 369*cdf0e10cSrcweir // 370*cdf0e10cSrcweir // XInterface methods. 371*cdf0e10cSrcweir // 372*cdf0e10cSrcweir //========================================================================= 373*cdf0e10cSrcweir 374*cdf0e10cSrcweir // virtual 375*cdf0e10cSrcweir void SAL_CALL InteractionRetry::acquire() 376*cdf0e10cSrcweir throw() 377*cdf0e10cSrcweir { 378*cdf0e10cSrcweir OWeakObject::acquire(); 379*cdf0e10cSrcweir } 380*cdf0e10cSrcweir 381*cdf0e10cSrcweir //========================================================================= 382*cdf0e10cSrcweir // virtual 383*cdf0e10cSrcweir void SAL_CALL InteractionRetry::release() 384*cdf0e10cSrcweir throw() 385*cdf0e10cSrcweir { 386*cdf0e10cSrcweir OWeakObject::release(); 387*cdf0e10cSrcweir } 388*cdf0e10cSrcweir 389*cdf0e10cSrcweir //========================================================================= 390*cdf0e10cSrcweir // virtual 391*cdf0e10cSrcweir uno::Any SAL_CALL 392*cdf0e10cSrcweir InteractionRetry::queryInterface( const uno::Type & rType ) 393*cdf0e10cSrcweir throw ( uno::RuntimeException ) 394*cdf0e10cSrcweir { 395*cdf0e10cSrcweir uno::Any aRet = cppu::queryInterface( rType, 396*cdf0e10cSrcweir static_cast< lang::XTypeProvider * >( this ), 397*cdf0e10cSrcweir static_cast< task::XInteractionContinuation * >( this ), 398*cdf0e10cSrcweir static_cast< task::XInteractionRetry * >( this ) ); 399*cdf0e10cSrcweir 400*cdf0e10cSrcweir return aRet.hasValue() 401*cdf0e10cSrcweir ? aRet : InteractionContinuation::queryInterface( rType ); 402*cdf0e10cSrcweir } 403*cdf0e10cSrcweir 404*cdf0e10cSrcweir //========================================================================= 405*cdf0e10cSrcweir // 406*cdf0e10cSrcweir // XTypeProvider methods. 407*cdf0e10cSrcweir // 408*cdf0e10cSrcweir //========================================================================= 409*cdf0e10cSrcweir 410*cdf0e10cSrcweir // virtual 411*cdf0e10cSrcweir uno::Sequence< sal_Int8 > SAL_CALL InteractionRetry::getImplementationId() 412*cdf0e10cSrcweir throw( uno::RuntimeException ) 413*cdf0e10cSrcweir { 414*cdf0e10cSrcweir static cppu::OImplementationId* pId = NULL; 415*cdf0e10cSrcweir if ( !pId ) 416*cdf0e10cSrcweir { 417*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 418*cdf0e10cSrcweir if ( !pId ) 419*cdf0e10cSrcweir { 420*cdf0e10cSrcweir static cppu::OImplementationId id( sal_False ); 421*cdf0e10cSrcweir pId = &id; 422*cdf0e10cSrcweir } 423*cdf0e10cSrcweir } 424*cdf0e10cSrcweir return (*pId).getImplementationId(); 425*cdf0e10cSrcweir } 426*cdf0e10cSrcweir 427*cdf0e10cSrcweir //========================================================================= 428*cdf0e10cSrcweir // virtual 429*cdf0e10cSrcweir uno::Sequence< uno::Type > SAL_CALL InteractionRetry::getTypes() 430*cdf0e10cSrcweir throw( uno::RuntimeException ) 431*cdf0e10cSrcweir { 432*cdf0e10cSrcweir static cppu::OTypeCollection* pCollection = 0; 433*cdf0e10cSrcweir if ( !pCollection ) 434*cdf0e10cSrcweir { 435*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 436*cdf0e10cSrcweir if ( !pCollection ) 437*cdf0e10cSrcweir { 438*cdf0e10cSrcweir static cppu::OTypeCollection collection( 439*cdf0e10cSrcweir getCppuType( static_cast< 440*cdf0e10cSrcweir uno::Reference< lang::XTypeProvider > * >( 0 ) ), 441*cdf0e10cSrcweir getCppuType( static_cast< 442*cdf0e10cSrcweir uno::Reference< task::XInteractionRetry > * >( 0 ) ) ); 443*cdf0e10cSrcweir pCollection = &collection; 444*cdf0e10cSrcweir } 445*cdf0e10cSrcweir } 446*cdf0e10cSrcweir return (*pCollection).getTypes(); 447*cdf0e10cSrcweir } 448*cdf0e10cSrcweir 449*cdf0e10cSrcweir //========================================================================= 450*cdf0e10cSrcweir // 451*cdf0e10cSrcweir // XInteractionContinuation methods. 452*cdf0e10cSrcweir // 453*cdf0e10cSrcweir //========================================================================= 454*cdf0e10cSrcweir 455*cdf0e10cSrcweir // virtual 456*cdf0e10cSrcweir void SAL_CALL InteractionRetry::select() 457*cdf0e10cSrcweir throw( uno::RuntimeException ) 458*cdf0e10cSrcweir { 459*cdf0e10cSrcweir recordSelection(); 460*cdf0e10cSrcweir } 461*cdf0e10cSrcweir 462*cdf0e10cSrcweir //========================================================================= 463*cdf0e10cSrcweir //========================================================================= 464*cdf0e10cSrcweir // 465*cdf0e10cSrcweir // InteractionApprove Implementation. 466*cdf0e10cSrcweir // 467*cdf0e10cSrcweir //========================================================================= 468*cdf0e10cSrcweir //========================================================================= 469*cdf0e10cSrcweir 470*cdf0e10cSrcweir //========================================================================= 471*cdf0e10cSrcweir // 472*cdf0e10cSrcweir // XInterface methods. 473*cdf0e10cSrcweir // 474*cdf0e10cSrcweir //========================================================================= 475*cdf0e10cSrcweir 476*cdf0e10cSrcweir // virtual 477*cdf0e10cSrcweir void SAL_CALL InteractionApprove::acquire() 478*cdf0e10cSrcweir throw() 479*cdf0e10cSrcweir { 480*cdf0e10cSrcweir OWeakObject::acquire(); 481*cdf0e10cSrcweir } 482*cdf0e10cSrcweir 483*cdf0e10cSrcweir //========================================================================= 484*cdf0e10cSrcweir // virtual 485*cdf0e10cSrcweir void SAL_CALL InteractionApprove::release() 486*cdf0e10cSrcweir throw() 487*cdf0e10cSrcweir { 488*cdf0e10cSrcweir OWeakObject::release(); 489*cdf0e10cSrcweir } 490*cdf0e10cSrcweir 491*cdf0e10cSrcweir //========================================================================= 492*cdf0e10cSrcweir // virtual 493*cdf0e10cSrcweir uno::Any SAL_CALL 494*cdf0e10cSrcweir InteractionApprove::queryInterface( const uno::Type & rType ) 495*cdf0e10cSrcweir throw ( uno::RuntimeException ) 496*cdf0e10cSrcweir { 497*cdf0e10cSrcweir uno::Any aRet = cppu::queryInterface( rType, 498*cdf0e10cSrcweir static_cast< lang::XTypeProvider * >( this ), 499*cdf0e10cSrcweir static_cast< task::XInteractionContinuation * >( this ), 500*cdf0e10cSrcweir static_cast< task::XInteractionApprove * >( this ) ); 501*cdf0e10cSrcweir 502*cdf0e10cSrcweir return aRet.hasValue() 503*cdf0e10cSrcweir ? aRet : InteractionContinuation::queryInterface( rType ); 504*cdf0e10cSrcweir } 505*cdf0e10cSrcweir 506*cdf0e10cSrcweir //========================================================================= 507*cdf0e10cSrcweir // 508*cdf0e10cSrcweir // XTypeProvider methods. 509*cdf0e10cSrcweir // 510*cdf0e10cSrcweir //========================================================================= 511*cdf0e10cSrcweir 512*cdf0e10cSrcweir // virtual 513*cdf0e10cSrcweir uno::Sequence< sal_Int8 > SAL_CALL InteractionApprove::getImplementationId() 514*cdf0e10cSrcweir throw( uno::RuntimeException ) 515*cdf0e10cSrcweir { 516*cdf0e10cSrcweir static cppu::OImplementationId* pId = NULL; 517*cdf0e10cSrcweir if ( !pId ) 518*cdf0e10cSrcweir { 519*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 520*cdf0e10cSrcweir if ( !pId ) 521*cdf0e10cSrcweir { 522*cdf0e10cSrcweir static cppu::OImplementationId id( sal_False ); 523*cdf0e10cSrcweir pId = &id; 524*cdf0e10cSrcweir } 525*cdf0e10cSrcweir } 526*cdf0e10cSrcweir return (*pId).getImplementationId(); 527*cdf0e10cSrcweir } 528*cdf0e10cSrcweir 529*cdf0e10cSrcweir //========================================================================= 530*cdf0e10cSrcweir // virtual 531*cdf0e10cSrcweir uno::Sequence< uno::Type > SAL_CALL InteractionApprove::getTypes() 532*cdf0e10cSrcweir throw( uno::RuntimeException ) 533*cdf0e10cSrcweir { 534*cdf0e10cSrcweir static cppu::OTypeCollection* pCollection = 0; 535*cdf0e10cSrcweir if ( !pCollection ) 536*cdf0e10cSrcweir { 537*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 538*cdf0e10cSrcweir if ( !pCollection ) 539*cdf0e10cSrcweir { 540*cdf0e10cSrcweir static cppu::OTypeCollection collection( 541*cdf0e10cSrcweir getCppuType( static_cast< 542*cdf0e10cSrcweir uno::Reference< lang::XTypeProvider > * >( 0 ) ), 543*cdf0e10cSrcweir getCppuType( static_cast< 544*cdf0e10cSrcweir uno::Reference< task::XInteractionApprove > * >( 0 ) ) ); 545*cdf0e10cSrcweir pCollection = &collection; 546*cdf0e10cSrcweir } 547*cdf0e10cSrcweir } 548*cdf0e10cSrcweir return (*pCollection).getTypes(); 549*cdf0e10cSrcweir } 550*cdf0e10cSrcweir 551*cdf0e10cSrcweir //========================================================================= 552*cdf0e10cSrcweir // 553*cdf0e10cSrcweir // XInteractionContinuation methods. 554*cdf0e10cSrcweir // 555*cdf0e10cSrcweir //========================================================================= 556*cdf0e10cSrcweir 557*cdf0e10cSrcweir // virtual 558*cdf0e10cSrcweir void SAL_CALL InteractionApprove::select() 559*cdf0e10cSrcweir throw( uno::RuntimeException ) 560*cdf0e10cSrcweir { 561*cdf0e10cSrcweir recordSelection(); 562*cdf0e10cSrcweir } 563*cdf0e10cSrcweir 564*cdf0e10cSrcweir //========================================================================= 565*cdf0e10cSrcweir //========================================================================= 566*cdf0e10cSrcweir // 567*cdf0e10cSrcweir // InteractionDisapprove Implementation. 568*cdf0e10cSrcweir // 569*cdf0e10cSrcweir //========================================================================= 570*cdf0e10cSrcweir //========================================================================= 571*cdf0e10cSrcweir 572*cdf0e10cSrcweir //========================================================================= 573*cdf0e10cSrcweir // 574*cdf0e10cSrcweir // XInterface methods. 575*cdf0e10cSrcweir // 576*cdf0e10cSrcweir //========================================================================= 577*cdf0e10cSrcweir 578*cdf0e10cSrcweir // virtual 579*cdf0e10cSrcweir void SAL_CALL InteractionDisapprove::acquire() 580*cdf0e10cSrcweir throw() 581*cdf0e10cSrcweir { 582*cdf0e10cSrcweir OWeakObject::acquire(); 583*cdf0e10cSrcweir } 584*cdf0e10cSrcweir 585*cdf0e10cSrcweir //========================================================================= 586*cdf0e10cSrcweir // virtual 587*cdf0e10cSrcweir void SAL_CALL InteractionDisapprove::release() 588*cdf0e10cSrcweir throw() 589*cdf0e10cSrcweir { 590*cdf0e10cSrcweir OWeakObject::release(); 591*cdf0e10cSrcweir } 592*cdf0e10cSrcweir 593*cdf0e10cSrcweir //========================================================================= 594*cdf0e10cSrcweir // virtual 595*cdf0e10cSrcweir uno::Any SAL_CALL 596*cdf0e10cSrcweir InteractionDisapprove::queryInterface( const uno::Type & rType ) 597*cdf0e10cSrcweir throw ( uno::RuntimeException ) 598*cdf0e10cSrcweir { 599*cdf0e10cSrcweir uno::Any aRet = cppu::queryInterface( rType, 600*cdf0e10cSrcweir static_cast< lang::XTypeProvider * >( this ), 601*cdf0e10cSrcweir static_cast< task::XInteractionContinuation * >( this ), 602*cdf0e10cSrcweir static_cast< task::XInteractionDisapprove * >( this ) ); 603*cdf0e10cSrcweir 604*cdf0e10cSrcweir return aRet.hasValue() 605*cdf0e10cSrcweir ? aRet : InteractionContinuation::queryInterface( rType ); 606*cdf0e10cSrcweir } 607*cdf0e10cSrcweir 608*cdf0e10cSrcweir //========================================================================= 609*cdf0e10cSrcweir // 610*cdf0e10cSrcweir // XTypeProvider methods. 611*cdf0e10cSrcweir // 612*cdf0e10cSrcweir //========================================================================= 613*cdf0e10cSrcweir 614*cdf0e10cSrcweir // virtual 615*cdf0e10cSrcweir uno::Sequence< sal_Int8 > SAL_CALL InteractionDisapprove::getImplementationId() 616*cdf0e10cSrcweir throw( uno::RuntimeException ) 617*cdf0e10cSrcweir { 618*cdf0e10cSrcweir static cppu::OImplementationId* pId = NULL; 619*cdf0e10cSrcweir if ( !pId ) 620*cdf0e10cSrcweir { 621*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 622*cdf0e10cSrcweir if ( !pId ) 623*cdf0e10cSrcweir { 624*cdf0e10cSrcweir static cppu::OImplementationId id( sal_False ); 625*cdf0e10cSrcweir pId = &id; 626*cdf0e10cSrcweir } 627*cdf0e10cSrcweir } 628*cdf0e10cSrcweir return (*pId).getImplementationId(); 629*cdf0e10cSrcweir } 630*cdf0e10cSrcweir 631*cdf0e10cSrcweir //========================================================================= 632*cdf0e10cSrcweir // virtual 633*cdf0e10cSrcweir uno::Sequence< uno::Type > SAL_CALL InteractionDisapprove::getTypes() 634*cdf0e10cSrcweir throw( uno::RuntimeException ) 635*cdf0e10cSrcweir { 636*cdf0e10cSrcweir static cppu::OTypeCollection* pCollection = 0; 637*cdf0e10cSrcweir if ( !pCollection ) 638*cdf0e10cSrcweir { 639*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 640*cdf0e10cSrcweir if ( !pCollection ) 641*cdf0e10cSrcweir { 642*cdf0e10cSrcweir static cppu::OTypeCollection collection( 643*cdf0e10cSrcweir getCppuType( static_cast< 644*cdf0e10cSrcweir uno::Reference< lang::XTypeProvider > * >( 0 ) ), 645*cdf0e10cSrcweir getCppuType( static_cast< 646*cdf0e10cSrcweir uno::Reference< task::XInteractionDisapprove > * >( 0 ) ) ); 647*cdf0e10cSrcweir pCollection = &collection; 648*cdf0e10cSrcweir } 649*cdf0e10cSrcweir } 650*cdf0e10cSrcweir return (*pCollection).getTypes(); 651*cdf0e10cSrcweir } 652*cdf0e10cSrcweir 653*cdf0e10cSrcweir //========================================================================= 654*cdf0e10cSrcweir // 655*cdf0e10cSrcweir // XInteractionContinuation methods. 656*cdf0e10cSrcweir // 657*cdf0e10cSrcweir //========================================================================= 658*cdf0e10cSrcweir 659*cdf0e10cSrcweir // virtual 660*cdf0e10cSrcweir void SAL_CALL InteractionDisapprove::select() 661*cdf0e10cSrcweir throw( uno::RuntimeException ) 662*cdf0e10cSrcweir { 663*cdf0e10cSrcweir recordSelection(); 664*cdf0e10cSrcweir } 665*cdf0e10cSrcweir 666*cdf0e10cSrcweir //========================================================================= 667*cdf0e10cSrcweir //========================================================================= 668*cdf0e10cSrcweir // 669*cdf0e10cSrcweir // InteractionSupplyAuthentication Implementation. 670*cdf0e10cSrcweir // 671*cdf0e10cSrcweir //========================================================================= 672*cdf0e10cSrcweir //========================================================================= 673*cdf0e10cSrcweir 674*cdf0e10cSrcweir //========================================================================= 675*cdf0e10cSrcweir // 676*cdf0e10cSrcweir // XInterface methods. 677*cdf0e10cSrcweir // 678*cdf0e10cSrcweir //========================================================================= 679*cdf0e10cSrcweir 680*cdf0e10cSrcweir // virtual 681*cdf0e10cSrcweir void SAL_CALL InteractionSupplyAuthentication::acquire() 682*cdf0e10cSrcweir throw() 683*cdf0e10cSrcweir { 684*cdf0e10cSrcweir OWeakObject::acquire(); 685*cdf0e10cSrcweir } 686*cdf0e10cSrcweir 687*cdf0e10cSrcweir //========================================================================= 688*cdf0e10cSrcweir // virtual 689*cdf0e10cSrcweir void SAL_CALL InteractionSupplyAuthentication::release() 690*cdf0e10cSrcweir throw() 691*cdf0e10cSrcweir { 692*cdf0e10cSrcweir OWeakObject::release(); 693*cdf0e10cSrcweir } 694*cdf0e10cSrcweir 695*cdf0e10cSrcweir //========================================================================= 696*cdf0e10cSrcweir // virtual 697*cdf0e10cSrcweir uno::Any SAL_CALL 698*cdf0e10cSrcweir InteractionSupplyAuthentication::queryInterface( const uno::Type & rType ) 699*cdf0e10cSrcweir throw ( uno::RuntimeException ) 700*cdf0e10cSrcweir { 701*cdf0e10cSrcweir uno::Any aRet = cppu::queryInterface( rType, 702*cdf0e10cSrcweir static_cast< lang::XTypeProvider * >( this ), 703*cdf0e10cSrcweir static_cast< task::XInteractionContinuation * >( this ), 704*cdf0e10cSrcweir static_cast< ucb::XInteractionSupplyAuthentication * >( this ), 705*cdf0e10cSrcweir static_cast< ucb::XInteractionSupplyAuthentication2 * >( this )); 706*cdf0e10cSrcweir 707*cdf0e10cSrcweir return aRet.hasValue() 708*cdf0e10cSrcweir ? aRet : InteractionContinuation::queryInterface( rType ); 709*cdf0e10cSrcweir } 710*cdf0e10cSrcweir 711*cdf0e10cSrcweir //========================================================================= 712*cdf0e10cSrcweir // 713*cdf0e10cSrcweir // XTypeProvider methods. 714*cdf0e10cSrcweir // 715*cdf0e10cSrcweir //========================================================================= 716*cdf0e10cSrcweir 717*cdf0e10cSrcweir // virtual 718*cdf0e10cSrcweir uno::Sequence< sal_Int8 > SAL_CALL 719*cdf0e10cSrcweir InteractionSupplyAuthentication::getImplementationId() 720*cdf0e10cSrcweir throw( uno::RuntimeException ) 721*cdf0e10cSrcweir { 722*cdf0e10cSrcweir static cppu::OImplementationId* pId = NULL; 723*cdf0e10cSrcweir if ( !pId ) 724*cdf0e10cSrcweir { 725*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 726*cdf0e10cSrcweir if ( !pId ) 727*cdf0e10cSrcweir { 728*cdf0e10cSrcweir static cppu::OImplementationId id( sal_False ); 729*cdf0e10cSrcweir pId = &id; 730*cdf0e10cSrcweir } 731*cdf0e10cSrcweir } 732*cdf0e10cSrcweir return (*pId).getImplementationId(); 733*cdf0e10cSrcweir } 734*cdf0e10cSrcweir 735*cdf0e10cSrcweir //========================================================================= 736*cdf0e10cSrcweir // virtual 737*cdf0e10cSrcweir uno::Sequence< uno::Type > SAL_CALL InteractionSupplyAuthentication::getTypes() 738*cdf0e10cSrcweir throw( uno::RuntimeException ) 739*cdf0e10cSrcweir { 740*cdf0e10cSrcweir static cppu::OTypeCollection* pCollection = 0; 741*cdf0e10cSrcweir if ( !pCollection ) 742*cdf0e10cSrcweir { 743*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 744*cdf0e10cSrcweir if ( !pCollection ) 745*cdf0e10cSrcweir { 746*cdf0e10cSrcweir static cppu::OTypeCollection collection( 747*cdf0e10cSrcweir getCppuType( static_cast< 748*cdf0e10cSrcweir uno::Reference< lang::XTypeProvider > * >( 0 ) ), 749*cdf0e10cSrcweir getCppuType( static_cast< 750*cdf0e10cSrcweir uno::Reference< 751*cdf0e10cSrcweir ucb::XInteractionSupplyAuthentication2 > * >( 0 ) ) ); 752*cdf0e10cSrcweir pCollection = &collection; 753*cdf0e10cSrcweir } 754*cdf0e10cSrcweir } 755*cdf0e10cSrcweir return (*pCollection).getTypes(); 756*cdf0e10cSrcweir } 757*cdf0e10cSrcweir 758*cdf0e10cSrcweir //========================================================================= 759*cdf0e10cSrcweir // 760*cdf0e10cSrcweir // XInteractionContinuation methods. 761*cdf0e10cSrcweir // 762*cdf0e10cSrcweir //========================================================================= 763*cdf0e10cSrcweir 764*cdf0e10cSrcweir // virtual 765*cdf0e10cSrcweir void SAL_CALL InteractionSupplyAuthentication::select() 766*cdf0e10cSrcweir throw( uno::RuntimeException ) 767*cdf0e10cSrcweir { 768*cdf0e10cSrcweir recordSelection(); 769*cdf0e10cSrcweir } 770*cdf0e10cSrcweir 771*cdf0e10cSrcweir //========================================================================= 772*cdf0e10cSrcweir // 773*cdf0e10cSrcweir // XInteractionSupplyAuthentication methods. 774*cdf0e10cSrcweir // 775*cdf0e10cSrcweir //========================================================================= 776*cdf0e10cSrcweir 777*cdf0e10cSrcweir // virtual 778*cdf0e10cSrcweir sal_Bool SAL_CALL 779*cdf0e10cSrcweir InteractionSupplyAuthentication::canSetRealm() 780*cdf0e10cSrcweir throw( uno::RuntimeException ) 781*cdf0e10cSrcweir { 782*cdf0e10cSrcweir return m_bCanSetRealm; 783*cdf0e10cSrcweir } 784*cdf0e10cSrcweir 785*cdf0e10cSrcweir //========================================================================= 786*cdf0e10cSrcweir // virtual 787*cdf0e10cSrcweir void SAL_CALL 788*cdf0e10cSrcweir InteractionSupplyAuthentication::setRealm( const rtl::OUString& Realm ) 789*cdf0e10cSrcweir throw( uno::RuntimeException ) 790*cdf0e10cSrcweir { 791*cdf0e10cSrcweir OSL_ENSURE( m_bCanSetPassword, 792*cdf0e10cSrcweir "InteractionSupplyAuthentication::setRealm - Not supported!" ); 793*cdf0e10cSrcweir 794*cdf0e10cSrcweir if ( m_bCanSetRealm ) 795*cdf0e10cSrcweir m_aRealm = Realm; 796*cdf0e10cSrcweir } 797*cdf0e10cSrcweir 798*cdf0e10cSrcweir //========================================================================= 799*cdf0e10cSrcweir // virtual 800*cdf0e10cSrcweir sal_Bool SAL_CALL 801*cdf0e10cSrcweir InteractionSupplyAuthentication::canSetUserName() 802*cdf0e10cSrcweir throw( uno::RuntimeException ) 803*cdf0e10cSrcweir { 804*cdf0e10cSrcweir return m_bCanSetUserName; 805*cdf0e10cSrcweir } 806*cdf0e10cSrcweir 807*cdf0e10cSrcweir //========================================================================= 808*cdf0e10cSrcweir // virtual 809*cdf0e10cSrcweir void SAL_CALL 810*cdf0e10cSrcweir InteractionSupplyAuthentication::setUserName( const rtl::OUString& UserName ) 811*cdf0e10cSrcweir throw( uno::RuntimeException ) 812*cdf0e10cSrcweir { 813*cdf0e10cSrcweir OSL_ENSURE( m_bCanSetUserName, 814*cdf0e10cSrcweir "InteractionSupplyAuthentication::setUserName - Not supported!" ); 815*cdf0e10cSrcweir 816*cdf0e10cSrcweir if ( m_bCanSetUserName ) 817*cdf0e10cSrcweir m_aUserName = UserName; 818*cdf0e10cSrcweir } 819*cdf0e10cSrcweir 820*cdf0e10cSrcweir //========================================================================= 821*cdf0e10cSrcweir // virtual 822*cdf0e10cSrcweir sal_Bool SAL_CALL 823*cdf0e10cSrcweir InteractionSupplyAuthentication::canSetPassword() 824*cdf0e10cSrcweir throw( uno::RuntimeException ) 825*cdf0e10cSrcweir { 826*cdf0e10cSrcweir return m_bCanSetPassword; 827*cdf0e10cSrcweir } 828*cdf0e10cSrcweir 829*cdf0e10cSrcweir //========================================================================= 830*cdf0e10cSrcweir // virtual 831*cdf0e10cSrcweir void SAL_CALL 832*cdf0e10cSrcweir InteractionSupplyAuthentication::setPassword( const rtl::OUString& Password ) 833*cdf0e10cSrcweir throw( uno::RuntimeException ) 834*cdf0e10cSrcweir { 835*cdf0e10cSrcweir OSL_ENSURE( m_bCanSetPassword, 836*cdf0e10cSrcweir "InteractionSupplyAuthentication::setPassword - Not supported!" ); 837*cdf0e10cSrcweir 838*cdf0e10cSrcweir if ( m_bCanSetPassword ) 839*cdf0e10cSrcweir m_aPassword = Password; 840*cdf0e10cSrcweir } 841*cdf0e10cSrcweir 842*cdf0e10cSrcweir //========================================================================= 843*cdf0e10cSrcweir // virtual 844*cdf0e10cSrcweir uno::Sequence< ucb::RememberAuthentication > SAL_CALL 845*cdf0e10cSrcweir InteractionSupplyAuthentication::getRememberPasswordModes( 846*cdf0e10cSrcweir ucb::RememberAuthentication& Default ) 847*cdf0e10cSrcweir throw( uno::RuntimeException ) 848*cdf0e10cSrcweir { 849*cdf0e10cSrcweir Default = m_eDefaultRememberPasswordMode; 850*cdf0e10cSrcweir return m_aRememberPasswordModes; 851*cdf0e10cSrcweir } 852*cdf0e10cSrcweir 853*cdf0e10cSrcweir //========================================================================= 854*cdf0e10cSrcweir // virtual 855*cdf0e10cSrcweir void SAL_CALL 856*cdf0e10cSrcweir InteractionSupplyAuthentication::setRememberPassword( 857*cdf0e10cSrcweir ucb::RememberAuthentication Remember ) 858*cdf0e10cSrcweir throw( uno::RuntimeException ) 859*cdf0e10cSrcweir { 860*cdf0e10cSrcweir m_eRememberPasswordMode = Remember; 861*cdf0e10cSrcweir } 862*cdf0e10cSrcweir 863*cdf0e10cSrcweir //========================================================================= 864*cdf0e10cSrcweir // virtual 865*cdf0e10cSrcweir sal_Bool SAL_CALL 866*cdf0e10cSrcweir InteractionSupplyAuthentication::canSetAccount() 867*cdf0e10cSrcweir throw( uno::RuntimeException ) 868*cdf0e10cSrcweir { 869*cdf0e10cSrcweir return m_bCanSetAccount; 870*cdf0e10cSrcweir } 871*cdf0e10cSrcweir 872*cdf0e10cSrcweir //========================================================================= 873*cdf0e10cSrcweir // virtual 874*cdf0e10cSrcweir void SAL_CALL 875*cdf0e10cSrcweir InteractionSupplyAuthentication::setAccount( const rtl::OUString& Account ) 876*cdf0e10cSrcweir throw( uno::RuntimeException ) 877*cdf0e10cSrcweir { 878*cdf0e10cSrcweir OSL_ENSURE( m_bCanSetAccount, 879*cdf0e10cSrcweir "InteractionSupplyAuthentication::setAccount - Not supported!" ); 880*cdf0e10cSrcweir 881*cdf0e10cSrcweir if ( m_bCanSetAccount ) 882*cdf0e10cSrcweir m_aAccount = Account; 883*cdf0e10cSrcweir } 884*cdf0e10cSrcweir 885*cdf0e10cSrcweir //========================================================================= 886*cdf0e10cSrcweir // virtual 887*cdf0e10cSrcweir uno::Sequence< ucb::RememberAuthentication > SAL_CALL 888*cdf0e10cSrcweir InteractionSupplyAuthentication::getRememberAccountModes( 889*cdf0e10cSrcweir ucb::RememberAuthentication& Default ) 890*cdf0e10cSrcweir throw( uno::RuntimeException ) 891*cdf0e10cSrcweir { 892*cdf0e10cSrcweir Default = m_eDefaultRememberAccountMode; 893*cdf0e10cSrcweir return m_aRememberAccountModes; 894*cdf0e10cSrcweir } 895*cdf0e10cSrcweir 896*cdf0e10cSrcweir //========================================================================= 897*cdf0e10cSrcweir // virtual 898*cdf0e10cSrcweir void SAL_CALL InteractionSupplyAuthentication::setRememberAccount( 899*cdf0e10cSrcweir ucb::RememberAuthentication Remember ) 900*cdf0e10cSrcweir throw( uno::RuntimeException ) 901*cdf0e10cSrcweir { 902*cdf0e10cSrcweir m_eRememberAccountMode = Remember; 903*cdf0e10cSrcweir } 904*cdf0e10cSrcweir 905*cdf0e10cSrcweir //========================================================================= 906*cdf0e10cSrcweir // 907*cdf0e10cSrcweir // XInteractionSupplyAuthentication2 methods. 908*cdf0e10cSrcweir // 909*cdf0e10cSrcweir //========================================================================= 910*cdf0e10cSrcweir 911*cdf0e10cSrcweir // virtual 912*cdf0e10cSrcweir ::sal_Bool SAL_CALL 913*cdf0e10cSrcweir InteractionSupplyAuthentication::canUseSystemCredentials( 914*cdf0e10cSrcweir ::sal_Bool& Default ) 915*cdf0e10cSrcweir throw ( uno::RuntimeException ) 916*cdf0e10cSrcweir { 917*cdf0e10cSrcweir Default = m_bDefaultUseSystemCredentials; 918*cdf0e10cSrcweir return m_bCanUseSystemCredentials; 919*cdf0e10cSrcweir } 920*cdf0e10cSrcweir 921*cdf0e10cSrcweir //========================================================================= 922*cdf0e10cSrcweir // virtual 923*cdf0e10cSrcweir void SAL_CALL InteractionSupplyAuthentication::setUseSystemCredentials( 924*cdf0e10cSrcweir ::sal_Bool UseSystemCredentials ) 925*cdf0e10cSrcweir throw ( uno::RuntimeException ) 926*cdf0e10cSrcweir { 927*cdf0e10cSrcweir if ( m_bCanUseSystemCredentials ) 928*cdf0e10cSrcweir m_bUseSystemCredentials = UseSystemCredentials; 929*cdf0e10cSrcweir } 930*cdf0e10cSrcweir 931*cdf0e10cSrcweir 932*cdf0e10cSrcweir //========================================================================= 933*cdf0e10cSrcweir //========================================================================= 934*cdf0e10cSrcweir // 935*cdf0e10cSrcweir // InteractionSupplyName Implementation. 936*cdf0e10cSrcweir // 937*cdf0e10cSrcweir //========================================================================= 938*cdf0e10cSrcweir //========================================================================= 939*cdf0e10cSrcweir 940*cdf0e10cSrcweir //========================================================================= 941*cdf0e10cSrcweir // 942*cdf0e10cSrcweir // XInterface methods. 943*cdf0e10cSrcweir // 944*cdf0e10cSrcweir //========================================================================= 945*cdf0e10cSrcweir 946*cdf0e10cSrcweir // virtual 947*cdf0e10cSrcweir void SAL_CALL InteractionSupplyName::acquire() 948*cdf0e10cSrcweir throw() 949*cdf0e10cSrcweir { 950*cdf0e10cSrcweir OWeakObject::acquire(); 951*cdf0e10cSrcweir } 952*cdf0e10cSrcweir 953*cdf0e10cSrcweir //========================================================================= 954*cdf0e10cSrcweir // virtual 955*cdf0e10cSrcweir void SAL_CALL InteractionSupplyName::release() 956*cdf0e10cSrcweir throw() 957*cdf0e10cSrcweir { 958*cdf0e10cSrcweir OWeakObject::release(); 959*cdf0e10cSrcweir } 960*cdf0e10cSrcweir 961*cdf0e10cSrcweir //========================================================================= 962*cdf0e10cSrcweir // virtual 963*cdf0e10cSrcweir uno::Any SAL_CALL 964*cdf0e10cSrcweir InteractionSupplyName::queryInterface( const uno::Type & rType ) 965*cdf0e10cSrcweir throw ( uno::RuntimeException ) 966*cdf0e10cSrcweir { 967*cdf0e10cSrcweir uno::Any aRet = cppu::queryInterface( rType, 968*cdf0e10cSrcweir static_cast< lang::XTypeProvider * >( this ), 969*cdf0e10cSrcweir static_cast< task::XInteractionContinuation * >( this ), 970*cdf0e10cSrcweir static_cast< ucb::XInteractionSupplyName * >( this ) ); 971*cdf0e10cSrcweir 972*cdf0e10cSrcweir return aRet.hasValue() 973*cdf0e10cSrcweir ? aRet : InteractionContinuation::queryInterface( rType ); 974*cdf0e10cSrcweir } 975*cdf0e10cSrcweir 976*cdf0e10cSrcweir //========================================================================= 977*cdf0e10cSrcweir // 978*cdf0e10cSrcweir // XTypeProvider methods. 979*cdf0e10cSrcweir // 980*cdf0e10cSrcweir //========================================================================= 981*cdf0e10cSrcweir 982*cdf0e10cSrcweir // virtual 983*cdf0e10cSrcweir uno::Sequence< sal_Int8 > SAL_CALL InteractionSupplyName::getImplementationId() 984*cdf0e10cSrcweir throw( uno::RuntimeException ) 985*cdf0e10cSrcweir { 986*cdf0e10cSrcweir static cppu::OImplementationId* pId = NULL; 987*cdf0e10cSrcweir if ( !pId ) 988*cdf0e10cSrcweir { 989*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 990*cdf0e10cSrcweir if ( !pId ) 991*cdf0e10cSrcweir { 992*cdf0e10cSrcweir static cppu::OImplementationId id( sal_False ); 993*cdf0e10cSrcweir pId = &id; 994*cdf0e10cSrcweir } 995*cdf0e10cSrcweir } 996*cdf0e10cSrcweir return (*pId).getImplementationId(); 997*cdf0e10cSrcweir } 998*cdf0e10cSrcweir 999*cdf0e10cSrcweir //========================================================================= 1000*cdf0e10cSrcweir // virtual 1001*cdf0e10cSrcweir uno::Sequence< uno::Type > SAL_CALL InteractionSupplyName::getTypes() 1002*cdf0e10cSrcweir throw( uno::RuntimeException ) 1003*cdf0e10cSrcweir { 1004*cdf0e10cSrcweir static cppu::OTypeCollection* pCollection = 0; 1005*cdf0e10cSrcweir if ( !pCollection ) 1006*cdf0e10cSrcweir { 1007*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 1008*cdf0e10cSrcweir if ( !pCollection ) 1009*cdf0e10cSrcweir { 1010*cdf0e10cSrcweir static cppu::OTypeCollection collection( 1011*cdf0e10cSrcweir getCppuType( static_cast< 1012*cdf0e10cSrcweir uno::Reference< lang::XTypeProvider > * >( 0 ) ), 1013*cdf0e10cSrcweir getCppuType( static_cast< 1014*cdf0e10cSrcweir uno::Reference< ucb::XInteractionSupplyName > * >( 0 ) ) ); 1015*cdf0e10cSrcweir pCollection = &collection; 1016*cdf0e10cSrcweir } 1017*cdf0e10cSrcweir } 1018*cdf0e10cSrcweir return (*pCollection).getTypes(); 1019*cdf0e10cSrcweir } 1020*cdf0e10cSrcweir 1021*cdf0e10cSrcweir //========================================================================= 1022*cdf0e10cSrcweir // 1023*cdf0e10cSrcweir // XInteractionContinuation methods. 1024*cdf0e10cSrcweir // 1025*cdf0e10cSrcweir //========================================================================= 1026*cdf0e10cSrcweir 1027*cdf0e10cSrcweir // virtual 1028*cdf0e10cSrcweir void SAL_CALL InteractionSupplyName::select() 1029*cdf0e10cSrcweir throw( uno::RuntimeException ) 1030*cdf0e10cSrcweir { 1031*cdf0e10cSrcweir recordSelection(); 1032*cdf0e10cSrcweir } 1033*cdf0e10cSrcweir 1034*cdf0e10cSrcweir //========================================================================= 1035*cdf0e10cSrcweir // 1036*cdf0e10cSrcweir // XInteractionSupplyName methods. 1037*cdf0e10cSrcweir // 1038*cdf0e10cSrcweir //========================================================================= 1039*cdf0e10cSrcweir 1040*cdf0e10cSrcweir // virtual 1041*cdf0e10cSrcweir void SAL_CALL 1042*cdf0e10cSrcweir InteractionSupplyName::setName( const rtl::OUString& Name ) 1043*cdf0e10cSrcweir throw( uno::RuntimeException ) 1044*cdf0e10cSrcweir { 1045*cdf0e10cSrcweir m_aName = Name; 1046*cdf0e10cSrcweir } 1047*cdf0e10cSrcweir 1048*cdf0e10cSrcweir //========================================================================= 1049*cdf0e10cSrcweir //========================================================================= 1050*cdf0e10cSrcweir // 1051*cdf0e10cSrcweir // InteractionReplaceExistingData Implementation. 1052*cdf0e10cSrcweir // 1053*cdf0e10cSrcweir //========================================================================= 1054*cdf0e10cSrcweir //========================================================================= 1055*cdf0e10cSrcweir 1056*cdf0e10cSrcweir //========================================================================= 1057*cdf0e10cSrcweir // 1058*cdf0e10cSrcweir // XInterface methods. 1059*cdf0e10cSrcweir // 1060*cdf0e10cSrcweir //========================================================================= 1061*cdf0e10cSrcweir 1062*cdf0e10cSrcweir // virtual 1063*cdf0e10cSrcweir void SAL_CALL InteractionReplaceExistingData::acquire() 1064*cdf0e10cSrcweir throw() 1065*cdf0e10cSrcweir { 1066*cdf0e10cSrcweir OWeakObject::acquire(); 1067*cdf0e10cSrcweir } 1068*cdf0e10cSrcweir 1069*cdf0e10cSrcweir //========================================================================= 1070*cdf0e10cSrcweir // virtual 1071*cdf0e10cSrcweir void SAL_CALL InteractionReplaceExistingData::release() 1072*cdf0e10cSrcweir throw() 1073*cdf0e10cSrcweir { 1074*cdf0e10cSrcweir OWeakObject::release(); 1075*cdf0e10cSrcweir } 1076*cdf0e10cSrcweir 1077*cdf0e10cSrcweir //========================================================================= 1078*cdf0e10cSrcweir // virtual 1079*cdf0e10cSrcweir uno::Any SAL_CALL 1080*cdf0e10cSrcweir InteractionReplaceExistingData::queryInterface( const uno::Type & rType ) 1081*cdf0e10cSrcweir throw ( uno::RuntimeException ) 1082*cdf0e10cSrcweir { 1083*cdf0e10cSrcweir uno::Any aRet = cppu::queryInterface( rType, 1084*cdf0e10cSrcweir static_cast< lang::XTypeProvider * >( this ), 1085*cdf0e10cSrcweir static_cast< task::XInteractionContinuation * >( this ), 1086*cdf0e10cSrcweir static_cast< ucb::XInteractionReplaceExistingData * >( this ) ); 1087*cdf0e10cSrcweir 1088*cdf0e10cSrcweir return aRet.hasValue() 1089*cdf0e10cSrcweir ? aRet : InteractionContinuation::queryInterface( rType ); 1090*cdf0e10cSrcweir } 1091*cdf0e10cSrcweir 1092*cdf0e10cSrcweir //========================================================================= 1093*cdf0e10cSrcweir // 1094*cdf0e10cSrcweir // XTypeProvider methods. 1095*cdf0e10cSrcweir // 1096*cdf0e10cSrcweir //========================================================================= 1097*cdf0e10cSrcweir 1098*cdf0e10cSrcweir // virtual 1099*cdf0e10cSrcweir uno::Sequence< sal_Int8 > SAL_CALL 1100*cdf0e10cSrcweir InteractionReplaceExistingData::getImplementationId() 1101*cdf0e10cSrcweir throw( uno::RuntimeException ) 1102*cdf0e10cSrcweir { 1103*cdf0e10cSrcweir static cppu::OImplementationId* pId = NULL; 1104*cdf0e10cSrcweir if ( !pId ) 1105*cdf0e10cSrcweir { 1106*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 1107*cdf0e10cSrcweir if ( !pId ) 1108*cdf0e10cSrcweir { 1109*cdf0e10cSrcweir static cppu::OImplementationId id( sal_False ); 1110*cdf0e10cSrcweir pId = &id; 1111*cdf0e10cSrcweir } 1112*cdf0e10cSrcweir } 1113*cdf0e10cSrcweir return (*pId).getImplementationId(); 1114*cdf0e10cSrcweir } 1115*cdf0e10cSrcweir 1116*cdf0e10cSrcweir //========================================================================= 1117*cdf0e10cSrcweir // virtual 1118*cdf0e10cSrcweir uno::Sequence< uno::Type > SAL_CALL InteractionReplaceExistingData::getTypes() 1119*cdf0e10cSrcweir throw( uno::RuntimeException ) 1120*cdf0e10cSrcweir { 1121*cdf0e10cSrcweir static cppu::OTypeCollection* pCollection = 0; 1122*cdf0e10cSrcweir if ( !pCollection ) 1123*cdf0e10cSrcweir { 1124*cdf0e10cSrcweir osl::Guard< osl::Mutex > aGuard( osl::Mutex::getGlobalMutex() ); 1125*cdf0e10cSrcweir if ( !pCollection ) 1126*cdf0e10cSrcweir { 1127*cdf0e10cSrcweir static cppu::OTypeCollection collection( 1128*cdf0e10cSrcweir getCppuType( static_cast< 1129*cdf0e10cSrcweir uno::Reference< lang::XTypeProvider > * >( 0 ) ), 1130*cdf0e10cSrcweir getCppuType( static_cast< 1131*cdf0e10cSrcweir uno::Reference< 1132*cdf0e10cSrcweir ucb::XInteractionReplaceExistingData > * >( 0 ) ) ); 1133*cdf0e10cSrcweir pCollection = &collection; 1134*cdf0e10cSrcweir } 1135*cdf0e10cSrcweir } 1136*cdf0e10cSrcweir return (*pCollection).getTypes(); 1137*cdf0e10cSrcweir } 1138*cdf0e10cSrcweir 1139*cdf0e10cSrcweir //========================================================================= 1140*cdf0e10cSrcweir // 1141*cdf0e10cSrcweir // XInteractionContinuation methods. 1142*cdf0e10cSrcweir // 1143*cdf0e10cSrcweir //========================================================================= 1144*cdf0e10cSrcweir 1145*cdf0e10cSrcweir // virtual 1146*cdf0e10cSrcweir void SAL_CALL InteractionReplaceExistingData::select() 1147*cdf0e10cSrcweir throw( uno::RuntimeException ) 1148*cdf0e10cSrcweir { 1149*cdf0e10cSrcweir recordSelection(); 1150*cdf0e10cSrcweir } 1151*cdf0e10cSrcweir 1152