#NEWLINE# def addAssociation( self , assoc , rawSgAssoc , originServer , originId , commit = True ) : #NEWLINE# #INDENT# '\n        :param assoc: (sydent.threepid.GlobalThreepidAssociation) The association to add as a high level object\n        :param sgAssoc The original raw bytes of the signed association\n        :return:\n        ' #NEWLINE# cur = self . sydent . db . cursor ( ) #NEWLINE# res = cur . execute ( 'insert or ignore into global_threepid_associations (medium, address, mxid, ts, notBefore, notAfter, originServer, originId, sgAssoc) values (?, ?, ?, ?, ?, ?, ?, ?, ?)' , ( res . medium , assoc . address , assoc . mxid , assoc . ts , assoc . not_before , assoc . not_after , originServer , originId , rawSgAssoc ) ) #NEWLINE# if commit : #NEWLINE# #INDENT# self . sydent . db . commit ( )