Class FilteredSoundStream
- java.lang.Object
-
- java.io.InputStream
-
- java.io.FilterInputStream
-
- fr.paris.lutece.plugins.captcha.modules.jcaptcha.service.sound.filter.FilteredSoundStream
-
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable
public class FilteredSoundStream extends java.io.FilterInputStreamThe FilteredSoundStream class is a FilterInputStream that applies a SoundFilter to the underlying input stream.- See Also:
SoundFilter
-
-
Constructor Summary
Constructors Constructor Description FilteredSoundStream(javax.sound.sampled.AudioInputStream in, SoundFilter soundFilter)Creates a new FilteredSoundStream object with the specified InputStream and SoundFilter.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intread(byte[] samples, int offset, int length)Overrides the FilterInputStream method to apply this filter whenever bytes are read-
Methods inherited from class java.io.FilterInputStream
available, close, mark, markSupported, read, read, reset, skip
-
-
-
-
Constructor Detail
-
FilteredSoundStream
public FilteredSoundStream(javax.sound.sampled.AudioInputStream in, SoundFilter soundFilter)Creates a new FilteredSoundStream object with the specified InputStream and SoundFilter.- Parameters:
in- the file sound streamsoundFilter- the sound filter
-
-
Method Detail
-
read
public int read(byte[] samples, int offset, int length) throws java.io.IOExceptionOverrides the FilterInputStream method to apply this filter whenever bytes are read- Overrides:
readin classjava.io.FilterInputStream- Parameters:
samples- the samplesoffset- the offsetlength- the length of sample- Returns:
- the byte read
- Throws:
java.io.IOException- the IOException
-
-