- Sponsor
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Generate inheritance information manually #1570
Comments
Inheritance is generated here: More or less hard-coded... maybe we can provide add an extension point somehow? Maybe you can inherit from the generator class and modify/extend this? Maybe we should wait until this pr which changes the allof generation is merged: |
Thanks for your response. I also had a look to this class but there is no extension point. Wait, I can just write a ITypeMapper, right? |
Mhm,
|
Cant you just add the additional types to the document’s definition and reference the base schema in allof and maybe update the discriminator mappings of the base schema (in a document processor)? |
This was also my idea, but how can I find the correct schema in the document processor? |
The contest has a resolver which can resolve the generated schema for a type i think |
Thanks, it works:
|
Hi,
I have a typical application with multiple layers and separate data structures: DTOs in my Api Layer, Business Objects in my Domain Layer and so on.
But one part of my application is a rule engine, like "When X happens (Trigger) send a tweet (Action)". So far I use inheritance for the different actions and define this inheritance in my DTOs. I would like to add plugins for the actions and therefore I have to break the architecture here a little bit. The goal is to define Action Definitions in your plugin and everything else is generated from it, e.g.
The question is: How can I generate the inheritance definition for it? I am had a look to the interfaces like IOperationProcessor and so but I can just not find the right information.
The text was updated successfully, but these errors were encountered: