Code Monkey home page Code Monkey logo

Comments (2)

FlixCoder avatar FlixCoder commented on September 2, 2024

That is indeed a fundamentally different design and sounds more like a new library if the structs are generated in user code. I don't think this will find its way into this crate.

However, due to profiling still being in conformance with the FHIR resource layout, you could make a trait on top:
There could be a proc macro generating a trait for a profile. The trait is then implemented for the specified resources in the profile and validates conformance with the profile. That way you would need to remember to call the validation though.

from fhir-sdk.

FlixCoder avatar FlixCoder commented on September 2, 2024

There is now even more possibilities: It would be possible to make your own structs for the profile (in what way ever, generated or not). Then you can use custom requests and parse the response to your types instead. The rest of the machinery would still be used, only URLs and response status handling would be custom.
Though it might even be possible to use the normal client methods without custom requests at all. It might be possible to just implement the required traits.

That said, I don't think I will bake in custom profile support itself, but allow crates on top to implement that without a lot of effort. So, closing this for now, but feel free to reopen if you think it is not easy enough to build profiles on top.

from fhir-sdk.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.