Logo Search packages:      
Sourcecode: zope-loginmanager version File versions

def LoginManager::UserSources::BasicUserSource::manage_mappings (   self,
  mapping = [],
  REQUEST = None 
) [inherited]

manage role mappings

Definition at line 289 of file UserSources.py.

00289                                                        :
        """manage role mappings"""
        self._role_mappings = rm = {}
        for m in mapping:
            if m.mfrom and m.mto:
                if rm.has_key(m.mfrom):
                    rm[m.mfrom].append(m.mto)
                else:
                    rm[m.mfrom] = [m.mto]

        # XXX probably a better way to do this...
        if not filter(lambda x: x['id'] == 'cache_expire', self._properties):
            self._properties = (
                {'id':'cache_expire', 'type': 'int', 'mode': 'w'},
            ) + self._properties

        self.cacheClear()

        if REQUEST: return self.manage_main(
            self,REQUEST,update_menu=1,
            manage_tabs_message="Role mappings changed.")

    def _zclassOK(self, z):


Generated by  Doxygen 1.6.0   Back to index