This commit extract spring-related links and recurring external links into asciidoctor attributes to be used by the Antora toolchain. It notably homogenizes links to: - IETF RFCs - Java Community Process JSRs - the Java API Documentation (on the Java 17 version) - Kotlin documentations (on the Kotlinlang.org version) - the Spring Boot reference guide (on the `html` version) This commit also reworks most link attributes to follow a Project-Category-Misc syntax. For example, `spring-boot-docs` rather than `docs-spring-boot`. Finally, it makes an effort to clean up remainders from the previous documentation toolchain, namely the `docs/asciidoc` folder and `modules/ROOT/pages/attributes.adoc` file. Closes gh-26864 Closes gh-31619
21 lines
860 B
Plaintext
21 lines
860 B
Plaintext
[[kotlin-classes-interfaces]]
|
|
= Classes and Interfaces
|
|
:page-section-summary-toc: 1
|
|
|
|
The Spring Framework supports various Kotlin constructs, such as instantiating Kotlin classes
|
|
through primary constructors, immutable classes data binding, and function optional parameters
|
|
with default values.
|
|
|
|
Kotlin parameter names are recognized through a dedicated `KotlinReflectionParameterNameDiscoverer`,
|
|
which allows finding interface method parameter names without requiring the Java 8 `-parameters`
|
|
compiler flag to be enabled during compilation. (For completeness, we nevertheless recommend
|
|
running the Kotlin compiler with its `-java-parameters` flag for standard Java parameter exposure.)
|
|
|
|
You can declare configuration classes as
|
|
{kotlin-docs}/nested-classes.html[top level or nested but not inner],
|
|
since the later requires a reference to the outer class.
|
|
|
|
|
|
|
|
|