Compare commits
No commits in common. "43cbdc54defcb2056b6b91c5f1be1183d3a5bc61" and "b854ed53f4a446cb318b81811900788aed51b028" have entirely different histories.
43cbdc54de
...
b854ed53f4
@ -1,54 +1,43 @@
|
|||||||
/*
|
/*
|
||||||
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
|
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
|
||||||
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
|
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
|
||||||
*/
|
*/
|
||||||
package métiers;
|
package métiers;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import métiers.Commande;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author famille Thevenot
|
* @author famille Thevenot
|
||||||
*/
|
*/
|
||||||
public class Entreprise {
|
public class Entreprise {
|
||||||
private String raisonSociale;
|
private String raisonSociale;
|
||||||
private ArrayList<Commande> lesCommandes = new ArrayList<>();
|
|
||||||
private ArrayList<Instrument> lesInstruments = new ArrayList<>();
|
public Entreprise(String raisonSociale) {
|
||||||
|
this.raisonSociale = raisonSociale;
|
||||||
public Entreprise(String raisonSociale) {
|
}
|
||||||
this.raisonSociale = raisonSociale;
|
|
||||||
}
|
public String getRaisonSociale() {
|
||||||
|
return raisonSociale;
|
||||||
public String getRaisonSociale() {
|
}
|
||||||
return raisonSociale;
|
|
||||||
}
|
public void setRaisonSociale(String raisonSociale) {
|
||||||
|
this.raisonSociale = raisonSociale;
|
||||||
public void setRaisonSociale(String raisonSociale) {
|
}
|
||||||
this.raisonSociale = raisonSociale;
|
|
||||||
}
|
@Override
|
||||||
|
public String toString() {
|
||||||
@Override
|
return "Entreprise{" + "raisonSociale=" + raisonSociale + '}';
|
||||||
public String toString() {
|
}
|
||||||
return "Entreprise{" + "raisonSociale=" + raisonSociale + '}';
|
|
||||||
}
|
|
||||||
|
public void ajouterCommande(Commande uneCommande){
|
||||||
|
}
|
||||||
public void ajouterCommande(Commande uneCommande){
|
public void supprimerCommande(Commande uneCommande){
|
||||||
lesCommandes.add(uneCommande);
|
}
|
||||||
}
|
|
||||||
|
public Commande rechercherCommande(int noCom){
|
||||||
public void supprimerCommande(Commande uneCommande){
|
Commande laCommande=null;
|
||||||
lesCommandes.remove(uneCommande);
|
return laCommande;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
public Commande rechercherCommande(int noCom){
|
|
||||||
Commande uneCommande = null;
|
|
||||||
for(Commande laCommande : lesCommandes){
|
|
||||||
if(laCommande.noCom == noCom){
|
|
||||||
uneCommande = laCommande;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return uneCommande;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user