Class TypeConversion.UUIDConversion

  • All Implemented Interfaces:
    TypeConversion<java.util.UUID>
    Enclosing interface:
    TypeConversion<T>

    public static class TypeConversion.UUIDConversion
    extends java.lang.Object
    implements TypeConversion<java.util.UUID>
    Converts either String or Utf8 to UUID.
    • Constructor Detail

      • UUIDConversion

        public UUIDConversion()
    • Method Detail

      • convert

        public java.util.UUID convert​(org.apache.avro.Schema fieldSchema,
                                      @NotNull
                                      java.lang.Object fieldValue)
        Description copied from interface: TypeConversion
        Convert value from the source type to the target type. Runtime exceptions are thrown on invalid argument or conversion failure.
        Specified by:
        convert in interface TypeConversion<java.util.UUID>
        Parameters:
        fieldSchema - avro schema to loop up the source schema
        fieldValue - value in the source type. The value cannot be null.
        Returns:
        the converted value