Top Description Methods
com.google.auto.value.extension.serializable.serializer.interfaces

public Interface SerializerFactory

Known Direct Implementers
com.google.auto.value.extension.serializable.serializer.impl.SerializerFactoryImpl
Imports
com.squareup.javapoet.CodeBlock, javax.lang.model.type.TypeMirror

A factory that returns a Serializer for any given TypeMirror.

Defaults to an identity serializer if no SerializerExtensions are suitable.

Method Summary

Modifier and TypeMethod and Description
public Serializer
getSerializer(javax.lang.model.type.TypeMirror type)

Returns a Serializer for the given TypeMirror.

public default CodeBlock
newIdentifier(String prefix)

Returns an identifier beginning with the given prefix and that is distinct from any identifier returned by another call to this method.

Method Detail

getSerializerback to summary
public Serializer getSerializer(javax.lang.model.type.TypeMirror type)

Returns a Serializer for the given TypeMirror.

newIdentifierback to summary
public default CodeBlock newIdentifier(String prefix)

Returns an identifier beginning with the given prefix and that is distinct from any identifier returned by another call to this method. The returned identifier will contain a $, which should also mean it is distinct from identifiers in user code that are in scope.

The default implementation of this method throws UnsupportedOperationException for compatibility reasons.