Module com.sun.xml.messaging.saaj
Class UUDecoderStream
java.lang.Object
java.io.InputStream
java.io.FilterInputStream
com.sun.xml.messaging.saaj.packaging.mime.util.UUDecoderStream
- All Implemented Interfaces:
Closeable,AutoCloseable
This class implements a UUDecoder. It is implemented as
a FilterInputStream, so one can just wrap this class around
any input stream and read bytes from this filter. The decoding
is done as the bytes are read out.
-
Field Summary
Fields inherited from class java.io.FilterInputStream
in -
Constructor Summary
ConstructorsConstructorDescriptionCreate a UUdecoder that decodes the specified input stream -
Method Summary
Methods inherited from class java.io.InputStream
nullInputStream, readAllBytes, readNBytes, readNBytes, skipNBytes, transferTo
-
Constructor Details
-
UUDecoderStream
Create a UUdecoder that decodes the specified input stream- Parameters:
in- the input stream
-
-
Method Details
-
read
Read the next decoded byte from this input stream. The byte is returned as anintin the range0to255. If no byte is available because the end of the stream has been reached, the value-1is returned. This method blocks until input data is available, the end of the stream is detected, or an exception is thrown.- Overrides:
readin classFilterInputStream- Returns:
- next byte of data, or
-1if the end of stream is reached. - Throws:
IOException- if an I/O error occurs.- See Also:
-
read
- Overrides:
readin classFilterInputStream- Throws:
IOException
-
markSupported
public boolean markSupported()- Overrides:
markSupportedin classFilterInputStream
-
available
- Overrides:
availablein classFilterInputStream- Throws:
IOException
-
getName
Get the "name" field from the prefix. This is meant to be the pathname of the decoded file- Returns:
- name of decoded file
- Throws:
IOException- if an I/O error occurs.
-
getMode
Get the "mode" field from the prefix. This is the permission mode of the source file.- Returns:
- permission mode of source file
- Throws:
IOException- if an I/O error occurs.
-