I have a wicket Pagewith@SpringBean
class ScreenDetailsPage(parameters: PageParameters) extends BasePage(parameters) {
@SpringBean(name = "screenDAO") protected var screenDao: DAO[Screen] = null
assertNotNull(screenDao)
and I found that @SpringBean is not populated. It does not matter if it screenDaois val or var, protected or private.
By raising the tree, I find that the constructor Component(indirectly) initializes @SpringBeanon behalf of its subclasses, but then the null assignment is non-initialization. But an appointment is required by Scala.
How can I prevent this behavior?
source
share