Skip to content

Update FactoryBean generic description in ref docs #26758

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/docs/asciidoc/core/core-beans.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -4539,14 +4539,14 @@ Java as opposed to a (potentially) verbose amount of XML, you can create your ow
`FactoryBean`, write the complex initialization inside that class, and then plug your
custom `FactoryBean` into the container.

The `FactoryBean` interface provides three methods:
The `FactoryBean<T>` interface provides three methods:

* `Object getObject()`: Returns an instance of the object this factory creates. The
* `T getObject()`: Returns an instance of the object this factory creates. The
instance can possibly be shared, depending on whether this factory returns singletons
or prototypes.
* `boolean isSingleton()`: Returns `true` if this `FactoryBean` returns singletons or
`false` otherwise.
* `Class getObjectType()`: Returns the object type returned by the `getObject()` method
* `Class<?> getObjectType()`: Returns the object type returned by the `getObject()` method
or `null` if the type is not known in advance.

The `FactoryBean` concept and interface is used in a number of places within the Spring
Expand Down