def __init__(self, siteInfo, userInfo): self.siteInfo = siteInfo self.userInfo = userInfo self.queries = AuditQuery() self.factory = AuditEventFactory()
def __init__(self, page): """Create an edit auditor. DESCRIPTION The constructor for an auditor is passed all the data that will be the same for the events that are created during one use of the auditor by a Zope 3 page-view. ARGUMENTS "page" A IGSContentFolder representing the page being edited. SIDE EFFECTS The page is set to the page that is passed in, and used as the context for the auditor. The user (who is acting on the page) is set after determining the logged-in user, using the page as the context. The site that all this is occurring on is set, after being determined by a similar mechanism to the user. A page-edit audit event factory is instantiated. """ self.page = page self.userInfo = createObject('groupserver.LoggedInUser', page) self.siteInfo = createObject('groupserver.SiteInfo', page) self.queries = AuditQuery() self.factory = EditPageAuditEventFactory()
def __init__(self, site): self.site = site self.userInfo = createObject('groupserver.LoggedInUser', site) self.siteInfo = createObject('groupserver.SiteInfo', site) self.queries = AuditQuery() self.factory = ChangeAuditEventFactory()
def __init__(self, siteInfo, groupInfo, adminInfo): self.siteInfo = siteInfo self.groupInfo = groupInfo self.adminInfo = adminInfo self.queries = AuditQuery() self.factory = AuditEventFactory()
def __init__(self, context, siteInfo): self.context = context self.siteInfo = siteInfo self.userInfo = createObject('groupserver.UserFromId', context, '') self.queries = AuditQuery() self.factory = LoginAuditEventFactory()
def __init__(self, user): self.user = user self.userInfo = createObject('groupserver.LoggedInUser', user) self.instanceUserInfo = IGSUserInfo(user) self.siteInfo = createObject('groupserver.SiteInfo', user) self.queries = AuditQuery() self.factory = CustomUserAuditEventFactory()
def __init__(self, context, userInfo, groupInfo, siteInfo): """Create a bounce-handling auditor (after the act). """ self.context = context self.userInfo = userInfo self.groupInfo = groupInfo self.siteInfo = siteInfo self.queries = AuditQuery() self.factory = BounceHandlingAuditEventFactory()
def __init__(self, context): """Create a user-creation auditor (after the act). """ self.context = context self.userInfo = createObject('groupserver.LoggedInUser', context) self.siteInfo = createObject('groupserver.SiteInfo', context) self.groupInfo = createObject('groupserver.GroupInfo', context) self.queries = AuditQuery() self.factory = WebPostAuditEventFactory()
def __init__(self, siteInfo, user): if not siteInfo: m = 'No siteInfo' raise ValueError(m) self.siteInfo = siteInfo if not user: m = 'No userInfo' raise ValueError(m) if IGSUserInfo.providedBy(user): self.userInfo = user else: self.userInfo = IGSUserInfo(user) self.queries = AuditQuery() self.factory = AuditEventFactory()
def __init__(self, siteInfo, user): """Create an login auditor. DESCRIPTION The constructor for an auditor is passed all the data that will be the same for the events that are created during one use of the auditor by a Zope 3 page-view. ARGUMENTS "userInfo" "siteInfo" SIDE EFFECTS """ self.user = user self.userInfo = IGSUserInfo(user) self.siteInfo = siteInfo self.queries = AuditQuery() self.factory = LoginAuditEventFactory()
def __init__(self, context, siteInfo): self.context = context self.siteInfo = siteInfo self.queries = AuditQuery() self.factory = AuditEventFactory()
def __init__(self, context): self.context = context self.queries = AuditQuery() self.factory = AuditEventFactory()
def queries(self): retval = AuditQuery() return retval
def queries(self): if self.__queries == None: self.__queries = AuditQuery() return self.__queries