ultrasonic-app-subsonic-and.../ultrasonic/src/main/java/org/moire/ultrasonic/service/MediaPlayerController.java

118 lines
2.6 KiB
Java
Raw Normal View History

2013-04-06 21:47:24 +02:00
/*
This file is part of Subsonic.
Subsonic is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Subsonic is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Subsonic. If not, see <http://www.gnu.org/licenses/>.
Copyright 2009 (C) Sindre Mehus
*/
2015-07-26 18:15:07 +02:00
package org.moire.ultrasonic.service;
2013-04-06 21:47:24 +02:00
2015-07-26 18:15:07 +02:00
import org.moire.ultrasonic.audiofx.EqualizerController;
import org.moire.ultrasonic.audiofx.VisualizerController;
import org.moire.ultrasonic.domain.MusicDirectory.Entry;
import org.moire.ultrasonic.domain.PlayerState;
import org.moire.ultrasonic.domain.RepeatMode;
2013-04-06 21:47:24 +02:00
import java.util.List;
2013-04-06 21:47:24 +02:00
/**
* @author Sindre Mehus
* @version $Id$
*/
2020-06-25 14:33:44 +02:00
public interface MediaPlayerController
{
2013-04-06 21:47:24 +02:00
void download(List<Entry> songs, boolean save, boolean autoplay, boolean playNext, boolean shuffle, boolean newPlaylist);
2013-04-06 21:47:24 +02:00
void downloadBackground(List<Entry> songs, boolean save);
2013-04-06 21:47:24 +02:00
void setShufflePlayEnabled(boolean enabled);
2013-04-06 21:47:24 +02:00
boolean isShufflePlayEnabled();
2013-04-06 21:47:24 +02:00
void shuffle();
2013-04-06 21:47:24 +02:00
RepeatMode getRepeatMode();
2013-04-06 21:47:24 +02:00
void setRepeatMode(RepeatMode repeatMode);
2013-04-06 21:47:24 +02:00
boolean getKeepScreenOn();
2013-04-06 21:47:24 +02:00
void setKeepScreenOn(boolean screenOn);
2013-04-06 21:47:24 +02:00
boolean getShowVisualization();
2013-04-06 21:47:24 +02:00
void setShowVisualization(boolean showVisualization);
void clear();
2013-04-06 21:47:24 +02:00
void clearIncomplete();
void remove(DownloadFile downloadFile);
void play(int index);
void seekTo(int position);
void previous();
2013-04-06 21:47:24 +02:00
void next();
2013-04-06 21:47:24 +02:00
void pause();
2013-04-06 21:47:24 +02:00
void stop();
2013-04-06 21:47:24 +02:00
void start();
2013-04-06 21:47:24 +02:00
void reset();
2013-04-06 21:47:24 +02:00
PlayerState getPlayerState();
2013-04-06 21:47:24 +02:00
int getPlayerPosition();
2013-04-06 21:47:24 +02:00
int getPlayerDuration();
2013-04-06 21:47:24 +02:00
void delete(List<Entry> songs);
2013-04-06 21:47:24 +02:00
void unpin(List<Entry> songs);
2013-04-06 21:47:24 +02:00
void setSuggestedPlaylistName(String name);
2013-04-06 21:47:24 +02:00
String getSuggestedPlaylistName();
2013-04-06 21:47:24 +02:00
EqualizerController getEqualizerController();
2013-04-06 21:47:24 +02:00
VisualizerController getVisualizerController();
2013-04-06 21:47:24 +02:00
boolean isJukeboxEnabled();
2013-04-06 21:47:24 +02:00
boolean isJukeboxAvailable();
void setJukeboxEnabled(boolean b);
2013-04-06 21:47:24 +02:00
void adjustJukeboxVolume(boolean up);
2013-04-06 21:47:24 +02:00
void togglePlayPause();
2013-04-06 21:47:24 +02:00
void setVolume(float volume);
2013-04-06 21:47:24 +02:00
void restore(List<Entry> songs, int currentPlayingIndex, int currentPlayingPosition, boolean autoPlay, boolean newPlaylist);
void stopJukeboxService();
2020-01-13 21:20:52 +01:00
void updateNotification();
2020-02-23 12:57:15 +01:00
void setSongRating(final int rating);
2013-04-06 21:47:24 +02:00
}