com.blackledge.david.tivo.multitasker.plugins
Class LocalAudio
java.lang.Object
com.blackledge.david.tivo.multitasker.plugins.LocalAudio
- All Implemented Interfaces:
- Audio, LocalOptionProvider, TickerTape
public class LocalAudio
- extends Object
- implements Audio, TickerTape, LocalOptionProvider
non-smart implementation of getting local music URLs for everything in "My Music"
- Version:
- $Revision: 1.1 $
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
OPTION_LOCAL_MUSIC_FOLDER
public static final String OPTION_LOCAL_MUSIC_FOLDER
- See Also:
- Constant Field Values
LocalAudio
public LocalAudio()
getNextAudioStream
public String getNextAudioStream()
- Description copied from interface:
Audio
- Provides the next Audio Stream to play. Use a URL of the form
app.getContext().getBaseURI().toString()+"local/"+myFilePath To play
a file local to the current computer, where myFilePath is relative to the
local file root defined in options.
- Specified by:
getNextAudioStream
in interface Audio
- Returns:
- a URL string that will provide an mp3 stream.
init
public void init(MultiTaskerApplication app)
- Specified by:
init
in interface Audio
- Specified by:
init
in interface TickerTape
getNextContent
public TickerTape.TickerTapeSegment getNextContent()
- Specified by:
getNextContent
in interface TickerTape
getLocalOptionNames
public Collection getLocalOptionNames()
- just the keySet of
getLocalOptionPreferences()
- Specified by:
getLocalOptionNames
in interface LocalOptionProvider
- Returns:
getLocalOptionPreferences
public Map getLocalOptionPreferences()
- Add support for
OPTION_LOCAL_MUSIC_FOLDER
map of your option keys where the value is "Type[+],text [range]" per the
MultiTaskerPreferences
class. Use a LinkedHashMap
to
maintain the order of your options.
- Specified by:
getLocalOptionPreferences
in interface LocalOptionProvider
- Returns:
- See Also:
LocalOptionProvider.getLocalOptionPreferences()
getLocalOptionDefault
public String getLocalOptionDefault(String key)
- Description copied from interface:
LocalOptionProvider
- defaults for each of the local option keys. Could just return null if
there is no provided default. If the local option default starts with a +,
it is appended (delimeted by a comma) to the getOptionDefault value, if
any.
- Specified by:
getLocalOptionDefault
in interface LocalOptionProvider
- Returns:
- Option value to use if none is set or overridden.