New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enable content switching on type- and formatCode #7
Comments
Thanks @justin-fyfe @devcritter. I completely agree, we should use typeCode and formatCode for the switching if content type is not going to be sufficient. Maybe we should just switch on those and if we have a use case for content type as well in the future then we can add it in. |
One question, would it be possible for a content handler to be able to register itself (or subscribe) to multiple formatCodes? I assume that it is possible for a generic CDA handler (that could handle several PCC templates) to call register for each template that can be handled. |
I'm not sure if this is possible at the moment, maybe @devcritter can comment further. I definitely think that a content handler should be able to do that though. |
Yup, they can at the moment (well on contentType). |
added type code to Content object, added type- formatCode handler map in service, type- formatCode handling for the unstructured data handler.
ServiceImpl: Switch InvalidContentTypeException -> InvalidCodedValueException
Issue raised by Justin on the wiki:
We could alter the signatures as follows:
Perhaps we should even take out the use of contentType and just switch on type- and formatCode? It sounds like they are more useful ito SHR usage?
For generic purposes switching on contentType could be useful I suppose, so we could have two matching paths:
allowing for one or the other...
The text was updated successfully, but these errors were encountered: