Class MockAudioSinkFactory
MockAudioSink to use in this mock.
By default, it loads an instance of MockDefaultAudioSink, but the class to load can be changed by setting
the system property "microej.internal.mock.audio.sink.impl" with the fully qualified name of the alternative implementation.
This other implementation can be loaded from another mock which is loaded in the same VEE.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe system property used to override the default audio sink loaded by the audio mock. -
Method Summary
Modifier and TypeMethodDescriptionstatic MockAudioSinkgetInstance(int resourceId, byte[] formatEncoding, int[] formatParameters, int bufferSize)
-
Field Details
-
MOCK_AUDIO_SINK_IMPL
The system property used to override the default audio sink loaded by the audio mock.The value must be the fully qualified name of an implementation of
MockAudioSink. If the system property is not set, or its value does not correspond to a valid fully qualified name of a subclass ofMockAudioSink, it loads an instance ofMockDefaultAudioSink.To load a subclass of
MockAudioSinkfrom another mock, the other mock must have this mock in its compile classpath. You can then implementMockAudioSinkand set it as audio sink implementation to use by callingSystem.setProperty(MockAudioSinkFactory.MOCK_AUDIO_SINK_IMPL, <CUSTOM_AUDIOSINK_FQN>)where<CUSTOM_AUDIOSINK_FQN>is the fully qualified name of your custom implementation.- See Also:
-
-
Method Details
-
getInstance
public static MockAudioSink getInstance(int resourceId, byte[] formatEncoding, int[] formatParameters, int bufferSize) throws ej.sni.NativeIOException - Throws:
ej.sni.NativeIOException
-