Closed hanneskod closed 7 years ago
Updated the DonorMapper functions a bit, but not quite done yet.
Yepp. But is it ok to implement the interface as defined in this pr? I'd like to merge as soon as possible...
Sorry for the delay, travelling day, along with some git hickups. Looks good to me. Just to clarify: we'll use save() to store the Donor in the collection, and commit() is the only one that writes anything to disk?
This interface is missing a delete() function. It won't be needed for the alpha, but should be in here for the future. Posts will be added to the database by mistake, or get added twice. There will be a need to remove faulty posts. With the Json flatfile approach, it's easy for us to delete the posts by hand. But that won't be viable in the long run.
Oh in the middle of the night. I hope I didn't stress you.
Adding delete before merge.
And thanx for the comment on commit(). You are right about the intended usage. But your comment made me realize that this is an odd method to put in a mapper interface. Should be done somewhere else in the app, just before shut down. Will open an issue and fix. So removing from the interface...
Oh, not at all. Git and I disagreed yesterday, and I lost some code. That stressed me out. Can't think when there's stuff not written down. Had to get back to square 1 before I could calm down enought to read this.
I think I agree on the saving. That would mean that the mapper is given the database at startup, and hands it back when the user is done with it, in the right format. Disk storage is taken care of in a different step. Which feels clean to me.
And 2 in the morning is perfectly normal office hours for a workaholic with toddlers. If the kids are sleeping, it's work time.
@nonbinary
Started work on the
MandateResponseListener
and that needs to know the donor mapper. And I know you are working on the mapper in parallel. The purpose of this pr is to define the interface ofDonorMapper
so that I can develop against the interface at the same time is you implement it.Any comments on the interface? Hopefully we can merge this fast..