-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathJukeBoxe.java
57 lines (38 loc) · 834 Bytes
/
JukeBoxe.java
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
public class JukeBoxe {
public String TitoloCanzone;
public String Autore;
public JukeBoxe(String x, String y) {
this.TitoloCanzone = x;
this.Autore = y;
}
}
class Canzone extends JukeBoxe {
public String Nazione;
public int Anno;
public Canzone(String z, String w, String nazione, int p) {
super(z, w);
this.Anno = p;
this.Nazione = nazione;
}
public void setAnno(int w) {
this.Anno = w;
}
public boolean testAnno(int x) {
boolean test = true;
if (Anno != x) {
test = false;
}
return test;
}
public String Visualizza() {
return ("titolo: " + TitoloCanzone + "Autore:" + Autore + "Nazione: " + Nazione + " Anno : " + Anno);
}
public int getAnno() {
// TODO Auto-generated method stub
return Anno;
}
public String getNazionalita() {
// TODO Auto-generated method stub
return Nazione;
}
}