JavaBean « Bean « JSF Q&A

1. Reading contents of a managed bean with reflection in a JSF application

I want to print out the contents of a backing bean in an auto-generated way. So all the contents appear on a JSP. Is this possible anyhow? Thanks in advance, Daniel

2. Handling a complex Bean-tree in JSF

Let's take a look at this bean structure for example:

public class Abean {
   private Bbean b;

public class Bbean {
   private ArrayList<Cbean> c;

public class Cbean {

3. How many Beans should be enough?

I'm a undergrad Student at a German University.
I have a team Programming Course .. where we have to use JavaEE/JSF to make a social networking site .. like LinkedIn.

4. JSF, multiple bean update property in a form

I edited my question to be more precise as I have more time to write it. I have a JSF form that should modify the value of the different properties of a ...

5. JSF Managed Bean auto-create?

Is it possible to have a JSF managed bean be automatically created? For example I have several session scoped beans. Sometimes it becomes necessary to access these instances in code (rather than ...

6. How is Bean's property referenced?

I have something like that: faces-config.xml

I have a bean and in jsp page I have something like value="#{aBean.someBoo}". But I dont have such property in bean's ...

7. JSF - First steps - Bean doesnt work

Im moving first steps into JSF framework. I so make these jsp/bean : index.jsp :

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
   <%@ taglib prefix="f" uri="" ...

8. Is there a way to know which bean properties are referenced in xhtml files of a JSF project?

I inherited a JSF project developed a year ago by someone which does not work in my company anymore, and the code is really hard to understand. A lot of it ...

9. JSF managed bean

Hy all, i am new with all of this,and probably this would be a dumb question,but i have an managed bean that has a property flower - String, and a property List ...

10. Difference between managed bean and backing bean

HI, I come across this term managed bean and backing bean in several forums. Many people thing both are the same. But, it has slight difference. Can any one help me to ...

11. JSF does not report undefined beans

I started to learn Java, JSF2 and JPA2 and used "Pet Catalog" example project to start with. I use Eclipse + Glassfish. So I have JSF view page with following line:

<h:outputText value="Item ...

12. JSF Bean won't set

This is very confusing. I'm working on a simple app for a class and followed the examples but the damn Bean property just won't set. Code follows: Bean code:

import ...

13. JSF: Bean method call with parameter

I can't get method calls with parameters to work in JSF 2.0 (MyFaces) and Tomcat 6. This is how I try it: <f:selectItems var="item" value="#{bla.someList} itemValue="#{item.value1}" itemLabel="#{item.value2}"> <f:param name="param1" value="0" /> </f:selectItems> I can't define ...

14. JSF 1.2: How to keep Managed Bean with request scope?

Is it possible to keep a request scope bean after the page is rendered?

15. Why do we need beans.xml while working with JSF web application?

I started web development using JSF, after studying JSP and Servlets for a while. When you create a JSF web application you always(may be often but am not sure if it ...

16. How should I go about reading the data from DB inside the managed beans?

I need to read/write data of a post(in a forum website). For reading the data of post, I need to read title of post, content Of Post & post owner. My ...

17. JSF request scoped bean population problem

this is my first question in this beautiful site. I have googled a lot but I didn't find any solution. I'm new to JSF and I'm learning it with "JSF 2 APIs ...

18. JSF bean initializing with faces-config.xml

I've a Bean named as Bucket, it has a HashMap. I want to initialize the bean and polulate the HashMap in the faces-config.xml with a property file. How can I do ...

19. Is it possible to access java beans in selenium tests?

We are currently developing a trade project with Richfaces 3.0, Seam 2.2 and JBOSS 6.0. And we are using Selenium for our GUI tests. I just want to know if there ...

20. How to fill managed bean properties with data from DB when using for existing data read?

I have a very simple managed bean LOB which is used for reading existing LOBs(from DB) as well as for writing new LOB to DB.

@ManagedBean(name = "lob")
public class LOB implements Serializable ...

21. JSF 2: property on bean assumed to be written instead of read?

I have the following simple view main.xhtml, the request URL would be something like: http://localhost:8080/myproj/main.jsf?pq=2

<ui:composition xmlns=""