-
-
Notifications
You must be signed in to change notification settings - Fork 99
Closed
Labels
enhancementNew feature or requestNew feature or request
Description
Is your feature request related to a problem? Please describe.
Since it cannot detect when the player is finished loading, it cannot know when to terminate the program.
Describe the solution you'd like
Thread blocking process until the player finishes loading the music stream (like player.waitReady().get())
Additional context
Example
public class Main(){
public static void main(String[] args) {
Session session = new Session.Builder()
.userPass("UserName", "Password")
.create();
PlayerConfiguration playerConfiguration = new PlayerConfiguration.Builder()
.setOutput(AudioOutput.STDOUT)
.build();
Player player = new Player(playerConfiguration, session);
try{
player.waitReady().get();
} catch(InterruptedException e){
e.printStackTrace();
} catch(ExecutionException e){
e.printStackTrace();
}
player.load("spotify:track:xxxxxxxxxxxxxxxxxxxxxx", true);
// Something to block it?
try{
session.close();
} catch(IOException e){
e.printStackTrace();
}
System.exit(0);
}
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request