package depart.frontal.taches;

import ca.ntro.app.tasks.frontend.FrontendTasks;
import depart.frontal.vues.VueA;

import static ca.ntro.app.tasks.frontend.FrontendTasks.*;

public class TachesA {
	
	public static void creerTaches(FrontendTasks tasks) {
		
		tasks.taskGroup("TachesA")
		
		     .waitsFor(viewLoaders())
		
		     .contains(subTasks -> {
		    	 
				tacheA1(subTasks);

		     });
	}

	private static void tacheA1(FrontendTasks subTasks) {

		subTasks.task(create(VueA.class))

		     .waitsFor(viewLoader(VueA.class))

		     .executesAndReturnsValue(inputs -> {
		    	 
		    	 var objA = inputs.get(viewLoader(VueA.class));
		    	 var objB = objA.createView();

		    	 return objB;
		     });
	}

}
