org.apache.commons.codec
Interface Encoder
- BinaryEncoder, StringEncoder
- Base64, BCodec, BinaryCodec, DoubleMetaphone, Hex, Metaphone, QCodec, QuotedPrintableCodec, RefinedSoundex, Soundex, URLCodec
Provides the highest level of abstraction for Encoders.
This is the sister interface of
Decoder
. Every implementation of
Encoder provides this common generic interface whic allows a user to pass a
generic Object to any Encoder implementation in the codec package.
$Id: Encoder.java,v 1.10 2004/02/29 04:08:31 tobrien Exp $- Apache Software Foundation
Object | encode(Object pObject) - Encodes an "Object" and returns the encoded content
as an Object.
|
encode
public Object encode(Object pObject)
throws EncoderException
Encodes an "Object" and returns the encoded content
as an Object. The Objects here may just be byte[]
or String
s depending on the implementation used.
pObject
- An object ot encode
EncoderException
- an encoder exception is
thrown if the encoder experiences a failure
condition during the encoding process.
commons-codec version 1.3 - Copyright © 2002-2004 - Apache Software Foundation