public void addArticle(Produit p, int quantite) { if (items.get(p.getIdProduit()) == null) { LigneCommande lc = new LigneCommande(); lc.setProduit(p); lc.setQuantite(quantite); lc.setPrix(p.getPrix()); } else { LigneCommande lc = items.get(p.getIdProduit()); lc.setQuantite(lc.getQuantite() + quantite); } }