|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.fasterxml.jackson.databind.util.NameTransformer
public abstract class NameTransformer
Helper class used to encapsulate details of name mangling, transforming of names using different strategies (prefixes, suffixes). Default implementation is "no-operation" (aka identity transformation).
Nested Class Summary | |
---|---|
static class |
NameTransformer.Chained
|
Field Summary | |
---|---|
static NameTransformer |
NOP
Singleton "no-operation" transformer which simply returns given name as is. |
Constructor Summary | |
---|---|
protected |
NameTransformer()
|
Method Summary | |
---|---|
static NameTransformer |
chainedTransformer(NameTransformer t1,
NameTransformer t2)
Method that constructs transformer that applies given transformers as a sequence; essentially combines separate transform operations into one logical transformation. |
abstract String |
reverse(String transformed)
Method called when reversal of transformation is needed; should return null if this is not possible, that is, given name can not have been result of calling transform(java.lang.String) of this object. |
static NameTransformer |
simpleTransformer(String prefix,
String suffix)
Factory method for constructing a simple transformer based on prefix and/or suffix. |
abstract String |
transform(String name)
Method called when (forward) transformation is needed. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final NameTransformer NOP
Constructor Detail |
---|
protected NameTransformer()
Method Detail |
---|
public static NameTransformer simpleTransformer(String prefix, String suffix)
public static NameTransformer chainedTransformer(NameTransformer t1, NameTransformer t2)
public abstract String transform(String name)
public abstract String reverse(String transformed)
transform(java.lang.String)
of this object.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |