Package org.apache.juneau.encoders
Class IdentityEncoder
java.lang.Object
org.apache.juneau.encoders.Encoder
org.apache.juneau.encoders.IdentityEncoder
Encoder for handling "identity" encoding and decoding.
Identity encoding is just another name for no encoding at all.
Notes:
- This class is thread safe and reusable.
See Also:
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionString[]
Returns[
."identity" ]Converts the specified compressed input stream into an uncompressed stream.Converts the specified uncompressed output stream into an uncompressed stream.
-
Field Details
-
INSTANCE
Singleton
-
-
Constructor Details
-
IdentityEncoder
public IdentityEncoder()Constructor.
-
-
Method Details
-
getInputStream
Description copied from class:Encoder
Converts the specified compressed input stream into an uncompressed stream.- Specified by:
getInputStream
in classEncoder
- Parameters:
is
- The compressed stream.- Returns:
- The uncompressed stream.
- Throws:
IOException
- If any errors occur, such as on a stream that's not a valid GZIP input stream.
-
getOutputStream
Description copied from class:Encoder
Converts the specified uncompressed output stream into an uncompressed stream.- Specified by:
getOutputStream
in classEncoder
- Parameters:
os
- The uncompressed stream.- Returns:
- The compressed stream stream.
- Throws:
IOException
- If any errors occur.
-
getCodings
Returns[
."identity" ]- Specified by:
getCodings
in classEncoder
- Returns:
- The codings that this encoder handles.
-