Acknowledgement Class Reference

#include <mw/messagingbus/acknowledgement.h>

Link against: messagingbus.lib

class Acknowledgement : public RequestId, public RequestId

Acknowledgement notification is a general response to sent requests and it contains the enumerations for all known errors. Acknowledgement inherits RequestID and is received from Session::sent().

Inherits from

  • Acknowledgement
    Public Member Enumerations
    enumType { None, NotRegistered, InvalidUserID, InvalidApplicationPath, ..., QueueFull }
    Public Member Functions
    Acknowledgement()
    Acknowledgement(const Acknowledgement &)
    virtual ~Acknowledgement()
    Type errorType()
    boolisError()
    Acknowledgement &operator=(const Acknowledgement &)
    ErrorResponse serverError()
    Protected Member Functions
    voidsetErrorType(Type)
    voidsetServerError(const ErrorResponse &)
    Inherited Functions
    RequestId::RequestId()
    RequestId::RequestId(const RequestId &)
    RequestId::id()const
    RequestId::operator=(const RequestId &)
    RequestId::setId(const QString &)
    RequestId::~RequestId()

    Member Enumeration Documentation

    Enum Type

    MB aknowledgement error types

    None Message was sent successfully. NotRegistered Application has not registered correctly. Registration needed. InvalidUserID Incorrect user id used as a parameter. InvalidApplicationPath Invalid file path given as a wakeup parameter. MissingCredentials JID missing MissingParameters The xml cannot be formed ResponseTimeOut Response for message not received from MB server MessageNotFound The requested message is not found in the queue ServerError Server responded with error. Acknowledgement::serverError() returns the specific error details. NotSupported Unsupported feature tries to be used NotAuthenticated Application is trying to send when authentication is not valid anymore. Needs to reauthenticate. InvalidFormat Parameter in a method call contains characters tha are not allowed. InvalidValue Parameter in a method call contains value that is out of range. QueueFull Queue has reached it's limit. No more messages are accepted until there is more space.

    Constructor & Destructor Documentation

    Acknowledgement ( )

    Acknowledgement()

    Constructor. Creates the AcknowledgementData object.

    Acknowledgement ( const Acknowledgement & )

    Acknowledgement(const Acknowledgement &other)

    Copy Constructor.

    other - Acknowledgement& class type parameter

    ~Acknowledgement ( )

    ~Acknowledgement()[virtual]

    Destructor.

    Member Function Documentation

    errorType ( )

    Type errorType()const

    Returns an Acknowledgement::Type type regarding different situations.

    Return Value
    Acknowledgement::Type

    isError ( )

    boolisError()const

    Returns a bool type.If return value is true message has been sent succesfully, else return value is false meaning an error occured.

    operator= ( const Acknowledgement & )

    Acknowledgement &operator=(const Acknowledgement &other)

    Operator =, protect against self-assignment.

    serverError ( )

    ErrorResponse serverError()const

    Returns an Error object containing error description.

    setErrorType ( Type )

    voidsetErrorType(Typetype)[protected]

    Method used for setting error type using an Acknowledgement::Type type paramater. Error type is added to logtxt.

    type - Acknowledgement::Type object type paramater

    See also: errorType()

    setServerError ( const ErrorResponse & )

    voidsetServerError(const ErrorResponse &error)[protected]

    Method used for setting server error.

    error - ErrorResponse& object type parameter.