Explain @viewscoped, @sessionscoped, @customscoped and @requestscoped annotations?
Answer Posted / Anand Kumar Sagar
"@ViewScoped is used to create a bean that has its lifecycle associated with the current view (JSF component tree).n@SessionScoped creates a bean whose lifecycle is bound to the HTTP session. It means it persists across requests but not across sessions.n@CustomScoped allows developers to define a custom scope of managed beans by implementing the javax.faces.context.ExternalContext interface and registering the custom scope with the FacesContext object.n@RequestScoped creates a bean whose lifecycle is bound to the current HTTP request. It means it does not persist across requests."n
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
No New Questions to Answer in this Category !! You can
Post New Questions
Answer Questions in Different Category