-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMusic.java
More file actions
214 lines (172 loc) · 4.89 KB
/
Music.java
File metadata and controls
214 lines (172 loc) · 4.89 KB
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
import java.time.LocalDate;
public class Music {
// Idk if I can use Lombok @Getter and @Setter here
// Because those are a dependency and idk if 'Verde' system supports it.
// Lets do the manual boring stuff
// Don't ask me why 'id' is a String either lol
private String id;
private String name;
private String key;
private String[] artists;
private LocalDate release_date;
private double acousticness;
private double danceability;
private double energy;
private int duration_ms;
private double instrumentalness;
private double valence;
private int popularity;
private double time;
private double liveness;
private double loudness;
private double speechiness;
private int year;
private double explicit;
private double mode;
//Constructors, gotta have 2 as default
public Music(String id, String name, String key, String[] artists, LocalDate release_date,
double acousticness, double danceability, double energy, int duration_ms,
double instrumentalness, double valence, int popularity, double time,
double liveness, double loudness, double speechiness, int year, double explicit, double mode) {
this.id = id;
this.name = name;
this.key = key;
this.artists = artists;
this.release_date = release_date;
this.acousticness = acousticness;
this.danceability = danceability;
this.energy = energy;
this.duration_ms = duration_ms;
this.instrumentalness = instrumentalness;
this.valence = valence;
this.popularity = popularity;
this.time = time;
this.liveness = liveness;
this.loudness = loudness;
this.speechiness = speechiness;
this.year = year;
this.explicit = explicit;
this.mode = mode;
}
Music() {
}
//Manual getters (seriously ? XD)
public String getId() {
return id;
}
public String getName() {
return name;
}
public String getKey() {
return key;
}
public String[] getArtists() {
return artists;
}
public LocalDate getRelease_date() {
return release_date;
}
public double getAcousticness() {
return acousticness;
}
public double getDanceability() {
return danceability;
}
public double getEnergy() {
return energy;
}
public int getDuration_ms() {
return duration_ms;
}
public double getInstrumentalness() {
return instrumentalness;
}
public double getValence() {
return valence;
}
public int getPopularity() {
return popularity;
}
public double getTime() {
return time;
}
public double getLiveness() {
return liveness;
}
public double getLoudness() {
return loudness;
}
public double getSpeechiness() {
return speechiness;
}
public int getYear() {
return year;
}
public double getExplicit() {
return explicit;
}
public double getMode() {
return mode;
}
//Manual Setters (boring af Ik)
public void setId(String id) {
this.id = id;
}
public void setName(String name) {
this.name = name;
}
public void setKey(String key) {
this.key = key;
}
public void setArtists(String[] artists) {
this.artists = artists;
}
public void setRelease_date(LocalDate release_date) {
this.release_date = release_date;
}
public void setAcousticness(double acousticness) {
this.acousticness = acousticness;
}
public void setDanceability(double danceability) {
this.danceability = danceability;
}
public void setEnergy(double energy) {
this.energy = energy;
}
public void setDuration_ms(int duration_ms) {
this.duration_ms = duration_ms;
}
public void setInstrumentalness(double instrumentalness) {
this.instrumentalness = instrumentalness;
}
public void setValence(double valence) {
this.valence = valence;
}
public void setPopularity(int popularity) {
this.popularity = popularity;
}
public void setTime(double time) {
this.time = time;
}
public void setLiveness(double liveness) {
this.liveness = liveness;
}
public void setLoudness(double loudness) {
this.loudness = loudness;
}
public void setSpeechiness(double speechiness) {
this.speechiness = speechiness;
}
public void setYear(int year) {
this.year = year;
}
public void setExplicit(double explicit) {
this.explicit = explicit;
}
public void setMode(double mode) {
this.mode = mode;
}
public Music clone(Music music) throws CloneNotSupportedException {
return (Music) music.clone();
}
}