The user has an addressbook; each entry therein has:
contacts.nick
contacts.webId -> their addressbook, our entry therein -> the ldp.inbox on that
our ldp.inbox on their entry in our addressbook
our solid.sentbox, for our own reference
A SolidContact is constructed from contactSub, podData.
It can send a message, with a callback (that will be called twice), and it can fetchSent and fetchReceived. This will trigger onMessage lots of times.
A SnapContact is constructed from SolidContact.
It can send a SnapStateTransition, and has a SnapChecker so just call loadMessages and it will load all sent and received into the SnapChecker.
SolidSnap has a singleton PodData, it exposes a getSnapContacts which calls getContacts on that, and constructs one SnapContact for each SolidContact. It also exposes addContact from PodData.
The user has an addressbook; each entry therein has:
A SolidContact is constructed from contactSub, podData. It can send a message, with a callback (that will be called twice), and it can fetchSent and fetchReceived. This will trigger onMessage lots of times. A SnapContact is constructed from SolidContact. It can send a SnapStateTransition, and has a SnapChecker so just call loadMessages and it will load all sent and received into the SnapChecker.
SolidSnap has a singleton PodData, it exposes a getSnapContacts which calls getContacts on that, and constructs one SnapContact for each SolidContact. It also exposes addContact from PodData.