def marshal(self):
    '\n      Implements :func:`autobahn.wamp.interfaces.IMessage.marshal`\n      '
    details = {u'roles': {}}
    if self.authid:
        details[u'authid'] = self.authid
    if self.authrole:
        details[u'authrole'] = self.authrole
    if self.authrole:
        details[u'authmethod'] = self.authmethod
    if self.authprovider:
        details[u'authprovider'] = self.authprovider
    for role in self.roles:
        details[u'roles'][role.ROLE] = {}
        for feature in role.__dict__:
            if ((not feature.startswith('_')) and (feature != 'ROLE') and (getattr(role, feature) is not None)):
                if (not (u'features' in details[u'roles'][role.ROLE])):
                    details[u'roles'][role.ROLE] = {u'features': {}}
                details[u'roles'][role.ROLE][u'features'][six.u(feature)] = getattr(role, feature)
    return [Welcome.MESSAGE_TYPE, self.session, details]
Implements :func:`autobahn.wamp.interfaces.IMessage.marshal`
def marshal(self):
    '\n      \n      '
    details = {u'roles': {}}
    if self.authid:
        details[u'authid'] = self.authid
    if self.authrole:
        details[u'authrole'] = self.authrole
    if self.authrole:
        details[u'authmethod'] = self.authmethod
    if self.authprovider:
        details[u'authprovider'] = self.authprovider
    for role in self.roles:
        details[u'roles'][role.ROLE] = {}
        for feature in role.__dict__:
            if ((not feature.startswith('_')) and (feature != 'ROLE') and (getattr(role, feature) is not None)):
                if (not (u'features' in details[u'roles'][role.ROLE])):
                    details[u'roles'][role.ROLE] = {u'features': {}}
                details[u'roles'][role.ROLE][u'features'][six.u(feature)] = getattr(role, feature)
    return [Welcome.MESSAGE_TYPE, self.session, details]