Package org.eclipse.yasson.internal
Class ComponentMatcher
- java.lang.Object
-
- org.eclipse.yasson.internal.ComponentMatcher
-
public class ComponentMatcher extends java.lang.Object
Searches for a registered components or Serializer for a given type.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Optional<AdapterBinding>
getDeserializeAdapterBinding(java.lang.reflect.Type propertyRuntimeType, ComponentBoundCustomization customization)
Get components from property model (if declared by annotation and runtime type matches), or return components searched by runtime type.java.util.Optional<DeserializerBinding<?>>
getDeserializerBinding(java.lang.reflect.Type propertyRuntimeType, ComponentBoundCustomization customization)
Lookup deserializer binding for a given property runtime type.java.util.Optional<AdapterBinding>
getSerializeAdapterBinding(java.lang.reflect.Type propertyRuntimeType, ComponentBoundCustomization customization)
Get components from property model (if declared by annotation and runtime type matches), or return components searched by runtime type.java.util.Optional<SerializerBinding<?>>
getSerializerBinding(java.lang.reflect.Type propertyRuntimeType, ComponentBoundCustomization customization)
Lookup serializer binding for a given property runtime type.
-
-
-
Method Detail
-
getSerializerBinding
public java.util.Optional<SerializerBinding<?>> getSerializerBinding(java.lang.reflect.Type propertyRuntimeType, ComponentBoundCustomization customization)
Lookup serializer binding for a given property runtime type.- Parameters:
propertyRuntimeType
- runtime type of a propertycustomization
- with component info- Returns:
- serializer optional
-
getDeserializerBinding
public java.util.Optional<DeserializerBinding<?>> getDeserializerBinding(java.lang.reflect.Type propertyRuntimeType, ComponentBoundCustomization customization)
Lookup deserializer binding for a given property runtime type.- Parameters:
propertyRuntimeType
- runtime type of a propertycustomization
- customization with component info- Returns:
- serializer optional
-
getSerializeAdapterBinding
public java.util.Optional<AdapterBinding> getSerializeAdapterBinding(java.lang.reflect.Type propertyRuntimeType, ComponentBoundCustomization customization)
Get components from property model (if declared by annotation and runtime type matches), or return components searched by runtime type.- Parameters:
propertyRuntimeType
- runtime type not nullcustomization
- customization with component info- Returns:
- components info if present
-
getDeserializeAdapterBinding
public java.util.Optional<AdapterBinding> getDeserializeAdapterBinding(java.lang.reflect.Type propertyRuntimeType, ComponentBoundCustomization customization)
Get components from property model (if declared by annotation and runtime type matches), or return components searched by runtime type.- Parameters:
propertyRuntimeType
- runtime type not nullcustomization
- customization with component info- Returns:
- components info if present
-
-