Polymorphic

Marker interface indicating the EntitySchema is polymorphic base. The marker is useless if schema is not EntitySchema.

Example:

// Base schema 'interface' does not have Polymorphic marker.
// It only declares base schema keys and should be abstract
sealed class BaseSchema(name: String): EntitySchema(name) {
val baseKey by dynoKey<String>()

// notice the Polymorphic marker
companion object: Vehicle("base"), Polymorphic
}

object DerivedSchema1: BaseSchema("derived1")
object DerivedSchema2: BaseSchema("derived2")

Functions

Link copied to clipboard

Returns a new DynoSchema that includes all properties from both the original schema and the other schema. If there are conflicting property names between the two schemas, an exception is thrown.

Link copied to clipboard
abstract fun getKey(serializersModule: SerializersModule, name: String): <Error class: unknown class><out <Error class: unknown class>>?

Retrieves a DynoKey instance corresponding to the given key name within the specified SerializersModule, or null if not found.

Link copied to clipboard
open fun keyCount(): Int

Number of keys registered in this schema

Link copied to clipboard
abstract fun keys(): Collection<<Error class: unknown class><out <Error class: unknown class>>>
Link copied to clipboard
abstract fun name(): String
Link copied to clipboard
abstract fun version(): Int