|
|
@ -61,14 +61,8 @@ public class Playlist implements Consumer<Track> |
|
|
|
Playlist ret = new Playlist(yaml.string("name")); |
|
|
|
Playlist ret = new Playlist(yaml.string("name")); |
|
|
|
YamlSequence trackList = yaml.value("tracks").asSequence(); |
|
|
|
YamlSequence trackList = yaml.value("tracks").asSequence(); |
|
|
|
for (int i = 0; i < trackList.size(); i++) |
|
|
|
for (int i = 0; i < trackList.size(); i++) |
|
|
|
{ |
|
|
|
|
|
|
|
try |
|
|
|
|
|
|
|
{ |
|
|
|
{ |
|
|
|
ret.addTrack(Track.fromYaml(trackList.yamlMapping(i))); |
|
|
|
ret.addTrack(Track.fromYaml(trackList.yamlMapping(i))); |
|
|
|
} catch (MalformedURLException ex) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
Logger.getLogger(Playlist.class.getName()).log(Level.SEVERE, null, ex); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
return ret; |
|
|
|
return ret; |
|
|
|
} |
|
|
|
} |
|
|
|