Class PatentAssertionSerializer

java.lang.Object
com.fasterxml.jackson.databind.JsonSerializer<PatentAssertion>
org.cyclonedx.util.serializer.PatentAssertionSerializer
All Implemented Interfaces:
com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitable

public class PatentAssertionSerializer extends com.fasterxml.jackson.databind.JsonSerializer<PatentAssertion>
Custom serializer for PatentAssertion that handles the bom-ref attribute/element name conflict in XML. In XML, "bom-ref" appears as both an attribute on <patentAssertion> and as child elements inside <patentRefs>. Jackson XML cannot distinguish these, so this serializer handles the XML output manually.
  • Nested Class Summary

    Nested classes/interfaces inherited from class com.fasterxml.jackson.databind.JsonSerializer

    com.fasterxml.jackson.databind.JsonSerializer.None
  • Constructor Summary

    Constructors
    Constructor
    Description
     
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    serialize(PatentAssertion value, com.fasterxml.jackson.core.JsonGenerator gen, com.fasterxml.jackson.databind.SerializerProvider provider)
     

    Methods inherited from class com.fasterxml.jackson.databind.JsonSerializer

    acceptJsonFormatVisitor, getDelegatee, handledType, isEmpty, isEmpty, isUnwrappingSerializer, properties, replaceDelegatee, serializeWithType, unwrappingSerializer, usesObjectId, withFilterId, withIgnoredProperties

    Methods inherited from class Object

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

    • PatentAssertionSerializer

      public PatentAssertionSerializer()
    • PatentAssertionSerializer

      public PatentAssertionSerializer(Version version)
  • Method Details

    • serialize

      public void serialize(PatentAssertion value, com.fasterxml.jackson.core.JsonGenerator gen, com.fasterxml.jackson.databind.SerializerProvider provider) throws IOException
      Specified by:
      serialize in class com.fasterxml.jackson.databind.JsonSerializer<PatentAssertion>
      Throws:
      IOException