-
Jun 19th, 2009, 12:50 AM
#1
How to set java this keyword in springs config file
I have a bean in which one of the properties need to be set with "this" keyword. Basically one of the property of the bean needs to be the instance of bean itself that is creating it.
Not sure how to do this. Any help on this?
-
Jun 20th, 2009, 08:35 AM
#2
Setup up a custom BeanPostProcessor, or setup a custom factory bean, with a factory method to create the target bean (Factory design pattern), or setup a wrapper around the target bean, which sets the required property and delegates calls to the target bean (Decorator design pattern).
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules