Package org.grails.encoder.impl
Class BasicCodecLookup
java.lang.Object
org.grails.encoder.impl.BasicCodecLookup
- All Implemented Interfaces:
CodecLookup,org.springframework.beans.factory.InitializingBean
public class BasicCodecLookup
extends Object
implements CodecLookup, org.springframework.beans.factory.InitializingBean
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final ConcurrentMap<String,Decoder> protected final ConcurrentMap<String,Encoder> static final StreamingEncoder -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidprotected <T extends CodecIdentifierProvider>
TcreateChainedCodecInstance(String codecName, ConcurrentMap<String, T> map, Class<T> returnType) protected <T extends CodecIdentifierProvider>
TcreateCodec(String codecName, ConcurrentMap<String, T> map, Class<T> returnType) protected Collection<String>createNameVariations(String name, CodecIdentifierProvider target) protected <T extends CodecIdentifierProvider>
TlookupCodec(String codecName, ConcurrentMap<String, T> map, Class<T> returnType) lookupDecoder(String codecName) lookupEncoder(String codecName) protected <T extends CodecIdentifierProvider>
TputChainedCodecInstance(String codecName, ConcurrentMap<String, T> map, T createdInstance) voidregisterCodecFactory(CodecFactory codecFactory) protected voidvoidregisterDecoder(Decoder decoder) voidregisterEncoder(Encoder encoder) protected <T extends CodecIdentifierProvider>
voidregisterVariationsOfName(Map<String, T> destinationMap, T target, String name) protected <T extends CodecIdentifierProvider>
voidregisterWithNameVaritions(Map<String, T> destinationMap, T target) void
-
Field Details
-
NONE_ENCODER
-
encoders
-
decoders
-
-
Constructor Details
-
BasicCodecLookup
public BasicCodecLookup()
-
-
Method Details
-
lookupEncoder
- Specified by:
lookupEncoderin interfaceCodecLookup
-
lookupDecoder
- Specified by:
lookupDecoderin interfaceCodecLookup
-
lookupCodec
protected <T extends CodecIdentifierProvider> T lookupCodec(String codecName, ConcurrentMap<String, T> map, Class<T> returnType) -
createCodec
protected <T extends CodecIdentifierProvider> T createCodec(String codecName, ConcurrentMap<String, T> map, Class<T> returnType) -
putChainedCodecInstance
protected <T extends CodecIdentifierProvider> T putChainedCodecInstance(String codecName, ConcurrentMap<String, T> map, T createdInstance) -
createChainedCodecInstance
protected <T extends CodecIdentifierProvider> T createChainedCodecInstance(String codecName, ConcurrentMap<String, T> map, Class<T> returnType) -
registerWithNameVaritions
protected <T extends CodecIdentifierProvider> void registerWithNameVaritions(Map<String, T> destinationMap, T target) -
registerVariationsOfName
protected <T extends CodecIdentifierProvider> void registerVariationsOfName(Map<String, T> destinationMap, T target, String name) -
createNameVariations
-
registerCodecFactory
-
registerDecoder
-
registerEncoder
-
reInitialize
public void reInitialize() -
registerCodecs
protected void registerCodecs() -
afterPropertiesSet
- Specified by:
afterPropertiesSetin interfaceorg.springframework.beans.factory.InitializingBean- Throws:
Exception
-