@Override public boolean equals(Object other) { if (!(other instanceof Type) || other == null) { return false; } return equals((Type)other); }
@Override public boolean equals(Object other) { if (!(other instanceof Type) || other == null) { return false; } return equals((Type)other); }
/** * {@inheritDoc} */ @Override protected boolean equals(Type otherType) { return !otherType.isPrimitive() && super.equals(otherType) && Objects.equals(getLogicalTypeAnnotation(),otherType.getLogicalTypeAnnotation()) && getFields().equals(otherType.asGroupType().getFields()); }
/** * {@inheritDoc} */ @Override protected boolean equals(Type otherType) { return !otherType.isPrimitive() && super.equals(otherType) && getOriginalType() == otherType.getOriginalType() && getFields().equals(otherType.asGroupType().getFields()); }
/** * {@inheritDoc} */ @Override protected boolean equals(Type other) { if (!other.isPrimitive()) { return false; } PrimitiveType otherPrimitive = other.asPrimitiveType(); return super.equals(other) && primitive == otherPrimitive.getPrimitiveTypeName() && length == otherPrimitive.length && columnOrder.equals(otherPrimitive.columnOrder) && eqOrBothNull(decimalMeta, otherPrimitive.decimalMeta); }
/** * {@inheritDoc} */ @Override protected boolean equals(Type other) { if (!other.isPrimitive()) { return false; } PrimitiveType otherPrimitive = other.asPrimitiveType(); return super.equals(other) && primitive == otherPrimitive.getPrimitiveTypeName() && length == otherPrimitive.length && columnOrder.equals(otherPrimitive.columnOrder) && eqOrBothNull(decimalMeta, otherPrimitive.decimalMeta); }
private ConvertedField visitListLike(ThriftField listLike, State state, boolean isSet) { State childState = new State(state.path, REPEATED, state.name + "_tuple"); ConvertedField converted = listLike.getType().accept(this, childState); if (converted.isKeep()) { // doProjection prevents an infinite recursion here if (isSet && doProjection) { ConvertedField fullConv = listLike .getType() .accept(new ThriftSchemaConvertVisitor(FieldProjectionFilter.ALL_COLUMNS, false, keepOneOfEachUnion), childState); if (!converted.asKeep().getType().equals(fullConv.asKeep().getType())) { throw new ThriftProjectionException("Cannot select only a subset of the fields in a set, " + "for path " + state.path); } } return new Keep(state.path, listType(state.repetition, state.name, converted.asKeep().getType())); } return new Drop(state.path); }
.accept(new ThriftSchemaConvertVisitor(FieldProjectionFilter.ALL_COLUMNS, false, keepOneOfEachUnion), keyState); if (!fullConvKey.asKeep().getType().equals(convertedKey.asKeep().getType())) { throw new ThriftProjectionException("Cannot select only a subset of the fields in a map key, " + "for path " + state.path);