Example #1
0
 def __init__(self, id, contributor, message, file, reply_to, approved):
     self.contributor = contributor
     self.message = message
     self.reply_to = reply_to
     self.approved = approved
     self.comment_date = DateTime()
     NyFSFile.__init__(self, id, '', file)
 def __init__(self, id, title, contributor, contributor_name, file, kwargs):
     self.contributor = contributor
     self.contributor_name = contributor_name
     self.review_date = DateTime()
     self.store_kwargs(kwargs)
     NyFSFile.__init__(self, id, title, file)
     self.ratings = {}
     self.votes = 0
Example #3
0
 def __init__(self, id, title, contributor, contributor_name, file, kwargs):
     self.contributor = contributor
     self.contributor_name = contributor_name
     self.review_date = DateTime()
     self.store_kwargs(kwargs)
     NyFSFile.__init__(self, id, title, file)
     self.ratings = {}
     self.votes = 0
Example #4
0
 def __init__(self, id, title, file, precondition):
     """
     Constructor.
     """
     NyFSFile.__init__(self, id, title, file, '', precondition)
     #"dirty" trick to get rid of the File's title property
     try: del self.title
     except: pass
     try: del self.id
     except: pass
     NyContentData.__init__(self)
Example #5
0
 def __init__(self, id, title, file):
     """
     Constructor.
     """
     NyFSFile.__init__(self, id, title, file, '')
     #"dirty" trick to get rid of the File's title property
     try:
         del self.title
     except:
         pass
     try:
         del self.id
     except:
         pass
     NyContentData.__init__(self)
Example #6
0
 def __setstate__(self, state):
     """ Updates """
     NyFSFile.inheritedAttribute("__setstate__")(self, state)
     if 'id' in self.__dict__:
         self.__name__ = self.__dict__['id']
         del self.__dict__['id']
Example #7
0
 def __init__(self, id, title, contributor, contributor_name, message, file):
     self.contributor = contributor
     self.contributor_name = contributor_name
     self.message = message
     self.comment_date = DateTime()
     NyFSFile.__init__(self, id, title, file)
 def __setstate__(self, state):
     """ Updates """
     NyFSFile.inheritedAttribute("__setstate__") (self, state)
     if 'id' in self.__dict__:
         self.__name__ = self.__dict__['id']
         del self.__dict__['id']
Example #9
0
 def __init__(self, id, contributor, message, file, reply_to):
     self.contributor = contributor
     self.message = message
     self.reply_to = reply_to
     self.comment_date = DateTime()
     NyFSFile.__init__(self, id, '', file)