ToOneRelationship
annotation class ToOneRelationship(val name: String, val resourceType: KClass<*>, val canBeEmpty: Boolean = false, val propertyName: String = "")(source)
Annotates a class representing a to-one relationship in a JSON:API resource.
Parameters
name
The name of the relationship.
resourceType
The type of the related resource.
canBeEmpty
If the relationship can have an empty value.
propertyName
The name of the property in the class. Defaults to the name of the relationship.