| Package | Description |
|---|---|
| com.at.avro | |
| com.at.avro.config | |
| com.at.avro.types |
| Modifier and Type | Method and Description |
|---|---|
List<AvroSchema> |
DbSchemaExtractor.getAll(AvroConfig avroConfig)
Returns all AvroSchemas that are present in a target DB
|
List<AvroSchema> |
DbSchemaExtractor.getForSchema(AvroConfig avroConfig,
String dbSchemaName)
Returns all AvroSchemas that are present in given DB schema
|
AvroSchema |
DbSchemaExtractor.getForTable(AvroConfig avroConfig,
String dbSchemaName,
String tableName)
Returns AvroSchema for a specific table.
|
List<AvroSchema> |
DbSchemaExtractor.getForTables(AvroConfig avroConfig,
String dbSchemaName,
String... tableNames)
Returns AvroSchemas for each of given tables
Note: when you have a schema with a large amount of tables but are only interested in a few of them,
consider calling getForTable() several times (separately for every table).
|
| Constructor and Description |
|---|
AvroField(schemacrawler.schema.Column column,
AvroConfig avroConfig) |
AvroSchema(schemacrawler.schema.Table table,
AvroConfig avroConfig) |
| Modifier and Type | Method and Description |
|---|---|
AvroConfig |
AvroConfig.setAllFieldsDefaultNull(boolean allFieldsDefaultNull)
Set to true to make all fields default to null.
|
AvroConfig |
AvroConfig.setAvroSchemaPostProcessor(java.util.function.BiConsumer<AvroSchema,schemacrawler.schema.Table> avroSchemaPostProcessor)
Set a callback that will be called after avro model was built.
|
AvroConfig |
AvroConfig.setDateTypeClass(Class<?> dateTypeClass)
Sets a "java-class" property in this fields definition.
|
AvroConfig |
AvroConfig.setDecimalTypeClass(Class<?> decimalTypeClass)
Sets a "java-class" property in this fields definition.
|
AvroConfig |
AvroConfig.setFieldNameMapper(java.util.function.Function<String,String> fieldNameMapper)
Provide custom field names resolver function which takes DB column name as an input.
|
AvroConfig |
AvroConfig.setNullableTrueByDefault(boolean nullableTrueByDefault)
Set to true to make all fields nullable in avro schema.
|
AvroConfig |
AvroConfig.setRepresentEnumsAsStrings(boolean representEnumsAsStrings)
Resolve 'enum' type to 'string' instead of 'enum'.
|
AvroConfig |
AvroConfig.setSchemaNameMapper(java.util.function.Function<String,String> schemaNameMapper)
Provide custom schema name resolver function which takes DB table name as an input.
|
AvroConfig |
AvroConfig.setUnknownTypeResolver(java.util.function.Function<String,String> unknownTypeResolver)
Provide mapper for unknown db types.
|
AvroConfig |
AvroConfig.setUseSqlCommentsAsDoc(boolean useSqlCommentsAsDoc)
Set to true to use SQL comments at table and field level as optional avro doc fields.
|
| Constructor and Description |
|---|
Date(schemacrawler.schema.Column column,
AvroConfig config) |
Decimal(schemacrawler.schema.Column column,
AvroConfig config) |
Copyright © 2021. All rights reserved.