Class EntitySchemaNameDeserializer

java.lang.Object
org.gcube.com.fasterxml.jackson.databind.JsonDeserializer<EntitySchema>
org.gcube.informationsystem.types.impl.relations.EntitySchemaNameDeserializer
All Implemented Interfaces:
org.gcube.com.fasterxml.jackson.databind.deser.ContextualDeserializer

public class EntitySchemaNameDeserializer extends org.gcube.com.fasterxml.jackson.databind.JsonDeserializer<EntitySchema> implements org.gcube.com.fasterxml.jackson.databind.deser.ContextualDeserializer
Deserializes an EntitySchema reference from either a flat type-name string or a legacy nested JSON object representation.
  • Nested Class Summary

    Nested classes/interfaces inherited from class org.gcube.com.fasterxml.jackson.databind.JsonDeserializer

    org.gcube.com.fasterxml.jackson.databind.JsonDeserializer.None
  • Constructor Summary

    Constructors
    Constructor
    Description
    Default constructor.
    Constructs a new deserializer targeting the given entity schema class.
  • Method Summary

    Modifier and Type
    Method
    Description
    org.gcube.com.fasterxml.jackson.databind.JsonDeserializer<?>
    createContextual(org.gcube.com.fasterxml.jackson.databind.DeserializationContext ctxt, org.gcube.com.fasterxml.jackson.databind.BeanProperty property)
     
    deserialize(org.gcube.com.fasterxml.jackson.core.JsonParser p, org.gcube.com.fasterxml.jackson.databind.DeserializationContext ctxt)
     
    deserializeWithType(org.gcube.com.fasterxml.jackson.core.JsonParser p, org.gcube.com.fasterxml.jackson.databind.DeserializationContext ctxt, org.gcube.com.fasterxml.jackson.databind.jsontype.TypeDeserializer typeDeserializer)
     

    Methods inherited from class org.gcube.com.fasterxml.jackson.databind.JsonDeserializer

    deserialize, findBackReference, getDelegatee, getEmptyValue, getEmptyValue, getKnownPropertyNames, getNullValue, getNullValue, getObjectIdReader, handledType, isCachable, replaceDelegatee, unwrappingDeserializer

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • EntitySchemaNameDeserializer

      public EntitySchemaNameDeserializer()
      Default constructor.
    • EntitySchemaNameDeserializer

      public EntitySchemaNameDeserializer(Class<?> targetClass)
      Constructs a new deserializer targeting the given entity schema class.
      Parameters:
      targetClass - the target entity schema class
  • Method Details

    • createContextual

      public org.gcube.com.fasterxml.jackson.databind.JsonDeserializer<?> createContextual(org.gcube.com.fasterxml.jackson.databind.DeserializationContext ctxt, org.gcube.com.fasterxml.jackson.databind.BeanProperty property)
      Specified by:
      createContextual in interface org.gcube.com.fasterxml.jackson.databind.deser.ContextualDeserializer
    • deserializeWithType

      public Object deserializeWithType(org.gcube.com.fasterxml.jackson.core.JsonParser p, org.gcube.com.fasterxml.jackson.databind.DeserializationContext ctxt, org.gcube.com.fasterxml.jackson.databind.jsontype.TypeDeserializer typeDeserializer) throws IOException
      Overrides:
      deserializeWithType in class org.gcube.com.fasterxml.jackson.databind.JsonDeserializer<EntitySchema>
      Throws:
      IOException
    • deserialize

      public EntitySchema deserialize(org.gcube.com.fasterxml.jackson.core.JsonParser p, org.gcube.com.fasterxml.jackson.databind.DeserializationContext ctxt) throws IOException
      Specified by:
      deserialize in class org.gcube.com.fasterxml.jackson.databind.JsonDeserializer<EntitySchema>
      Throws:
      IOException