For the moment, DomBackup has been thought only for a backup goal, not restoration. It will be an issue to implement this last feature.
I see 2 ways of solving it:
Refactor a bit DomBackup to build it from a json file and add methods to restore a completed backup
Add a class for completed backup, such as DomCompleteBackup, sharing some methods with DomBackup, and focused only on showing information about a successful backup and also about restoring it. We should be able to transform a DomBackup to a DomCompleteBackup object, and also build a DomCompleteBackup obj from a json file (or a definition dict).
1st way seems dirtier to implement, but more logical to use: a DomBackup represents a backup you can start or restart.
2st way seems cleaner, and at use we know if we are dealing with something that have to be backup, or a complete backup.
For the moment, DomBackup has been thought only for a backup goal, not restoration. It will be an issue to implement this last feature.
I see 2 ways of solving it:
1st way seems dirtier to implement, but more logical to use: a DomBackup represents a backup you can start or restart. 2st way seems cleaner, and at use we know if we are dealing with something that have to be backup, or a complete backup.