Пример #1
0
class CalDAVAccount(object):

    def __init__(self, server, port=None, ssl=False, afunix=None, user="", pswd="", principal=None, root=None, logging=False, noHostRedirect=False):
        self.session = CalDAVSession(server, port, ssl, afunix, user, pswd, principal, root, logging, noHostRedirect=noHostRedirect)
        self.principal = principalCache.getPrincipal(self.session, self.session.principalPath)

    def setUserPswd(self, user, pswd):

        self.session.setUserPswd(user, pswd)
        self.principal = principalCache.getPrincipal(self.session, self.session.principalPath)

    def getPrincipal(self, path=None, refresh=False):
        if path:
            return principalCache.getPrincipal(self.session, path, refresh=refresh)
        elif refresh:
            self.principal = principalCache.getPrincipal(self.session, self.session.principalPath, refresh=refresh)

        return self.principal
Пример #2
0
class CalDAVAccount(object):

    def __init__(self, server, port=None, ssl=False, user="", pswd="", principal=None, root=None, logging=False):
        self.session = CalDAVSession(server, port, ssl, user, pswd, principal, root, logging)
        self.principal = principalCache.getPrincipal(self.session, self.session.principalPath)


    def setUserPswd(self, user, pswd):

        self.session.setUserPswd(user, pswd)
        self.principal = principalCache.getPrincipal(self.session, self.session.principalPath)


    def getPrincipal(self, path=None, refresh=False):
        if path:
            return principalCache.getPrincipal(self.session, path, refresh=refresh)
        elif refresh:
            self.principal = principalCache.getPrincipal(self.session, self.session.principalPath, refresh=refresh)

        return self.principal
Пример #3
0
 def __init__(self, server, port=None, ssl=False, afunix=None, user="", pswd="", principal=None, root=None, logging=False, noHostRedirect=False):
     self.session = CalDAVSession(server, port, ssl, afunix, user, pswd, principal, root, logging, noHostRedirect=noHostRedirect)
     self.principal = principalCache.getPrincipal(self.session, self.session.principalPath)
Пример #4
0
 def __init__(self, server, port=None, ssl=False, user="", pswd="", principal=None, root=None, logging=False):
     self.session = CalDAVSession(server, port, ssl, user, pswd, principal, root, logging)
     self.principal = principalCache.getPrincipal(self.session, self.session.principalPath)