-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTestDocuments.java
More file actions
31 lines (21 loc) · 832 Bytes
/
Copy pathTestDocuments.java
File metadata and controls
31 lines (21 loc) · 832 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package td2Class.bibliotheque;
public class TestDocuments {
public static void main(String[] args) {
Document all[] = new Document[6];
Dictionnaire dic = new Dictionnaire(1, "Hachette", Langue.Espagnol);
all[0] = dic;
Document doc = new Document(2, "Super Document");
all[1] = doc;
Livre livre = new Livre(3, "Harry Potter", "J. K. Rowling", 4000);
all[2] = livre;
Manuel man = new Manuel(4, "Java Pour les nul", "Pierre Pierre", 200, 0);
all[3] = man;
Revue rev = new Revue(5, "Programmez", 12, 2014);
all[4] = rev;
Roman rom = new Roman(6, "Harry Potter 2", "J. K. Rowling", 4000, PrixLitteraire.valueOf("a"));
all[5] = rom;
for(Document d : all) {
System.out.println(d);
}
}
}