LibreOffice Module ucbhelper (master) 1
|
This class implements the interface XInteractionRequest. More...
#include <interactionrequest.hxx>
Public Member Functions | |
InteractionRequest (const css::uno::Any &rRequest) | |
Constructor. More... | |
void | setContinuations (const css::uno::Sequence< css::uno::Reference< css::task::XInteractionContinuation > > &rContinuations) |
This method sets the continuations for the request. More... | |
virtual css::uno::Any SAL_CALL | getRequest () override |
virtual css::uno::Sequence< css::uno::Reference< css::task::XInteractionContinuation > > SAL_CALL | getContinuations () override |
rtl::Reference< InteractionContinuation > const & | getSelection () const |
After passing this request to XInteractionHandler::handle, this method returns the continuation that was chosen by the interaction handler. More... | |
void | setSelection (const rtl::Reference< InteractionContinuation > &rxSelection) |
This method sets a continuation for the request. More... | |
Protected Member Functions | |
void | setRequest (const css::uno::Any &rRequest) |
InteractionRequest () | |
virtual | ~InteractionRequest () override |
Private Attributes | |
std::unique_ptr< InteractionRequest_Impl > | m_pImpl |
This class implements the interface XInteractionRequest.
Instances can be passed directly to XInteractionHandler::handle(...). Each interaction request contains an exception describing the error and a number of interaction continuations describing the possible "answers" for the request. After the request was passed to XInteractionHandler::handle(...) the method getSelection() returns the continuation chosen by the interaction handler.
The typical usage of this class would be:
1) Create exception object that shall be handled by the interaction handler. 2) Create InteractionRequest, supply exception as ctor parameter 3) Create continuations needed and add them to a sequence 4) Supply the continuations to the InteractionRequest by calling setContinuations(...)
This class can also be used as base class for more specialized requests, like authentication requests.
Definition at line 65 of file interactionrequest.hxx.
|
protected |
|
overrideprotectedvirtual |
ucbhelper::InteractionRequest::InteractionRequest | ( | const css::uno::Any & | rRequest | ) |
Constructor.
rRequest | is the exception describing the error. |
|
overridevirtual |
|
overridevirtual |
rtl::Reference< InteractionContinuation > const & ucbhelper::InteractionRequest::getSelection | ( | ) | const |
After passing this request to XInteractionHandler::handle, this method returns the continuation that was chosen by the interaction handler.
Referenced by ucbhelper::SimpleInteractionRequest::getResponse().
void ucbhelper::InteractionRequest::setContinuations | ( | const css::uno::Sequence< css::uno::Reference< css::task::XInteractionContinuation > > & | rContinuations | ) |
This method sets the continuations for the request.
rContinuations | contains the possible continuations. |
Referenced by ucbhelper::AuthenticationFallbackRequest::AuthenticationFallbackRequest(), ucbhelper::SimpleAuthenticationRequest::initialize(), ucbhelper::SimpleCertificateValidationRequest::SimpleCertificateValidationRequest(), ucbhelper::SimpleInteractionRequest::SimpleInteractionRequest(), and ucbhelper::SimpleIOErrorRequest::SimpleIOErrorRequest().
|
protected |
void ucbhelper::InteractionRequest::setSelection | ( | const rtl::Reference< InteractionContinuation > & | rxSelection | ) |
This method sets a continuation for the request.
It also can be used to reset the continuation set by a previous XInteractionHandler::handle call in order to use this request object more than once.
rxSelection | is the interaction continuation to activate for the request or an empty reference in order to reset the current selection. |
Referenced by ucbhelper::InteractionContinuation::recordSelection().
|
private |
Definition at line 68 of file interactionrequest.hxx.