Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(9)  |  Call(5)  |  Derive(0)  |  Import(4)

src/d/e/dexterity.membrane-0.4/dexterity/membrane/behavior/membraneuser.py   dexterity.membrane(Download)
from Products.membrane.interfaces import IMembraneUserAuth
from Products.membrane.interfaces import IMembraneUserChanger
from Products.membrane.interfaces import IMembraneUserObject
from Products.membrane.interfaces import IMembraneUserProperties
from five import grok
    def verifyCredentials(self, credentials):
        """Returns True is password is authenticated, False if not.
        """
        user = IMembraneUserObject(self.context)
        if credentials.get('login') != user.getUserName():
        if self.verifyCredentials(credentials):
            # return (self.getUserId(), self.getUserName())
            user = IMembraneUserObject(self.context)
            return (user.getUserId(), user.getUserName())
 
    def getRoles(self, user_id):
        membrane = IMembraneUserObject(self.context)
        if membrane.getUserId() != user_id:
            return ()
        if not self._in_right_state():
        if not self._in_right_state():
            return
        membrane = IMembraneUserObject(self.context)
        yield membrane.getUserId(), self.roles
 

src/p/r/Products.FacultyStaffDirectory-3.1.3/Products/FacultyStaffDirectory/membership/person.py   Products.FacultyStaffDirectory(Download)
from zope.annotation.interfaces import IAttributeAnnotatable, IAnnotations
 
from Products.membrane.interfaces import IMembraneUserObject
from Products.membrane.at.interfaces import IUserAuthentication
from Products.membrane.at.interfaces import IUserRoles

src/p/r/Products.FacultyStaffDirectory-3.1.3/Products/FacultyStaffDirectory/events/person.py   Products.FacultyStaffDirectory(Download)
from Acquisition import aq_parent, aq_inner
 
from Products.CMFCore.utils import getToolByName
from Products.membrane.interfaces import IMembraneUserObject
from Products.FacultyStaffDirectory import FSDMessageFactory as _

src/p/r/Products.FacultyStaffDirectory-3.1.3/Products/FacultyStaffDirectory/tests/testPerson.py   Products.FacultyStaffDirectory(Download)
    def testIMembraneUserObject(self):
        """Test the functionality of the IMembraneUserObject interface."""
        from Products.membrane.interfaces import IMembraneUserObject
        # adapt the person object
        u = IMembraneUserObject(self.person)