1 /************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 11 * OpenOffice.org is free software: you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License version 3 13 * only, as published by the Free Software Foundation. 14 * 15 * OpenOffice.org is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 * GNU Lesser General Public License version 3 for more details 19 * (a copy is included in the LICENSE file that accompanied this code). 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * version 3 along with OpenOffice.org. If not, see 23 * <http://www.openoffice.org/license.html> 24 * for a copy of the LGPLv3 License. 25 * 26 ************************************************************************/ 27 28 // MARKER(update_precomp.py): autogen include statement, do not remove 29 #include "precompiled_forms.hxx" 30 #include "submission.hxx" 31 32 #include "model.hxx" 33 #include "binding.hxx" 34 #include "mip.hxx" 35 #include "evaluationcontext.hxx" 36 #include "unohelper.hxx" 37 #include "submission/submission_put.hxx" 38 #include "submission/submission_post.hxx" 39 #include "submission/submission_get.hxx" 40 41 #include <rtl/ustring.hxx> 42 #include <rtl/ustrbuf.hxx> 43 44 #include <com/sun/star/uno/Sequence.hxx> 45 #include <com/sun/star/uno/Reference.hxx> 46 #include <com/sun/star/xforms/XModel.hpp> 47 #include <com/sun/star/uno/RuntimeException.hpp> 48 #include <com/sun/star/xml/xpath/XXPathObject.hpp> 49 #include <com/sun/star/container/XNameAccess.hpp> 50 #include <com/sun/star/xml/xpath/XPathObjectType.hpp> 51 #include <com/sun/star/xml/dom/XNodeList.hpp> 52 #include <com/sun/star/xml/dom/XDocument.hpp> 53 #include <com/sun/star/xml/dom/XDocumentBuilder.hpp> 54 #include <com/sun/star/xml/dom/XDocumentFragment.hpp> 55 #include <com/sun/star/xml/dom/NodeType.hpp> 56 #include <com/sun/star/task/XInteractionHandler.hpp> 57 #include <com/sun/star/task/XInteractionRequest.hpp> 58 #include <com/sun/star/task/XInteractionContinuation.hpp> 59 #include <com/sun/star/xforms/InvalidDataOnSubmitException.hpp> 60 #include <com/sun/star/frame/XFrame.hpp> 61 #include <cppuhelper/typeprovider.hxx> 62 #include <comphelper/propertysetinfo.hxx> 63 #include <comphelper/interaction.hxx> 64 #include <unotools/processfactory.hxx> 65 #include <memory> 66 67 68 69 70 using rtl::OUString; 71 using rtl::OUStringBuffer; 72 using com::sun::star::beans::UnknownPropertyException; 73 using com::sun::star::beans::PropertyVetoException; 74 using com::sun::star::lang::IllegalArgumentException; 75 using com::sun::star::util::VetoException; 76 using com::sun::star::form::submission::XSubmissionVetoListener; 77 using com::sun::star::lang::WrappedTargetException; 78 using com::sun::star::lang::NoSupportException; 79 using com::sun::star::task::XInteractionHandler; 80 using com::sun::star::task::XInteractionRequest; 81 using com::sun::star::task::XInteractionContinuation; 82 using com::sun::star::xforms::XModel; 83 using com::sun::star::xforms::InvalidDataOnSubmitException; 84 using com::sun::star::container::XNameAccess; 85 using com::sun::star::xml::xpath::XXPathObject; 86 using com::sun::star::xml::xpath::XPathObjectType; 87 using com::sun::star::frame::XFrame; 88 using xforms::Submission; 89 using xforms::Model; 90 using xforms::MIP; 91 using std::auto_ptr; 92 93 using namespace com::sun::star::uno; 94 using namespace com::sun::star::lang; 95 using namespace com::sun::star::xml::dom; 96 97 Submission::Submission() : 98 msID(), 99 msBind(), 100 maRef(), 101 msAction(), 102 msMethod(), 103 msVersion(), 104 mbIndent(), 105 msMediaType(), 106 msEncoding(), 107 mbOmitXmlDeclaration(), 108 mbStandalone(), 109 msCDataSectionElement(), 110 msReplace( OUSTRING("none") ), 111 msSeparator(), 112 msIncludeNamespacePrefixes(), 113 m_aFactory(utl::getProcessServiceFactory()) 114 { 115 initializePropertySet(); 116 } 117 118 Submission::~Submission() throw() 119 { 120 } 121 122 Reference<XModel> Submission::getModel() const 123 { 124 return mxModel; 125 } 126 127 void Submission::setModel( const Reference<XModel>& xModel ) 128 { 129 mxModel = xModel; 130 } 131 132 OUString Submission::getID() const 133 { 134 return msID; 135 } 136 137 void Submission::setID( const OUString& sID ) 138 { 139 msID = sID; 140 } 141 142 OUString Submission::getBind() const 143 { 144 return msBind; 145 } 146 147 void Submission::setBind( const OUString& sBind ) 148 { 149 msBind = sBind; 150 } 151 152 OUString Submission::getRef() const 153 { 154 return maRef.getExpression(); 155 } 156 157 void Submission::setRef( const OUString& sRef ) 158 { 159 maRef.setExpression( sRef ); 160 } 161 162 OUString Submission::getAction() const 163 { 164 return msAction; 165 } 166 167 void Submission::setAction( const OUString& sAction ) 168 { 169 msAction = sAction; 170 } 171 172 OUString Submission::getMethod() const 173 { 174 return msMethod; 175 } 176 177 void Submission::setMethod( const OUString& sMethod ) 178 { 179 msMethod = sMethod; 180 } 181 182 OUString Submission::getVersion() const 183 { 184 return msVersion; 185 } 186 187 void Submission::setVersion( const OUString& sVersion ) 188 { 189 msVersion = sVersion; 190 } 191 192 bool Submission::getIndent() const 193 { 194 return mbIndent; 195 } 196 197 void Submission::setIndent( bool bIndent ) 198 { 199 mbIndent = bIndent; 200 } 201 202 OUString Submission::getMediaType() const 203 { 204 return msMediaType; 205 } 206 207 void Submission::setMediaType( const OUString& sMediaType ) 208 { 209 msMediaType = sMediaType; 210 } 211 212 OUString Submission::getEncoding() const 213 { 214 return msEncoding; 215 } 216 217 void Submission::setEncoding( const OUString& sEncoding ) 218 { 219 msEncoding = sEncoding; 220 } 221 222 bool Submission::getOmitXmlDeclaration() const 223 { 224 return mbOmitXmlDeclaration; 225 } 226 227 void Submission::setOmitXmlDeclaration( bool bOmitXmlDeclaration ) 228 { 229 mbOmitXmlDeclaration = bOmitXmlDeclaration; 230 } 231 232 bool Submission::getStandalone() const 233 { 234 return mbStandalone; 235 } 236 237 void Submission::setStandalone( bool bStandalone ) 238 { 239 mbStandalone = bStandalone; 240 } 241 242 OUString Submission::getCDataSectionElement() const 243 { 244 return msCDataSectionElement; 245 } 246 247 void Submission::setCDataSectionElement( const OUString& sCDataSectionElement ) 248 { 249 msCDataSectionElement = sCDataSectionElement; 250 } 251 252 OUString Submission::getReplace() const 253 { 254 return msReplace; 255 } 256 257 void Submission::setReplace( const OUString& sReplace ) 258 { 259 msReplace = sReplace; 260 } 261 262 OUString Submission::getSeparator() const 263 { 264 return msSeparator; 265 } 266 267 void Submission::setSeparator( const OUString& sSeparator ) 268 { 269 msSeparator = sSeparator; 270 } 271 272 Sequence< OUString > Submission::getIncludeNamespacePrefixes() const 273 { 274 return msIncludeNamespacePrefixes; 275 } 276 277 void Submission::setIncludeNamespacePrefixes( const Sequence< OUString >& rIncludeNamespacePrefixes ) 278 { 279 msIncludeNamespacePrefixes = rIncludeNamespacePrefixes; 280 } 281 282 bool Submission::doSubmit( const Reference< XInteractionHandler >& xHandler ) 283 { 284 liveCheck(); 285 286 // construct XXPathObject for submission doc; use bind in preference of ref 287 EvaluationContext aEvalContext; 288 ComputedExpression aExpression; 289 if( msBind.getLength() != 0 ) 290 { 291 Binding* pBinding = Binding::getBinding( mxModel->getBinding(msBind) ); 292 if( pBinding != NULL ) 293 { 294 aExpression.setExpression( pBinding->getBindingExpression() ); 295 aEvalContext = pBinding->getEvaluationContext(); 296 } 297 // TODO: else: illegal binding name -> raise error 298 } 299 else if( maRef.getExpression().getLength() != 0 ) 300 { 301 aExpression.setExpression( maRef.getExpression() ); 302 aEvalContext = Model::getModel( mxModel )->getEvaluationContext(); 303 } 304 else 305 { 306 aExpression.setExpression( OUSTRING( "/" ) ); 307 aEvalContext = Model::getModel( mxModel )->getEvaluationContext(); 308 } 309 aExpression.evaluate( aEvalContext ); 310 Reference<XXPathObject> xResult = aExpression.getXPath(); 311 OSL_ENSURE( xResult.is(), "no result?" ); 312 313 // early out if we have not obtained any result 314 if( ! xResult.is() ) 315 return false; 316 317 318 // Reference< XNodeList > aList = xResult->getNodeList(); 319 OUString aMethod = getMethod(); 320 321 // strip whitespace-only text node for get submission 322 Reference< XDocumentFragment > aFragment = createSubmissionDocument( 323 xResult, aMethod.equalsIgnoreAsciiCaseAscii("get")); 324 325 // submit result; set encoding, etc. 326 auto_ptr<CSubmission> xSubmission; 327 if (aMethod.equalsIgnoreAsciiCaseAscii("PUT")) 328 xSubmission = auto_ptr<CSubmission>( 329 new CSubmissionPut( getAction(), aFragment)); 330 else if (aMethod.equalsIgnoreAsciiCaseAscii("post")) 331 xSubmission = auto_ptr<CSubmission>( 332 new CSubmissionPost( getAction(), aFragment)); 333 else if (aMethod.equalsIgnoreAsciiCaseAscii("get")) 334 xSubmission = auto_ptr<CSubmission>( 335 new CSubmissionGet( getAction(), aFragment)); 336 else 337 { 338 OSL_ENSURE(sal_False, "Unsupported xforms submission method"); 339 return false; 340 } 341 342 xSubmission->setEncoding(getEncoding()); 343 CSubmission::SubmissionResult aResult = xSubmission->submit( xHandler ); 344 345 if (aResult == CSubmission::SUCCESS) 346 { 347 Reference< XDocument > aInstanceDoc = getInstanceDocument(xResult); 348 aResult = xSubmission->replace(getReplace(), aInstanceDoc, Reference< XFrame >()); 349 } 350 351 return ( aResult == CSubmission::SUCCESS ); 352 } 353 354 Sequence<sal_Int8> Submission::getUnoTunnelID() 355 { 356 static cppu::OImplementationId aImplementationId; 357 return aImplementationId.getImplementationId(); 358 } 359 360 Submission* Submission::getSubmission( 361 const Reference<XPropertySet>& xPropertySet ) 362 { 363 Reference<XUnoTunnel> xTunnel( xPropertySet, UNO_QUERY ); 364 return xTunnel.is() 365 ? reinterpret_cast<Submission*>( 366 xTunnel->getSomething( getUnoTunnelID() ) ) 367 : NULL; 368 } 369 370 371 372 373 374 375 void Submission::liveCheck() 376 throw( RuntimeException ) 377 { 378 bool bValid = mxModel.is(); 379 380 if( ! bValid ) 381 throw RuntimeException(); 382 } 383 384 Model* Submission::getModelImpl() const 385 { 386 Model* pModel = NULL; 387 if( mxModel.is() ) 388 pModel = Model::getModel( mxModel ); 389 return pModel; 390 } 391 392 393 // 394 // Property-Set implementation 395 // 396 397 #define HANDLE_ID 0 398 #define HANDLE_Bind 1 399 #define HANDLE_Ref 2 400 #define HANDLE_Action 3 401 #define HANDLE_Method 4 402 #define HANDLE_Version 5 403 #define HANDLE_Indent 6 404 #define HANDLE_MediaType 7 405 #define HANDLE_Encoding 8 406 #define HANDLE_OmitXmlDeclaration 9 407 #define HANDLE_Standalone 10 408 #define HANDLE_CDataSectionElement 11 409 #define HANDLE_Replace 12 410 #define HANDLE_Separator 13 411 #define HANDLE_IncludeNamespacePrefixes 14 412 #define HANDLE_Model 15 413 414 #define REGISTER_PROPERTY( property, type ) \ 415 registerProperty( PROPERTY( property, type ), \ 416 new DirectPropertyAccessor< Submission, type >( this, &Submission::set##property, &Submission::get##property ) ); 417 418 #define REGISTER_PROPERTY_BOOL( property ) \ 419 registerProperty( PROPERTY( property, bool ), \ 420 new BooleanPropertyAccessor< Submission, bool >( this, &Submission::set##property, &Submission::get##property ) ); 421 422 void Submission::initializePropertySet() 423 { 424 REGISTER_PROPERTY ( ID, OUString ); 425 REGISTER_PROPERTY ( Bind, OUString ); 426 REGISTER_PROPERTY ( Ref, OUString ); 427 REGISTER_PROPERTY ( Action, OUString ); 428 REGISTER_PROPERTY ( Method, OUString ); 429 REGISTER_PROPERTY ( Version, OUString ); 430 REGISTER_PROPERTY_BOOL( Indent ); 431 REGISTER_PROPERTY ( MediaType, OUString ); 432 REGISTER_PROPERTY ( Encoding, OUString ); 433 REGISTER_PROPERTY_BOOL( OmitXmlDeclaration ); 434 REGISTER_PROPERTY_BOOL( Standalone ); 435 REGISTER_PROPERTY ( CDataSectionElement, OUString ); 436 REGISTER_PROPERTY ( Replace, OUString ); 437 REGISTER_PROPERTY ( Separator, OUString ); 438 REGISTER_PROPERTY ( IncludeNamespacePrefixes, Sequence< OUString > ); 439 REGISTER_PROPERTY ( Model, Reference<XModel> ); 440 441 initializePropertyValueCache( HANDLE_Indent ); 442 initializePropertyValueCache( HANDLE_OmitXmlDeclaration ); 443 initializePropertyValueCache( HANDLE_Standalone ); 444 } 445 446 sal_Bool SAL_CALL Submission::convertFastPropertyValue( 447 Any& rConvertedValue, Any& rOldValue, sal_Int32 nHandle, const Any& rValue ) 448 throw ( IllegalArgumentException ) 449 { 450 if ( nHandle == HANDLE_IncludeNamespacePrefixes ) 451 { 452 // for convinience reasons (????), we accept a string which contains 453 // a comma-separated list of namespace prefixes 454 ::rtl::OUString sTokenList; 455 if ( rValue >>= sTokenList ) 456 { 457 std::vector< OUString > aPrefixes; 458 sal_Int32 p = 0; 459 while ( p >= 0 ) 460 aPrefixes.push_back( sTokenList.getToken( 0, ',', p ) ); 461 462 Sequence< ::rtl::OUString > aConvertedPrefixes( &aPrefixes[0], aPrefixes.size() ); 463 return PropertySetBase::convertFastPropertyValue( rConvertedValue, rOldValue, nHandle, makeAny( aConvertedPrefixes ) ); 464 } 465 } 466 467 return PropertySetBase::convertFastPropertyValue( rConvertedValue, rOldValue, nHandle, rValue ); 468 } 469 470 OUString SAL_CALL Submission::getName() 471 throw( RuntimeException ) 472 { 473 return getID(); 474 } 475 476 void SAL_CALL Submission::setName( const OUString& sID ) 477 throw( RuntimeException ) 478 { 479 setID( sID ); 480 } 481 482 483 484 sal_Int64 SAL_CALL Submission::getSomething( 485 const Sequence<sal_Int8>& aId ) 486 throw( RuntimeException ) 487 { 488 return ( aId == getUnoTunnelID() ) ? reinterpret_cast<sal_Int64>(this) : 0; 489 } 490 491 492 OUString lcl_message( const OUString& rID, const OUString& rText ) 493 { 494 OUStringBuffer aMessage; 495 aMessage.append( OUSTRING("XForms submission '") ); 496 aMessage.append( rID ); 497 aMessage.append( OUSTRING("' failed") ); 498 aMessage.append( rText ); 499 aMessage.append( OUSTRING(".") ); 500 return aMessage.makeStringAndClear(); 501 } 502 503 void SAL_CALL Submission::submitWithInteraction( 504 const Reference<XInteractionHandler>& _rxHandler ) 505 throw ( VetoException, 506 WrappedTargetException, 507 RuntimeException ) 508 { 509 // as long as this class is not really threadsafe, we need to copy 510 // the members we're interested in 511 Reference< XModel > xModel( mxModel ); 512 ::rtl::OUString sID( msID ); 513 514 if ( !xModel.is() || !msID.getLength() ) 515 throw RuntimeException( 516 ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "This is not a valid submission object." ) ), 517 *this 518 ); 519 520 Model* pModel = Model::getModel( xModel ); 521 OSL_ENSURE( pModel != NULL, "illegal model?" ); 522 523 // #i36765# #i47248# warning on submission of illegal data 524 // check for validity (and query user if invalid) 525 bool bValid = pModel->isValid(); 526 if( ! bValid ) 527 { 528 InvalidDataOnSubmitException aInvalidDataException( 529 lcl_message(sID, OUSTRING(" due to invalid data") ), *this ); 530 531 if( _rxHandler.is() ) 532 { 533 // labouriously create interaction request 534 comphelper::OInteractionRequest* pRequest 535 = new comphelper::OInteractionRequest( 536 makeAny( aInvalidDataException ) ); 537 Reference<XInteractionRequest> xRequest = pRequest; 538 539 comphelper::OInteractionApprove* pContinue 540 = new comphelper::OInteractionApprove(); 541 Reference<XInteractionContinuation> xContinue = pContinue; 542 pRequest->addContinuation( xContinue ); 543 544 comphelper::OInteractionDisapprove* pCancel 545 = new comphelper::OInteractionDisapprove(); 546 Reference<XInteractionContinuation> xCancel = pCancel; 547 pRequest->addContinuation( xCancel ); 548 549 // ask the handler... 550 _rxHandler->handle( xRequest ); 551 OSL_ENSURE( pContinue->wasSelected() || pCancel->wasSelected(), 552 "handler didn't select" ); 553 554 // and continue, if user chose 'continue' 555 if( pContinue->wasSelected() ) 556 bValid = true; 557 } 558 559 // abort if invalid (and user didn't tell us to continue) 560 if( ! bValid ) 561 throw aInvalidDataException; 562 } 563 564 // attempt submission 565 bool bResult = false; 566 try 567 { 568 bResult = doSubmit( _rxHandler ); 569 } 570 catch( const VetoException& ) 571 { 572 OSL_ENSURE( sal_False, "Model::submit: Hmm. How can a single submission have a veto right?" ); 573 // allowed to leave 574 throw; 575 } 576 catch( const Exception& e ) 577 { 578 // exception caught: re-throw as wrapped target exception 579 throw WrappedTargetException( 580 lcl_message( sID, OUSTRING(" due to exception being thrown") ), 581 *this, makeAny( e ) ); 582 } 583 584 if( bResult ) 585 { 586 mxModel->rebuild(); 587 } 588 else 589 { 590 // other failure: throw wrapped target exception, too. 591 throw WrappedTargetException( 592 lcl_message( sID, OUString() ), *this, Any() ); 593 } 594 } 595 596 void SAL_CALL Submission::submit( ) throw ( VetoException, WrappedTargetException, RuntimeException ) 597 { 598 submitWithInteraction( NULL ); 599 } 600 601 void SAL_CALL Submission::addSubmissionVetoListener( const Reference< XSubmissionVetoListener >& /*listener*/ ) throw (NoSupportException, RuntimeException) 602 { 603 // TODO 604 throw NoSupportException(); 605 } 606 607 void SAL_CALL Submission::removeSubmissionVetoListener( const Reference< XSubmissionVetoListener >& /*listener*/ ) throw (NoSupportException, RuntimeException) 608 { 609 // TODO 610 throw NoSupportException(); 611 } 612 613 static sal_Bool _isIgnorable(const Reference< XNode >& aNode) 614 { 615 // ignore whitespace-only textnodes 616 if (aNode->getNodeType() == NodeType_TEXT_NODE) 617 { 618 OUString aTrimmedValue = aNode->getNodeValue().trim(); 619 if (aTrimmedValue.getLength() == 0) return sal_True; 620 } 621 622 return sal_False; 623 } 624 625 // recursively copy relevant nodes from A to B 626 static void _cloneNodes(Model& aModel, const Reference< XNode >& dstParent, const Reference< XNode >& source, sal_Bool bRemoveWSNodes) 627 { 628 if (!source.is()) return; 629 630 Reference< XNode > cur = source; 631 Reference< XDocument > dstDoc = dstParent->getOwnerDocument(); 632 Reference< XNode > imported; 633 634 if (cur.is()) 635 { 636 // is this node relevant? 637 MIP mip = aModel.queryMIP(cur); 638 if(mip.isRelevant() && !(bRemoveWSNodes && _isIgnorable(cur))) 639 { 640 imported = dstDoc->importNode(cur, sal_False); 641 imported = dstParent->appendChild(imported); 642 // append source children to new imported parent 643 for( cur = cur->getFirstChild(); cur.is(); cur = cur->getNextSibling() ) 644 _cloneNodes(aModel, imported, cur, bRemoveWSNodes); 645 } 646 } 647 } 648 Reference< XDocument > Submission::getInstanceDocument(const Reference< XXPathObject >& aObj) 649 { 650 using namespace com::sun::star::xml::xpath; 651 // result 652 Reference< XDocument > aDocument; 653 654 if (aObj->getObjectType() == XPathObjectType_XPATH_NODESET) 655 { 656 Reference< XNodeList > aList = aObj->getNodeList(); 657 if (aList->getLength() > 0) 658 aDocument = aList->item(0)->getOwnerDocument(); 659 } 660 return aDocument; 661 } 662 663 Reference< XDocumentFragment > Submission::createSubmissionDocument(const Reference< XXPathObject >& aObj, sal_Bool bRemoveWSNodes) 664 { 665 using namespace com::sun::star::xml::xpath; 666 Reference< XDocumentBuilder > aDocBuilder(m_aFactory->createInstance( 667 OUString::createFromAscii("com.sun.star.xml.dom.DocumentBuilder")), UNO_QUERY); 668 Reference< XDocument > aDocument = aDocBuilder->newDocument(); 669 Reference< XDocumentFragment > aFragment = aDocument->createDocumentFragment(); 670 671 // 672 if (aObj->getObjectType() == XPathObjectType_XPATH_NODESET) 673 { 674 Reference< XNodeList > aList = aObj->getNodeList(); 675 Reference< XNode > aListItem; 676 for (sal_Int32 i=0; i < aList->getLength(); i++) 677 { 678 aListItem = aList->item(i); 679 if (aListItem->getNodeType()==NodeType_DOCUMENT_NODE) 680 aListItem = Reference< XNode >( 681 (Reference< XDocument >(aListItem, UNO_QUERY))->getDocumentElement(), UNO_QUERY); 682 // copy relevant nodes from instance into fragment 683 _cloneNodes(*getModelImpl(), Reference< XNode >(aFragment, UNO_QUERY), aListItem, bRemoveWSNodes); 684 } 685 } 686 return aFragment; 687 } 688 689 // some forwarding: XPropertySet is implemented in our base class, 690 // but also available as base of XSubmission 691 Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL Submission::getPropertySetInfo( ) throw(RuntimeException) 692 { 693 return PropertySetBase::getPropertySetInfo(); 694 } 695 void SAL_CALL Submission::setPropertyValue( const ::rtl::OUString& aPropertyName, const Any& aValue ) throw(UnknownPropertyException, PropertyVetoException, IllegalArgumentException, WrappedTargetException, RuntimeException) 696 { 697 PropertySetBase::setPropertyValue( aPropertyName, aValue ); 698 } 699 Any SAL_CALL Submission::getPropertyValue( const ::rtl::OUString& PropertyName ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) 700 { 701 return PropertySetBase::getPropertyValue( PropertyName ); 702 } 703 void SAL_CALL Submission::addPropertyChangeListener( const ::rtl::OUString& aPropertyName, const Reference< ::com::sun::star::beans::XPropertyChangeListener >& xListener ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) 704 { 705 PropertySetBase::addPropertyChangeListener( aPropertyName, xListener ); 706 } 707 void SAL_CALL Submission::removePropertyChangeListener( const ::rtl::OUString& aPropertyName, const Reference< ::com::sun::star::beans::XPropertyChangeListener >& aListener ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) 708 { 709 PropertySetBase::removePropertyChangeListener( aPropertyName, aListener ); 710 } 711 void SAL_CALL Submission::addVetoableChangeListener( const ::rtl::OUString& PropertyName, const Reference< ::com::sun::star::beans::XVetoableChangeListener >& aListener ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) 712 { 713 PropertySetBase::addVetoableChangeListener( PropertyName, aListener ); 714 } 715 void SAL_CALL Submission::removeVetoableChangeListener( const ::rtl::OUString& PropertyName, const Reference< ::com::sun::star::beans::XVetoableChangeListener >& aListener ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) 716 { 717 PropertySetBase::removeVetoableChangeListener( PropertyName, aListener ); 718 } 719 720