Automatic Bean Creation
Question: will using
FacesContext context = FacesContext.getCurrentInstance();
Bean bean开发者_如何学Go = (Bean) context.getApplication().evaluateExpressionGet(context, "#{bean}", Bean.class);
cause a new Bean to be instantiated each time the code runs through these statements? Or will it simply refer to the same instance initially created?
It will only create one if not already created yet in the current request/session/application.
精彩评论