sempr-tk / sempr

SEMPR - Semantic Environment Mapping, Processing and Reasoning
BSD 3-Clause "New" or "Revised" License
7 stars 1 forks source link

IDGeneration, saving & object_already_persistent #32

Open niniemann opened 6 years ago

niniemann commented 6 years ago

I'd like to change something fundamentally here. Original idea was to create the ID all the way down in the c'tor of DBObject so that every derived entity can already access and use it (especially usefull for creating a child-RDF-Entity / PropertyMap etc). By now I'm rather convinced that it would be better to split things up: Leave the "default c'tor" as simple as possible, without any ID-generation whatsoever, and add a second initialization step to set the id and update anything that relies on it.

ctieben commented 5 years ago

Please also think about temporary entities. See the simple solution in #53 which shall be solved by the architecture and not by flags.