Skip to content

Commit babff8e

Browse files
committed
Fix Kotlin example for dependency injection with static factory method
Closes gh-28589
1 parent 290cc73 commit babff8e

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/docs/asciidoc/core/core-beans.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1427,6 +1427,7 @@ The following example shows the corresponding `ExampleBean` class:
14271427
// a static factory method; the arguments to this method can be
14281428
// considered the dependencies of the bean that is returned,
14291429
// regardless of how those arguments are actually used.
1430+
@JvmStatic
14301431
fun createInstance(anotherBean: AnotherBean, yetAnotherBean: YetAnotherBean, i: Int): ExampleBean {
14311432
val eb = ExampleBean (...)
14321433
// some other operations...

0 commit comments

Comments
 (0)