Add automatic media job type compatibility and introduce the DataVertical enum #1151
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
makes progress against #1065 by building on top of #1062 by further expanding support for automatically handling media jobs.
It allows not writing dedicated media adapters in cases where the existing photo/video functionality is satisfactory. It also provides automatic interoperability with destinations that only provide a Media adapter.
Main contributions:
MediaToPhotoConversionImporter
andMediaToPhotoConversionExporter
with generic versions that can support conversion between any two adapters:AnyToAnyImporter
andAnyToAnyExporter
MediaExporterDecorator
andMediaImporterDecorator
which combine existing photo and video adapters to seamlessly cover the media job type.TransferCompatibilityProvider
which attempts to build a substitute adapter upon not finding a real one. E.g. when a media job can't find a media importer, it will combine existing photo and video importers to perform the job.DataVertical
enum which replaces the hardcoded type strings like"PHOTOS"
.Review the commit separately as the
DataVertical
commit is very monotonic.note: this PR has a lot in it due to #1136 (comment)