Hello,
I have designed an OpenAccess Domain Model that enables functionality in my database schema that I would like to be able to use across multiple applications and databases. In other words I've defined a set of tables and stored procedures that provide a feature for multiple applications that I have created an OpenAccess Domain Model to interact with that I want to reuse.
Currently when I create a new project that will utilize this functionality I have to take a copy of my existing model and then add the business logic for the application on top of it. This causes my application feature model to be bound to the business logic model. This will cause issues in the future because when I need to add features and provide fix bugs in the feature model because I will then have to update all of the models I based off of the original application feature model.
What I would like is the ability to create associations between two or more existing OpenAccess Domain Models or create model inheritance. For creating associations between models it would be great if two or more models could be linked together so that they could reference each other’s entities and create associations between keys. The model inheritance I envision working like base classes and derived class’s functionality. Either implementation would be great but I feel the linking of models with associations would be best because it would allow more than two models to be tied together whereas the inheritance model would only allow a base and derived model.
My end goal is that I envision having a collection of OpenAccess Domain Models, each satisfying specific functionality in my applications like a collection of class libraries does now in the .NET environment. For example I could have a UserAuthentication model with a User entity and WebForum model with a Thread entity. Ideally when the user creates a new Thread you would want to associate the User entity with the Thread.CreatedByUser property in the database. This is easy enough to accomplish if all of the entities are in a single model but with linked models the UserAuthentication model could partitioned out of the main model and be reused in multiple applications.
I'm sure you can see where I am going with this idea and its potential benefits so I have two questions I'm hoping you can answer:
One, can this type of functionality be implemented in the current release of OpenAccess ORM, and if so can you provide an example how to do so?
Two, if this cannot be done currently do you think this is a feature that could be added in a future release of OpenAccess ORM?
Thank you,
Bryan Farrell