Class UnionByNameVisitor

  • public class UnionByNameVisitor
    extends SchemaWithPartnerVisitor<java.lang.Integer,​java.lang.Boolean>
    Visitor class that accumulates the set of changes needed to evolve an existing schema into the union of the existing and a new schema. Changes are added to an UpdateSchema operation.
    • Method Detail

      • visit

        public static void visit​(UpdateSchema api,
                                 Schema existingSchema,
                                 Schema newSchema)
        Adds changes needed to produce a union of two schemas to an UpdateSchema operation.

        Changes are accumulated to evolve the existingSchema into a union with newSchema.

        api - an UpdateSchema for adding changes
        existingSchema - an existing schema
        newSchema - a new schema to compare with the existing
      • struct

        public java.lang.Boolean struct​(Types.StructType struct,
                                        java.lang.Integer partnerId,
                                        java.util.List<java.lang.Boolean> missingPositions)
        struct in class SchemaWithPartnerVisitor<java.lang.Integer,​java.lang.Boolean>
      • list

        public java.lang.Boolean list​(Types.ListType list,
                                      java.lang.Integer partnerId,
                                      java.lang.Boolean isElementMissing)
        list in class SchemaWithPartnerVisitor<java.lang.Integer,​java.lang.Boolean>
      • map

        public java.lang.Boolean map​(Types.MapType map,
                                     java.lang.Integer partnerId,
                                     java.lang.Boolean isKeyMissing,
                                     java.lang.Boolean isValueMissing)
        map in class SchemaWithPartnerVisitor<java.lang.Integer,​java.lang.Boolean>