Example #1
0
 def hash(self, row):
     return content_hash(row.Resource)
Example #2
0
 def hash(self, row):
     return content_hash(row.Title, row.Description, row.Standard,
                         row.Origin)
Example #3
0
 def hash(self, row):
     return content_hash(row.Modified, row.RemoteID, row.CachedUntil,
                         row.Expires, row.UserID)
Example #4
0
 def hash(self, row):
     return content_hash(row.Login, row.Password, row.Name, row.FirstName,
                         row.Email, row.Administrator)
Example #5
0
 def hash(self, row):
     return content_hash(row.Title, row.Description, row.UsageAgreement)
Example #6
0
 def hash(self, row):
     return content_hash(row.Label, row.ShortView, row.MediumView,
                         row.LongView)
Example #7
0
 def hash(self, row):
     return content_hash(row.ObjectID, row.UserID, row.GroupID,
                         row.GrantPriv, row.DenyPriv)
Example #8
0
 def hash(self, row):
     return content_hash(row.Modified, row.RemoteID, row.CachedUntil, row.Expires, row.UserID)
Example #9
0
 def hash(self, row):
     return content_hash(row.CollectionID, (row.Flags or 0) & IMAGE_SHARED)
Example #10
0
 def hash(self, row):
     return content_hash(row.Title, row.Description, row.Standard, row.Origin)
Example #11
0
 def hash(self, row):
     return content_hash(row.ItemValue)
Example #12
0
 def hash(self, row):
     return content_hash(row.Title, row.ResourcePath)
Example #13
0
 def hash(self, row):
     return content_hash(row.Title, row.Description, row.UsageAgreement)
Example #14
0
 def hash(self, row):
     return content_hash(row.AttributeValue)
Example #15
0
 def hash(self, row):
     return content_hash(row.Title)
Example #16
0
 def hash(self, row):
     return content_hash(row.Resource)
Example #17
0
 def hash(self, row):
     return content_hash(row.Label, row.Name, row.ControlledListID)
Example #18
0
 def hash(self, row):
     return content_hash(row.Title, row.UserID, row.Description, row.ArchiveFlag, row.AccessPassword)
Example #19
0
 def hash(self, row):
     return content_hash(row.Login, row.Password, row.Name, row.FirstName, row.Email, row.Administrator)
Example #20
0
 def hash(self, row):
     return content_hash(row.Title)
Example #21
0
 def hash(self, row):
     return content_hash(row.ObjectID, row.UserID, row.GroupID,
                         row.GrantPriv, row.DenyPriv, row.MediumImageHeight,
                         row.MediumImageWidth)
Example #22
0
 def hash(self, row):
     return content_hash(row.DisplayOrder, row.Annotation, row.Scratch)
Example #23
0
 def hash(self, row):
     return content_hash(row.AttributeValue)
Example #24
0
 def hash(self, row):
     return content_hash(row.Label, row.Name, row.ControlledListID)
Example #25
0
 def hash(self, row):
     return content_hash(row.Title, row.ResourcePath)
Example #26
0
 def hash(self, row):
     return content_hash(row.DCElement, row.DCRefinement)
Example #27
0
 def hash(self, row):
     return content_hash(row.ItemValue)
Example #28
0
 def hash(self, row):
     return content_hash(row.Label, row.ShortView, row.MediumView, row.LongView)
Example #29
0
 def hash(self, row):
     return content_hash(row.CollectionID, (row.Flags or 0) & IMAGE_SHARED)
Example #30
0
 def hash(self, row):
     return content_hash(row.Label, row.FieldValue, row.DisplayOrder)
Example #31
0
 def hash(self, row):
     return content_hash(row.Title, row.UserID, row.Description,
                         row.ArchiveFlag, row.AccessPassword)
Example #32
0
 def hash(self, row):
     return content_hash(row.ObjectID, row.UserID, row.GroupID, row.GrantPriv, row.DenyPriv)
Example #33
0
 def hash(self, row):
     return content_hash(row.DisplayOrder, row.Annotation, row.Scratch)
Example #34
0
 def hash(self, row):
     return content_hash(row.ObjectID, row.UserID, row.GroupID, row.GrantPriv, row.DenyPriv, row.MediumImageHeight, row.MediumImageWidth)
Example #35
0
 def hash(self, row):
     return content_hash(row.DCElement, row.DCRefinement)
Example #36
0
    ResetPassword=1 << 18,
    ManageAnnouncements=1 << 21,
    ManageControlledLists=1 << 23,
    ManageCollectionGroups=1 << 25,
    UserOptions=1 << 26,
    PersonalImages=1 << 27,
    ShareImages=1 << 28,
    SuggestImages=1 << 29,
    Unknown=1 << 31,
)

IMAGE_SHARED = 1
IMAGE_SUGGESTED = 2
IMAGE_REJECTED = 4

STATIC_CONTENT_HASH = content_hash('static')


class MergeObjectsException(Exception):
    def __init__(self, instance):
        super(MergeObjectsException, self).__init__()
        self.instance = instance


class MigrateModel(object):

    instance_maps = dict()

    def __init__(self,
                 cursor,
                 model,
Example #37
0
 def hash(self, row):
     return content_hash(row.Label, row.FieldValue, row.DisplayOrder)
Example #38
0
    ManageAnnouncements = 1 << 21,
    ManageControlledLists = 1 << 23,
    ManageCollectionGroups = 1 << 25,
    UserOptions = 1 << 26,
    PersonalImages = 1 << 27,
    ShareImages = 1 << 28,
    SuggestImages = 1 << 29,
    Unknown = 1 << 31,
)

IMAGE_SHARED = 1
IMAGE_SUGGESTED = 2
IMAGE_REJECTED = 4


STATIC_CONTENT_HASH = content_hash('static')


class MergeObjectsException(Exception):

    def __init__(self, instance):
        super(MergeObjectsException, self).__init__()
        self.instance = instance


class MigrateModel(object):

    instance_maps = dict()

    def __init__(self, cursor, model, query, label=None, m2m_model=None, type=None):
        self.model = model