Package org.jjazz.embeddedsynth.spi
Interface EmbeddedSynthProvider
public interface EmbeddedSynthProvider
Provide an EmbeddedSynth instance and its related methods.
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
static EmbeddedSynthProvider
Get the first EmbeddedSynthProvider instance found in the global lookup.static EmbeddedSynth
Get the default EmbeddedSynth instance.Get the EmbeddedSynth instance.Get the OUT MidiDevice associated to the embedded synth.boolean
Check if the EmbeddedSynth is active.boolean
Check if this EmbeddedSynthProvider is enabled.void
void
setEmbeddedSynthActive
(boolean b) If b is true do what's necessary so that the EmbeddedSynth becomes the current JJazzLab output synth.
-
Field Details
-
PROP_PROVIDER_ENABLED
- See Also:
-
PROP_EMBEDDED_SYNTH_ACTIVE
- See Also:
-
-
Method Details
-
getDefaultProvider
Get the first EmbeddedSynthProvider instance found in the global lookup.- Returns:
-
getDefaultSynth
Get the default EmbeddedSynth instance.Rely on getDefaultProvider().
- Returns:
- Can be null.
-
getEmbeddedSynth
EmbeddedSynth getEmbeddedSynth()Get the EmbeddedSynth instance.- Returns:
- Might be null if provider is disabled.
-
getOutMidiDevice
MidiDevice getOutMidiDevice()Get the OUT MidiDevice associated to the embedded synth.- Returns:
- Might be null if provider is disabled.
-
setEmbeddedSynthActive
If b is true do what's necessary so that the EmbeddedSynth becomes the current JJazzLab output synth.If state is changed a PROP_EMBEDDED_SYNTH_ACTIVE change event is fired.
- Parameters:
b
-- Throws:
EmbeddedSynthException
-
isEmbeddedSynthActive
boolean isEmbeddedSynthActive()Check if the EmbeddedSynth is active.- Returns:
-
isEnabled
boolean isEnabled()Check if this EmbeddedSynthProvider is enabled. By default an EmbeddedSynthProvider is enabled, but it might get itself disabled if it encounters initialization errors, typically when calling setEmbeddedSynthActive(). When it becomes disabled a PROP_PROVIDER_ENABLED change event is fired.- Returns:
-
addPropertyChangeListener
-
removePropertyChangeListener
-