Skip to content
Snippets Groups Projects
Commit 21a9055f authored by Henrik tom Wörden's avatar Henrik tom Wörden
Browse files

Merge branch 'f-refactor-merge' into f-constant-ident

parents 85adfed9 13114a96
No related branches found
No related tags found
5 merge requests!160STY: styling,!154MAINT: do not treat records if no Identifiable can be created,!153MAINT: refactor merge into new function,!152MAINT: move checks that are not related to identifiables,!151New class to track treated Records during sync
Pipeline #47721 passed
......@@ -254,27 +254,6 @@ class TreatedRecordLookUp():
self._missing: dict[int, db.Entity] = {}
self._existing: dict[int, db.Entity] = {}
# TODO is this needed?
def by_path(self, path):
if path in self._path_look_up:
return self._path_look_up[path]
else:
return None
# TODO is this needed?
def by_ID(self, eid):
if eid in self._id_look_up:
return self._id_look_up[path]
else:
return None
# TODO is this needed?
def by_identifiable(self, identifiable):
if identifiable.get_representation() in self._id_look_up:
return self._id_look_up[identifiable.get_representation()]
else:
return None
def add(self, record: db.Entity, identifiable: Optional[Identifiable] = None):
"""
Add a Record that was treated, such that it is contained in the internal look up dicts
......@@ -326,16 +305,6 @@ class TreatedRecordLookUp():
else:
return None
# TODO is this needed?
def is_missing(self, record: db.Entity):
""" Check whether this Record is missing on the remote server """
return id(record) in self._missing
# TODO is this needed?
def is_existing(self, record: db.Entity):
""" Check whether this Record is existing on the remote server """
return id(record) in self._existing
def get_missing_list(self):
""" Return all Records that are missing in the remote server """
return list(self._missing.values())
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment