Read field from parent node in custom Jackson Deserializer Read field from parent node in custom Jackson Deserializer json json

Read field from parent node in custom Jackson Deserializer


You can access it through the DeserializationContext like so

Object parent = dc.getParser().getParsingContext().getCurrentValue();

Then cast it to the appropriate POJO type that has the 'importantKey' field.