ajout fonction API
This commit is contained in:
@@ -224,7 +224,17 @@ public class AbstractGroupeFactoryNP implements AbstractGroupeFactory {
|
||||
* @throws java.lang.NullPointerException si le String est null.
|
||||
*/
|
||||
public Set<Groupe> getGroupesOfEtudiant(Etudiant etu){
|
||||
throw new UnsupportedOperationException("pas encore implanté");
|
||||
Collection<Groupe> s= this.brain.values();
|
||||
Set<Groupe> ret=new LinkedHashSet<Groupe>();
|
||||
for(Groupe g: s){
|
||||
for(Etudiant e: g.getEtudiants()){
|
||||
if(e==etu){
|
||||
ret.add(g);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user