import java.util.ArrayList; public class ElementsVF3 { String name ; String type ; String value ; ArrayList attributs= new ArrayList() ; ArrayList Relations= new ArrayList() ; public ElementsVF3(String name,String value,String type, ArrayList attributs , ArrayList Relations ) { this.name = name ; this.attributs= attributs ;this.Relations= Relations ; this.value=value; this.type=type; } public ElementsVF3() { // TODO Auto-generated constructor stub } public void afficher() {System.out.println( type+" of name: "+name ); int u; if (attributs.isEmpty()==false) for (u = 0; u < attributs.size(); u++) { attributs.get(u).afficher(); } if (Relations.isEmpty()==false) for (u = 0; u < Relations.size(); u++) { System.out.println("--------------------------------------------- "); Relations.get(u).afficher(); } } public void afficherMod() {System.out.println("--------------------------------------------- "); System.out.println("Class name : "+name +" value "+value); int u; if (attributs.size()!=0) for (u = 0; u < attributs.size(); u++) { System.out.println("--------------------------------------------- "); attributs.get(u).afficherMod(); } if (Relations.size()!=0) for (u = 0; u < Relations.size(); u++) { System.out.println("--------------------------------------------- "); Relations.get(u).afficherMod(); } } }