com.fasterxml.jackson.databind.cfg

Class ConstructorDetector

  • All Implemented Interfaces:
    Serializable


    public final class ConstructorDetector
    extends Object
    implements Serializable
    Configurable handler used to select aspects of selecting constructor to use as "Creator" for POJOs. Defines the API for handlers, a pre-defined set of standard instances and methods for constructing alternative configurations.
    Since:
    2.12
    See Also:
    Serialized Form
    • Method Detail

      • withAllowJDKTypeConstructors

        public ConstructorDetector withAllowJDKTypeConstructors(boolean state)
      • requireCtorAnnotation

        public boolean requireCtorAnnotation()
      • allowJDKTypeConstructors

        public boolean allowJDKTypeConstructors()
      • singleArgCreatorDefaultsToDelegating

        public boolean singleArgCreatorDefaultsToDelegating()
      • singleArgCreatorDefaultsToProperties

        public boolean singleArgCreatorDefaultsToProperties()
      • shouldIntrospectorImplicitConstructors

        public boolean shouldIntrospectorImplicitConstructors(Class<?> rawType)
        Accessor that combines checks for whether implicit creators are allowed and, if so, whether JDK type constructors are allowed (if type is JDK type) to determine whether implicit constructor detection should be enabled for given type or not.
        Parameters:
        rawType - Value type to consider
        Returns:
        True if implicit constructor detection should be enabled; false if not

Copyright © 2008–2021 FasterXML. All rights reserved.