mercredi 18 novembre 2020

Is there a design pattern for object dependency [closed]

Hi in my application I need to perform an idea that there is the main object that has tasks that may depend on each other

for example:

MissionToMars has a list of tasks

Task1 - find a good health astronauts Task2 - Build a ship Task3 - Send the ship to mars

task1 and 2 can be done together but task3 depends on task 1 and 2 so it can't start until task1 and task2 will be done... is there any Design Paterren for that approach or i need to do some kind of dependence table like

task | dependent task
1
2
3 ----- 1
3 ----- 2

Aucun commentaire:

Enregistrer un commentaire