Class AvroSchemaUtil


  • public class AvroSchemaUtil
    extends java.lang.Object
    • Method Detail

      • convert

        public static org.apache.avro.Schema convert​(Schema schema,
                                                     java.lang.String tableName)
      • convert

        public static org.apache.avro.Schema convert​(Schema schema,
                                                     java.util.Map<Types.StructType,​java.lang.String> names)
      • convert

        public static org.apache.avro.Schema convert​(Type type)
      • convert

        public static org.apache.avro.Schema convert​(Types.StructType type,
                                                     java.lang.String name)
      • convert

        public static org.apache.avro.Schema convert​(Type type,
                                                     java.util.Map<Types.StructType,​java.lang.String> names)
      • convert

        public static Type convert​(org.apache.avro.Schema schema)
      • toIceberg

        public static Schema toIceberg​(org.apache.avro.Schema schema)
      • convertTypes

        public static java.util.Map<Type,​org.apache.avro.Schema> convertTypes​(Types.StructType type,
                                                                                    java.lang.String name)
      • pruneColumns

        public static org.apache.avro.Schema pruneColumns​(org.apache.avro.Schema schema,
                                                          java.util.Set<java.lang.Integer> selectedIds,
                                                          NameMapping nameMapping)
      • buildAvroProjection

        public static org.apache.avro.Schema buildAvroProjection​(org.apache.avro.Schema schema,
                                                                 Schema expected,
                                                                 java.util.Map<java.lang.String,​java.lang.String> renames)
      • isTimestamptz

        public static boolean isTimestamptz​(org.apache.avro.Schema schema)
      • isOptionSchema

        public static boolean isOptionSchema​(org.apache.avro.Schema schema)
      • isKeyValueSchema

        public static boolean isKeyValueSchema​(org.apache.avro.Schema schema)
      • getKeyId

        public static int getKeyId​(org.apache.avro.Schema schema)
      • getValueId

        public static int getValueId​(org.apache.avro.Schema schema)
      • getElementId

        public static int getElementId​(org.apache.avro.Schema schema)
      • getFieldId

        public static int getFieldId​(org.apache.avro.Schema.Field field)
      • hasFieldId

        public static boolean hasFieldId​(org.apache.avro.Schema.Field field)
      • makeCompatibleName

        public static java.lang.String makeCompatibleName​(java.lang.String name)