Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » JavaServer Faces » pagecode sync in Eclipse(Can Ecplise automatically keep the JSF pagecode in sync?)
icon5.gif  pagecode sync in Eclipse [message #664156] Thu, 07 April 2011 16:24 Go to next message
Ben is currently offline BenFriend
Messages: 8
Registered: March 2011
Junior Member
Greetings! I have posted this question in the Eclipse forum and was suggested that I post something here.

We are currently using RAD 7 and are very interested in moving to Eclipse. RAD has a handy feature that allows you to modify your JSF page while automatically updating the managed backing bean (pagecode) with the appropriate getters and setters. So far, we've not found anything in Eclipse (plugin or otherwise) that will do this for us.

Does anyone know of a way in Eclipse to have your pagecode automatically updated for you? Surely you guys using Ecplise don't go in and manually add/remove/change getters and setters for your page components, or do you???

Thanks a bunch!
Re: pagecode sync in Eclipse [message #665230 is a reply to message #664156] Wed, 13 April 2011 19:30 Go to previous messageGo to next message
Ian Trimble is currently offline Ian TrimbleFriend
Messages: 137
Registered: July 2009
Senior Member
The JSF Tools project doesn't have tooling that manages the concept of one page == one backing bean, it's just not the approach we took. There's nothing to prevent the user from developing a backing bean for each page, but some tooling we looked at actually locked the user into that approach and we felt that it was a limitation we didn't want to impose.

So the short answer is that the JSF Tools project doesn't currently offer the functionality that you want. (But feel free to log an enhancement request in Bugzilla for such a feature.)

- Ian
Re: pagecode sync in Eclipse [message #665380 is a reply to message #665230] Thu, 14 April 2011 13:51 Go to previous message
Ben is currently offline BenFriend
Messages: 8
Registered: March 2011
Junior Member
Thank you Ian! I was wondering, could you describe how you guys architect your web pages? Perhaps we need to change what we do to match more closely what the community does.

On our site, we have primarily .jsp pages (with jsf components) where there is a backing bean for each page. When you navigate to a page where you want to display a list of parts for example, we have a before phase listener such as this...
<f:view beforePhase="#{pc_Parts.beforePhase}">

... and in the backing bean (Parts.java is a managed bean defined in faces-config.xml as pc_Parts), we've got a phase listener like this where we hit our DB for parts info and put a List<PartBean> into the session.
public void beforePhase(PhaseEvent pe) {
    List<PartBean> parts = getParts();
    setPartsList(parts);
}

Our parts.jsp page then has a t:dataTable that builds the list of parts from the session and displays them on the page.


If you have time (or anyone else for that matter), how does this differ from how you would structure a jsf page without using a backing bean?

Thanks all for your input!
Previous Topic:Referencing Bean values in JSF page
Next Topic:what is the importance of 3 xml files for pi, dti and normal inside metadata directory
Goto Forum:
  


Current Time: Thu Mar 28 20:58:38 GMT 2024

Powered by FUDForum. Page generated in 0.02668 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top