... friends call him Mister Bean... :-)
| Modifier and Type | Class and Description |
|---|---|
| public static enum | AbstractTypeMaterializer.
Enumeration that defines togglable features that guide the serialization feature. |
| pack-priv static class | AbstractTypeMaterializer.
To support actual dynamic loading of bytecode we need a simple custom classloader. |
| Modifier and Type | Field and Description |
|---|---|
| protected final AbstractTypeMaterializer. | _classLoader
We will use per-materializer class loader for now; would be nice to find a way to reduce number of class loaders (and hence number of generated classes!) constructed... |
| protected String | _defaultPackage
Package name to use as prefix for generated classes. |
| protected int | _featureFlags
Bit set that contains all enabled features |
| protected static final int | DEFAULT_FEATURE_FLAGS
Bitfield (set of flags) of all Features that are enabled by default. |
| public static final String | DEFAULT_PACKAGE_FOR_GENERATED
Default package to use for generated classes. |
| Access | Constructor and Description |
|---|---|
| public | |
| public | AbstractTypeMaterializer(ClassLoader
Class loader to use for generated classes; if
null, will use class loader that loaded materializer itself. parentClassLoader)
|
| Modifier and Type | Method and Description |
|---|---|
| protected Class | |
| protected Class | |
| protected boolean | Returns: True if materialization should proceed;false if not.Type that we are asked to materialize type)Overridable helper method called to check if given non-concrete type should be materialized. |
| public void | |
| public void | |
| public final boolean | isEnabled(AbstractTypeMaterializer.
Method for checking whether given feature is enabled or not |
| public Class | |
| public Class | materializeRawType(MapperConfig<?> config, AnnotatedClass typeDef)
Note should not be called for generic types. |
| public JavaType | resolveAbstractType(DeserializationConfig
Configuration in use config, BeanDescription Description of the POJO type to resolve beanDesc)Overrides com. Entry-point for |
| public void | set(AbstractTypeMaterializer.
Method for enabling or disabling specified feature. |
| public void | |
| public Version | version()
Implements com. Method that will return version information stored in and read from jar that contains this class. |
| _classLoader | back to summary |
|---|---|
| protected final AbstractTypeMaterializer. We will use per-materializer class loader for now; would be nice to find a way to reduce number of class loaders (and hence number of generated classes!) constructed... | |
| _defaultPackage | back to summary |
|---|---|
| protected String _defaultPackage Package name to use as prefix for generated classes. | |
| _featureFlags | back to summary |
|---|---|
| protected int _featureFlags Bit set that contains all enabled features | |
| DEFAULT_FEATURE_FLAGS | back to summary |
|---|---|
| protected static final int DEFAULT_FEATURE_FLAGS Bitfield (set of flags) of all Features that are enabled by default. | |
| DEFAULT_PACKAGE_FOR_GENERATED | back to summary |
|---|---|
| public static final String DEFAULT_PACKAGE_FOR_GENERATED Default package to use for generated classes. | |
| AbstractTypeMaterializer | back to summary |
|---|---|
| public AbstractTypeMaterializer() | |
| AbstractTypeMaterializer | back to summary |
|---|---|
public AbstractTypeMaterializer(ClassLoader parentClassLoader)
| |
| _loadAndResolve | back to summary |
|---|---|
| protected Class | |
| _materializeRawType | back to summary |
|---|---|
| protected Class | |
| _suitableType | back to summary |
|---|---|
| protected boolean _suitableType(JavaType type) Overridable helper method called to check if given non-concrete type should be materialized. Default implementation will blocks all
Jackson 2.12 and earlier enumerated a small set of other types under
| |
| disable | back to summary |
|---|---|
| public void disable(AbstractTypeMaterializer. Method for disabling specified feature. | |
| enable | back to summary |
|---|---|
| public void enable(AbstractTypeMaterializer. Method for enabling specified feature. | |
| isEnabled | back to summary |
|---|---|
| public final boolean isEnabled(AbstractTypeMaterializer. Method for checking whether given feature is enabled or not | |
| materializeGenericType | back to summary |
|---|---|
public Class
| |
| materializeRawType | back to summary |
|---|---|
| public Class Note should not be called for generic types.
| |
| resolveAbstractType | back to summary |
|---|---|
| public JavaType resolveAbstractType(DeserializationConfig config, BeanDescription beanDesc) Overrides com. Entry-point for
| |
| set | back to summary |
|---|---|
| public void set(AbstractTypeMaterializer. Method for enabling or disabling specified feature. | |
| setDefaultPackage | back to summary |
|---|---|
| public void setDefaultPackage(String defPkg) Method for specifying package to use for generated classes. | |
| version | back to summary |
|---|---|
| public Version version() Implements com. Method that will return version information stored in and read from jar that contains this class.
| |
| Modifier and Type | Field and Description |
|---|---|
| pack-priv final boolean | |
| public static final AbstractTypeMaterializer. | FAIL_ON_NON_PUBLIC_TYPES
Feature that determines what happens when attempt is made to generate implementation of non-public class or interface. |
| public static final AbstractTypeMaterializer. | FAIL_ON_UNMATERIALIZED_METHOD
Feature that determines what happens if an "unrecognized" (non-getter, non-setter) abstract method is encountered: if set to true, will throw an exception during materialization; if false, will materialize method that throws exception only if called. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| protected static int | |
| public boolean | |
| public int | |
| public static AbstractTypeMaterializer. | |
| public static AbstractTypeMaterializer. |
| _defaultState | back to summary |
|---|---|
| pack-priv final boolean _defaultState | |
| FAIL_ON_NON_PUBLIC_TYPES | back to summary |
|---|---|
| public static final AbstractTypeMaterializer. Feature that determines what happens when attempt is made to generate implementation of non-public class or interface. If true, an exception is thrown; if false, will just quietly ignore attempts. | |
| FAIL_ON_UNMATERIALIZED_METHOD | back to summary |
|---|---|
| public static final AbstractTypeMaterializer. Feature that determines what happens if an "unrecognized" (non-getter, non-setter) abstract method is encountered: if set to true, will throw an exception during materialization; if false, will materialize method that throws exception only if called. | |
| Feature | back to summary |
|---|---|
| private Feature(boolean defaultState) | |
| collectDefaults | back to summary |
|---|---|
| protected static int collectDefaults() | |
| enabledByDefault | back to summary |
|---|---|
| public boolean enabledByDefault() | |
| getMask | back to summary |
|---|---|
| public int getMask() | |
| valueOf | back to summary |
|---|---|
| public static AbstractTypeMaterializer. | |
| values | back to summary |
|---|---|
| public static AbstractTypeMaterializer. | |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public Class | loadAndResolve(String className, byte[] byteCode, Class<?>
Interface or abstract class that class to load should extend or
implement targetClass)
|
| MyClassLoader | back to summary |
|---|---|
| public MyClassLoader(ClassLoader parent) | |
| loadAndResolve | back to summary |
|---|---|
public Class
| |