godot.entrygenerator.exceptions.WrongAnnotationUsageException.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of godot-entry-generator Show documentation
Show all versions of godot-entry-generator Show documentation
Godot Kotlin entry code generator.
The newest version!
package godot.entrygenerator.exceptions
import godot.entrygenerator.model.PropertyHintAnnotation
import godot.entrygenerator.model.RegisteredProperty
class WrongAnnotationUsageException(
registeredProperty: RegisteredProperty,
propertyHintAnnotation: PropertyHintAnnotation?,
effectiveTypes: Set? = null
) : EntryGeneratorException(
"You annotated ${registeredProperty.fqName} with @${propertyHintAnnotation?.let { it::class.qualifiedName }?.substringAfterLast(".")?.removeSuffix("HintAnnotation")} which ${if (effectiveTypes != null) "is only applicable to properties of type $effectiveTypes" else "cannot be applied on properties of type ${registeredProperty.type.fqName}"}"
)