Class Base64Encoder

  • All Implemented Interfaces:
    Encoder

    public class Base64Encoder
    extends java.lang.Object
    implements Encoder
    Encoder implementation for standard base64 encoding.
    Version:
    $Id: //depot/branches/personal/haraldk/twelvemonkeys/release-2/twelvemonkeys-core/src/main/java/com/twelvemonkeys/io/enc/Base64Encoder.java#2 $
    Author:
    Harald Kuhr
    See Also:
    RFC 1421, RFC 2045, Base64Decoder
    • Constructor Summary

      Constructors 
      Constructor Description
      Base64Encoder()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void encode​(java.io.OutputStream stream, java.nio.ByteBuffer buffer)
      Encodes up to buffer.remaining() bytes into the given input stream, from the given buffer.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • Base64Encoder

        public Base64Encoder()
    • Method Detail

      • encode

        public void encode​(java.io.OutputStream stream,
                           java.nio.ByteBuffer buffer)
                    throws java.io.IOException
        Description copied from interface: Encoder
        Encodes up to buffer.remaining() bytes into the given input stream, from the given buffer.
        Specified by:
        encode in interface Encoder
        Parameters:
        stream - the output stream to encode data to
        buffer - buffer to read data from
        Throws:
        java.io.IOException - if an I/O error occurs