Arquisoft / wiq_en1b

wiq_en1b
https://youtu.be/r2XqDUHj3zU
0 stars 1 forks source link

Design the domain and data models #30

Closed Mister-Mario closed 5 months ago

Mister-Mario commented 6 months ago

Discuss the domain and data models

UO289845 commented 6 months ago

This is the idea of the domain model for the question generator module based on what we talked in the meeting:

question_generator_hierarchy drawio

Explanation and details

The PopulationGenerator and CapitalGenerator are examples of specific implementations of the question generator. Also the QuestionGeneratorClass is the facade that comunicates the question generator with the backend. Also there's a connection between the database comunication interface and the AbstractGenerator, but in truth the comunication would be done through the specific implementations of the generator. And finally, the names are provisional and subject to change.

UO289845 commented 6 months ago

And one extra thing, the QuestionType is there simply for the conditional code in the facade, that would be something like:

if (type==QuestionType.POPULATION)
    generator = new PopulationGenerator();
else if (type==QuestionType.CAPITAL)
    generator = new CapitalGenerator();