public class ClassNameCodec extends EntropicStringSetCodec
EntropicStringSetCodec
that
is tailored specifically for mapping (fully qualified) class names.CodecFactory
Modifier and Type | Method and Description |
---|---|
void |
add(Class<?> cls)
Convenience method to add the class name of the given class to
the mappings.
|
void |
add(Object o)
Convenience method to add the class name of the class of the
given object to the mappings.
|
String |
encode(Class<?> cls)
Convenience method to return the encoded value for the given class.
|
String |
encode(Object o)
Convenience method to return the encoded value of the class of the
given object.
|
add, addAll
decode, encode, equals, hashCode, size, toDebugString, toEncodedString, toString, valueOf
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
decode, encode, size
public void add(Class<?> cls)
cls
- the classpublic void add(Object o)
o
- the object instance whose class name should be addedpublic String encode(Class<?> cls)
cls
- the class to encodeCopyright © 2015. All Rights Reserved.