@Override public int hashCode() { return (this.getNamespace() + this.getTable() + this.getExtractId()).hashCode(); }
@Override public boolean equals(Object object) { if (!(object instanceof Extract)) { return false; } Extract other = (Extract) object; return super.equals(other) && this.getNamespace().equals(other.getNamespace()) && this.getTable().equals(other.getTable()) && this.getExtractId().equals(other.getExtractId()); }
/** * Get the writer output file path corresponding to this {@link Extract}. * * @return writer output file path corresponding to this {@link Extract} * @deprecated As {@code this.getIsFull} is deprecated. */ @Deprecated public String getOutputFilePath() { return this.getNamespace().replaceAll("\\.", "/") + "/" + this.getTable() + "/" + this.getExtractId() + "_" + (this.getIsFull() ? "full" : "append"); }
@Override public MessageType convertSchema(JsonArray inputSchema, WorkUnitState workUnit) throws SchemaConversionException { String fieldName = workUnit.getExtract().getTable(); JsonSchema jsonSchema = new JsonSchema(inputSchema); jsonSchema.setColumnName(fieldName); recordConverter = new RecordConverter(jsonSchema, ROOT); return (MessageType) recordConverter.schema(); }
if (previousExtract.getNamespace().equals(namespace) && previousExtract.getTable().equals(table)) { this.previousTableState.addAll(pre);
@Override public Schema convertSchema(JsonArray schema, WorkUnitState workUnit) throws SchemaConversionException { try { JsonSchema jsonSchema = new JsonSchema(schema); jsonSchema.setColumnName(workUnit.getExtract().getTable()); recordConverter = new RecordConverter(jsonSchema, workUnit, workUnit.getExtract().getNamespace()); } catch (UnsupportedDateTypeException e) { throw new SchemaConversionException(e); } Schema recordSchema = recordConverter.schema(); if (workUnit .getPropAsBoolean(CONVERTER_AVRO_NULLIFY_FIELDS_ENABLED, DEFAULT_CONVERTER_AVRO_NULLIFY_FIELDS_ENABLED)) { return this.generateSchemaWithNullifiedField(workUnit, recordSchema); } return recordSchema; }
Extract extract = this.getExtract(); table.setNamespace(extract.getNamespace()); table.setName(extract.getTable()); if (extract.hasType()) { table.setType(TableTypeEnum.valueOf(extract.getType().name()));
@Override public boolean equals(Object object) { if (!(object instanceof Extract)) { return false; } Extract other = (Extract) object; return super.equals(other) && this.getNamespace().equals(other.getNamespace()) && this.getTable().equals(other.getTable()) && this.getExtractId().equals(other.getExtractId()); }
@Override public int hashCode() { return (this.getNamespace() + this.getTable() + this.getExtractId()).hashCode(); }
/** * Get the writer output file path corresponding to this {@link Extract}. * * @return writer output file path corresponding to this {@link Extract} * @deprecated As {@code this.getIsFull} is deprecated. */ @Deprecated public String getOutputFilePath() { return this.getNamespace().replaceAll("\\.", "/") + "/" + this.getTable() + "/" + this.getExtractId() + "_" + (this.getIsFull() ? "full" : "append"); }
@Override public MessageType convertSchema(JsonArray inputSchema, WorkUnitState workUnit) throws SchemaConversionException { String fieldName = workUnit.getExtract().getTable(); JsonSchema jsonSchema = new JsonSchema(inputSchema); jsonSchema.setColumnName(fieldName); recordConverter = new RecordConverter(jsonSchema, ROOT); return (MessageType) recordConverter.schema(); }
if (previousExtract.getNamespace().equals(namespace) && previousExtract.getTable().equals(table)) { this.previousTableState.addAll(pre);
@Override public Schema convertSchema(JsonArray schema, WorkUnitState workUnit) throws SchemaConversionException { try { JsonSchema jsonSchema = new JsonSchema(schema); jsonSchema.setColumnName(workUnit.getExtract().getTable()); recordConverter = new RecordConverter(jsonSchema, workUnit, workUnit.getExtract().getNamespace()); } catch (UnsupportedDateTypeException e) { throw new SchemaConversionException(e); } Schema recordSchema = recordConverter.schema(); if (workUnit .getPropAsBoolean(CONVERTER_AVRO_NULLIFY_FIELDS_ENABLED, DEFAULT_CONVERTER_AVRO_NULLIFY_FIELDS_ENABLED)) { return this.generateSchemaWithNullifiedField(workUnit, recordSchema); } return recordSchema; }
Extract extract = this.getExtract(); table.setNamespace(extract.getNamespace()); table.setName(extract.getTable()); if (extract.hasType()) { table.setType(TableTypeEnum.valueOf(extract.getType().name()));