com.fasterxml.jackson.databind.deser.std

## Class NumberDeserializers.PrimitiveOrWrapperDeserializer<T>

- java.lang.Object
- - com.fasterxml.jackson.databind.JsonDeserializer<T>
  - - com.fasterxml.jackson.databind.deser.std.StdDeserializer<T>
    - - com.fasterxml.jackson.databind.deser.std.StdScalarDeserializer<T>
      - - com.fasterxml.jackson.databind.deser.std.NumberDeserializers.PrimitiveOrWrapperDeserializer<T>

- All Implemented Interfaces:
    Serializable
  Direct Known Subclasses:
    NumberDeserializers.BooleanDeserializer, NumberDeserializers.ByteDeserializer, NumberDeserializers.CharacterDeserializer, NumberDeserializers.DoubleDeserializer, NumberDeserializers.FloatDeserializer, NumberDeserializers.IntegerDeserializer, NumberDeserializers.LongDeserializer, NumberDeserializers.ShortDeserializer
  Enclosing class:
    NumberDeserializers

      protected abstract static class NumberDeserializers.PrimitiveOrWrapperDeserializer<T>
      extends StdScalarDeserializer<T>

  See Also:
    Serialized Form

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from class com.fasterxml.jackson.databind.JsonDeserializer

      `JsonDeserializer.None`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected T` | `_nullValue`
    `protected boolean` | `_primitive`

    - ### Fields inherited from class com.fasterxml.jackson.databind.deser.std.StdDeserializer

      `_valueClass, F_MASK_INT_COERCIONS`

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `PrimitiveOrWrapperDeserializer(Class<T> vc, T nvl)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `T` | `getNullValue()` Deprecated.
    `T` | `getNullValue(DeserializationContext ctxt)` Method that can be called to determine value to be used for representing null values (values deserialized when JSON token is `JsonToken.VALUE_NULL`).

    - ### Methods inherited from class com.fasterxml.jackson.databind.deser.std.StdScalarDeserializer

      `deserializeWithType`

    - ### Methods inherited from class com.fasterxml.jackson.databind.deser.std.StdDeserializer

      `_coerceIntegral, _deserializeFromEmpty, _failDoubleToIntCoercion, _hasTextualNull, _isIntNumber, _isNaN, _isNegInf, _isPosInf, _parseBoolean, _parseBooleanFromNumber, _parseBooleanPrimitive, _parseByte, _parseDate, _parseDouble, _parseDoublePrimitive, _parseFloat, _parseFloatPrimitive, _parseInteger, _parseIntPrimitive, _parseLong, _parseLongPrimitive, _parseShort, _parseShortPrimitive, _parseString, findConvertingContentDeserializer, findDeserializer, getValueClass, getValueType, handledType, handleUnknownProperty, isDefaultDeserializer, isDefaultKeyDeserializer, parseDouble`

    - ### Methods inherited from class com.fasterxml.jackson.databind.JsonDeserializer

      `deserialize, deserialize, findBackReference, getDelegatee, getEmptyValue, getEmptyValue, getKnownPropertyNames, getObjectIdReader, isCachable, replaceDelegatee, unwrappingDeserializer`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### _nullValue

          protected final T _nullValue

    - #### _primitive

          protected final boolean _primitive

  - ### Constructor Detail

    - #### PrimitiveOrWrapperDeserializer

          protected PrimitiveOrWrapperDeserializer(Class<T> vc,
                                                   T nvl)

  - ### Method Detail

    - #### getNullValue

          public final T getNullValue(DeserializationContext ctxt)
                               throws JsonMappingException

      Description copied from class: `JsonDeserializer`
      Method that can be called to determine value to be used for representing null values (values deserialized when JSON token is `JsonToken.VALUE_NULL`). Usually this is simply Java null, but for some types (especially primitives) it may be necessary to use non-null values.

      Since version 2.6 (in which the context argument was added), call is expected to be made each and every time a null token needs to be handled.

      Default implementation simply returns null.

      Overrides:
        `getNullValue` in class `JsonDeserializer<T>`
      Throws:
        `JsonMappingException`

    - #### getNullValue

          @Deprecated
          public final T getNullValue()

      Deprecated.
      Overrides:
        `getNullValue` in class `JsonDeserializer<T>`

Copyright © 2014–2015 FasterXML. All rights reserved.