PaymentReply

Since: BlackBerry 10.0.0

#include <bb/platform/PaymentReply>

To link against this class, add the following line to your .pro file: LIBS += -lbbplatform

Base class for all PaymentManager replies.

This class provides the finished and error information for all PaymentManager replies. Subclasses of this class are returned for all PaymentManager request methods. Initially, the returned object will be unfinished and will not contain any valid information relating to the request (other than that it is unfinished). Once the request is finished, isError() can be used to determine whether the request succeeded or failed. If the request was successful, then the subclass will provide data on the success result. If the request failed, errorCode() will identify the nature of the error and, if applicable, errorInfo() will provide more detail on the particular error that occurred.

The finished() signal can be used to determine when the request finishes. There are also signals on PaymentManager that can be to determine when a request finishes.

Note:

Do not delete the object in a slot connected to the finished() signal. Use QObject::deleteLater() instead.


Overview

Properties Index

interrorCode [read-only]
QStringerrorInfo [read-only]
QStringerrorText [read-only]
boolfinished [read-only]

Public Functions Index

virtual ~PaymentReply ()
interrorCode () const
QStringerrorInfo () const
QStringerrorText () const
boolisError () const
boolisFinished () const

Signals Index

voidfinished ()

Properties

int errorCode[read-only]

Represents the error code.

Since:

BlackBerry 10.2.0

QString errorInfo[read-only]

Get the extra error information.

In the event of a Failed errorCode, this represents extra information to further identify the error that occurred, for diagnostic purposes.

Since:

BlackBerry 10.2.0

QString errorText[read-only]

Represents the error text.

If the request is unfinished or finished successfully, then this method returns an empty string. If the request failed, then this method returns the a description of the error that occurred.

Since:

BlackBerry 10.2.0

bool finished[read-only]

Represents whether the request is finished.

Whether the request is finished.

Since:

BlackBerry 10.2.0

Public Functions

virtual~PaymentReply ()

Destructor.

Destroys a PaymentReply.

Since:

BlackBerry 10.0.0

int errorCode ()

Get the error code.

If the request is unfinished or finished successfully, then this method returns PaymentErrorCode::None. If the request failed, then this method returns the appropriate PaymentErrorCode.

Return:

The error code.

Since:

BlackBerry 10.0.0

QString errorInfo ()

Get the extra error information.

In the event of a Failed errorCode(), this method returns extra information to further identify the error that occurred, for diagnostic purposes.

Return:

The extra error information.

Since:

BlackBerry 10.2.0

QString errorText ()

Get the error text.

If the request is unfinished or finished successfully, then this method returns an empty string. If the request failed, then this method returns the a description of the error that occurred.

Return:

A description of the error that occurred.

Since:

BlackBerry 10.0.0

bool isError ()

Whether the request failed.

If the request is unfinished or finished successfully, then this method returns false. If the request failed, then this method returns true.

Return:

Whether the request failed.

Since:

BlackBerry 10.0.0

bool isFinished ()

Whether the request is finished.

Return:

true if a result has been received, false otherwise.

Since:

BlackBerry 10.0.0

Signals

void finished ()

Emitted when a result is received.

Since:

BlackBerry 10.0.0

Last modified: 2014-09-30



Got questions about leaving a comment? Get answers from our Disqus FAQ.

comments powered by Disqus