Package-level declarations

Types

Link copied to clipboard
internal data class ClasspathScanResult(val enums: List<KtEnumInfo>, val composites: List<KtCompositeInfo>, val dynamicSerializers: Map<String, KSerializer<Any>>, val dynamicReverseMap: Map<KClass<*>, String>)

Result of classpath scanning for type annotations.

Link copied to clipboard
internal class ClasspathTypeScanner(packagesToScan: List<String>)

Scans the classpath for type mapping annotations.

Link copied to clipboard
internal data class DatabaseScanResult(val enums: Map<String, Map<String, Triple<Int, Int, List<String>>>>, val composites: Map<String, Map<String, Triple<Int, Int, Map<String, Int>>>>, val allOidNames: Map<Int, String>)

Result of database scanning for PostgreSQL type definitions.

Link copied to clipboard
internal class DatabaseTypeScanner(jdbcTemplate: JdbcTemplate, dbSchemas: List<String>)

Scans PostgreSQL database for type definitions.

Link copied to clipboard
internal data class KtCompositeInfo(val kClass: KClass<*>, val pgName: String, val schema: String, val mapperClass: KClass<out PgCompositeMapper<*>>? = null)

Information about a Kotlin data class annotated with @PgComposite.

Link copied to clipboard
internal data class KtEnumInfo(val kClass: KClass<*>, val pgName: String, val schema: String, val pgConvention: CaseConvention, val kotlinConvention: CaseConvention)

Information about a Kotlin enum annotated with @PgEnum.

Link copied to clipboard
internal data class PgArrayDefinition(val oid: Int, val typeName: String, val elementOid: Int)

Metadata for a PostgreSQL ARRAY type, linking to its element type.

Link copied to clipboard
internal data class PgCompositeDefinition(val oid: Int, val typeName: String, val attributes: Map<String, Int>, val kClass: KClass<*>, val mapper: PgCompositeMapper<Any>? = null)

Metadata for a PostgreSQL COMPOSITE type with ordered attribute definitions.

Link copied to clipboard
internal data class PgEnumDefinition(val oid: Int, val typeName: String, val valueToEnumMap: Map<String, Enum<*>>, val kClass: KClass<out Enum<*>>)

Metadata for a PostgreSQL ENUM type, enabling bidirectional value mapping.

Link copied to clipboard
internal enum TypeCategory : Enum<TypeCategory>

Classification of PostgreSQL types for routing to appropriate converters.

Link copied to clipboard
internal class TypeRegistry(oidCategoryMap: Map<Int, TypeCategory>, enumsByOid: Map<Int, PgEnumDefinition>, compositesByOid: Map<Int, PgCompositeDefinition>, arraysByOid: Map<Int, PgArrayDefinition>, classToPgNameMap: Map<KClass<*>, QualifiedName>, dynamicSerializers: Map<String, KSerializer<Any>>, classToDynamicNameMap: Map<KClass<*>, String>, pgNameToOidMap: Map<QualifiedName, Int>, oidToNameMap: Map<Int, String>)

Central repository of PostgreSQL type metadata for bidirectional conversion.

Link copied to clipboard
internal class TypeRegistryLoader(jdbcTemplate: JdbcTemplate, packagesToScan: List<String>, dbSchemas: List<String>)

Orchestrates TypeRegistry initialization by coordinating classpath and database scanning, then merging and validating the results.