aspose file tools*
The moose likes JSF and the fly likes JSF tree structure Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "JSF tree structure" Watch "JSF tree structure" New topic
Author

JSF tree structure

Amrita SeungJo
Greenhorn

Joined: Apr 09, 2014
Posts: 4
Hi I am new to jsf i have been given a task to create a tree structure in jsf but cant use richfaces and primefaces.. Can anyone tell me how to do it. I need a complete project for reference as i am to totally new to this. :confused: :confused:
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16061
    
  21

There isn't any support for a collapsible tree in the base JSF system. JSF's UI components are based on HTML controls, and there's no HTML tree component, either.

It's not a simple task to create a UI tree component in HTML or core JSF. It's not even that simple when you use a pre-debugged UI tree such as the ones in RichFaces and PrimeFaces.


Customer surveys are for companies who didn't pay proper attention to begin with.
Amrita SeungJo
Greenhorn

Joined: Apr 09, 2014
Posts: 4
Thank you TIM but i just wanted to know is it possible to do the same by creating custom tags???
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16061
    
  21

Obviously. After all, the RichFaces and PrimeFaces people did so!

However, creating custom JSF tags is not something to do just to while away an idle afternoon. And if you do create one, I'd recommend using the xhtml method over custom Java code, as it's a lot simpler and less likely to break when JSF's next release comes out.

In short, if you attempt this, expect to spend a LOT of time and effort (== money, if you're doing it for business purposes). Not to mention the annoyance of having to drop everything and go fix bugs as they pop up.

Unless you're authoring your own alternative JSF tagset with commercial intent or simply want to muck around in JSF's darker levels, it would be far more productive to simply use an existing pre-debugged tree control. You'll spend quite enough time on that, I can attest from experience.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JSF tree structure