@staticmethod
def parse(wmsg):
    '\n      Verifies and parses an unserialized raw message into an actual WAMP message instance.\n\n      :param wmsg: The unserialized raw message.\n      :type wmsg: list\n\n      :returns: An instance of this class.\n      '
    assert ((len(wmsg) > 0) and (wmsg[0] == Invocation.MESSAGE_TYPE))
    if (len(wmsg) not in (4, 5, 6)):
        raise ProtocolError('invalid message length {0} for INVOCATION'.format(len(wmsg)))
    request = check_or_raise_id(wmsg[1], "'request' in INVOCATION")
    registration = check_or_raise_id(wmsg[2], "'registration' in INVOCATION")
    details = check_or_raise_extra(wmsg[3], "'details' in INVOCATION")
    args = None
    if (len(wmsg) > 4):
        args = wmsg[4]
        if (type(args) != list):
            raise ProtocolError("invalid type {0} for 'args' in INVOCATION".format(type(args)))
    kwargs = None
    if (len(wmsg) > 5):
        kwargs = wmsg[5]
        if (type(kwargs) != dict):
            raise ProtocolError("invalid type {0} for 'kwargs' in INVOCATION".format(type(kwargs)))
    timeout = None
    if (u'timeout' in details):
        detail_timeout = details[u'timeout']
        if (type(detail_timeout) not in six.integer_types):
            raise ProtocolError("invalid type {0} for 'timeout' detail in INVOCATION".format(type(detail_timeout)))
        if (detail_timeout < 0):
            raise ProtocolError("invalid value {0} for 'timeout' detail in INVOCATION".format(detail_timeout))
        timeout = detail_timeout
    receive_progress = None
    if (u'receive_progress' in details):
        detail_receive_progress = details[u'receive_progress']
        if (type(detail_receive_progress) != bool):
            raise ProtocolError("invalid type {0} for 'receive_progress' detail in INVOCATION".format(type(detail_receive_progress)))
        receive_progress = detail_receive_progress
    caller = None
    if (u'caller' in details):
        detail_caller = details[u'caller']
        if (type(detail_caller) not in six.integer_types):
            raise ProtocolError("invalid type {0} for 'caller' detail in INVOCATION".format(type(detail_caller)))
        caller = detail_caller
    authid = None
    if (u'authid' in details):
        detail_authid = details[u'authid']
        if (type(detail_authid) != six.text_type):
            raise ProtocolError("invalid type {0} for 'authid' detail in INVOCATION".format(type(detail_authid)))
        authid = detail_authid
    authrole = None
    if (u'authrole' in details):
        detail_authrole = details[u'authrole']
        if (type(detail_authrole) != six.text_type):
            raise ProtocolError("invalid type {0} for 'authrole' detail in INVOCATION".format(type(detail_authrole)))
        authrole = detail_authrole
    authmethod = None
    if (u'authmethod' in details):
        detail_authmethod = details[u'authmethod']
        if (type(detail_authmethod) != six.text_type):
            raise ProtocolError("invalid type {0} for 'authmethod' detail in INVOCATION".format(type(detail_authmethod)))
        authmethod = detail_authmethod
    obj = Invocation(request, registration, args=args, kwargs=kwargs, timeout=timeout, receive_progress=receive_progress, caller=caller, authid=authid, authrole=authrole, authmethod=authmethod)
    return obj
Verifies and parses an unserialized raw message into an actual WAMP message instance.

:param wmsg: The unserialized raw message.
:type wmsg: list

:returns: An instance of this class.
@staticmethod
def parse(wmsg):
    '\n      Verifies and parses an unserialized raw message into an actual WAMP message instance.\n\n      :param wmsg: The unserialized raw message.\n      :type wmsg: list\n\n      :returns: An instance of this class.\n      '
    assert ((len(wmsg) > 0) and (wmsg[0] == Invocation.MESSAGE_TYPE))
    if (len(wmsg) not in (4, 5, 6)):
        raise ProtocolError('invalid message length {0} for INVOCATION'.format(len(wmsg)))
    request = check_or_raise_id(wmsg[1], "'request' in INVOCATION")
    registration = check_or_raise_id(wmsg[2], "'registration' in INVOCATION")
    details = check_or_raise_extra(wmsg[3], "'details' in INVOCATION")
    args = None
    if (len(wmsg) > 4):
        args = wmsg[4]
        if (type(args) != list):
            raise ProtocolError("invalid type {0} for 'args' in INVOCATION".format(type(args)))
    kwargs = None
    if (len(wmsg) > 5):
        kwargs = wmsg[5]
        if (type(kwargs) != dict):
            raise ProtocolError("invalid type {0} for 'kwargs' in INVOCATION".format(type(kwargs)))
    timeout = None
    if (u'timeout' in details):
        detail_timeout = details[u'timeout']
        if (type(detail_timeout) not in six.integer_types):
            raise ProtocolError("invalid type {0} for 'timeout' detail in INVOCATION".format(type(detail_timeout)))
        if (detail_timeout < 0):
            raise ProtocolError("invalid value {0} for 'timeout' detail in INVOCATION".format(detail_timeout))
        timeout = detail_timeout
    receive_progress = None
    if (u'receive_progress' in details):
        detail_receive_progress = details[u'receive_progress']
        if (type(detail_receive_progress) != bool):
            raise ProtocolError("invalid type {0} for 'receive_progress' detail in INVOCATION".format(type(detail_receive_progress)))
        receive_progress = detail_receive_progress
    caller = None
    if (u'caller' in details):
        detail_caller = details[u'caller']
        if (type(detail_caller) not in six.integer_types):
            raise ProtocolError("invalid type {0} for 'caller' detail in INVOCATION".format(type(detail_caller)))
        caller = detail_caller
    authid = None
    if (u'authid' in details):
        detail_authid = details[u'authid']
        if (type(detail_authid) != six.text_type):
            raise ProtocolError("invalid type {0} for 'authid' detail in INVOCATION".format(type(detail_authid)))
        authid = detail_authid
    authrole = None
    if (u'authrole' in details):
        detail_authrole = details[u'authrole']
        if (type(detail_authrole) != six.text_type):
            raise ProtocolError("invalid type {0} for 'authrole' detail in INVOCATION".format(type(detail_authrole)))
        authrole = detail_authrole
    authmethod = None
    if (u'authmethod' in details):
        detail_authmethod = details[u'authmethod']
        if (type(detail_authmethod) != six.text_type):
            raise ProtocolError("invalid type {0} for 'authmethod' detail in INVOCATION".format(type(detail_authmethod)))
        authmethod = detail_authmethod
    obj = Invocation(request, registration, args=args, kwargs=kwargs, timeout=timeout, receive_progress=receive_progress, caller=caller, authid=authid, authrole=authrole, authmethod=authmethod)
    return obj