This content has been marked as final.
Show 5 replies
-
1. Re: Class Loader Problem...
kayoung7 Aug 23, 2007 4:23 PM (in response to indyjones)I've been having the same problem.
-
2. Re: Class Loader Problem...
indyjones Aug 24, 2007 8:20 AM (in response to indyjones)Can anyone help here?
I am really stuck...
Any idea, i mean, anything, would be really appreciated....
Thanks
indy -
3. Re: Class Loader Problem...
indyjones Aug 24, 2007 8:39 AM (in response to indyjones)Here is the code....
<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <ui:composition xmlns="http://www.w3.org/1999/xhtml" xmlns:s="http://jboss.com/products/seam/taglib" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html" xmlns:rich="http://richfaces.ajax4jsf.org/rich" xmlns:a4j="https://ajax4jsf.dev.java.net/ajax" template="layout/template.xhtml"> <ui:define name="body"> <rich:tabPanel> <rich:tab label="Users"> <a4j:form ajaxSubmit="true"> <rich:dataTable id="usersList" rows="10" onRowMouseOver="this.style.backgroundColor='#F1F1F1'" onRowMouseOut="this.style.backgroundColor='#{a4jSkin.tableBackgroundColor}'" var="users" value="#{usermanager.users}" binding="#{workflowBean.usersTable}"> <a4j:support event="onRowClick" actionListener="#{usermanager.userClick}"/> <f:facet name="header"> <rich:columnGroup> <rich:column><h:outputText value="User Name" /></rich:column> <rich:column><h:outputText value="First Name" /></rich:column> <rich:column><h:outputText value="Middle Name" /></rich:column> <rich:column><h:outputText value="Last Name" /></rich:column> </rich:columnGroup> </f:facet> <rich:column><h:outputText value="#{users.username}" /></rich:column> <rich:column><h:outputText value="#{users.firstname}" /></rich:column> <rich:column><h:outputText value="#{users.middlename}" /></rich:column> <rich:column><h:outputText value="#{users.lastname}" /></rich:column> </rich:dataTable> <rich:spacer height="20" /> <rich:datascroller for="usersList" maxPages="50" /> <rich:tabPanel> <rich:tab label="Information"> <h:panelGrid columns="2"> <h:outputText value="First Name" /> <h:inputText value="Casey" id="fname" /> <h:outputText value="Middle Name" /> <h:inputText value="dfjakldsa" id="mname" /> <h:outputText value="Last Name" /> <h:inputText value="Kjfkdlsa" id="lname" /> </h:panelGrid> </rich:tab> <rich:tab label="Roles"> this is where the users roles are listed </rich:tab> </rich:tabPanel> </a4j:form> </rich:tab> <rich:tab label="Roles"> Role Administration </rich:tab> </rich:tabPanel> </ui:define> </ui:composition>
import static org.jboss.seam.ScopeType.SESSION; import java.util.List; import org.hibernate.Criteria; import org.hibernate.Session; import javax.ejb.Stateless; import javax.faces.event.ActionEvent; import org.jboss.seam.annotations.In; import org.jboss.seam.annotations.Logger; import org.jboss.seam.annotations.Out; import org.jboss.seam.annotations.Name; import org.jboss.seam.annotations.Scope; import org.jboss.seam.annotations.datamodel.DataModel; import org.jboss.seam.annotations.security.Restrict; import org.jboss.seam.log.Log; import org.jboss.seam.security.Identity; import org.richfaces.component.html.HtmlDataTable; import com.yourencore.innovationnetwork.object.Role; import com.yourencore.innovationnetwork.object.User; @Stateless @Name("usermanager") @Scope(SESSION) @Restrict("#{identity.loggedIn}") public class UserManager implements UserManagerInterface { @In private User user; @In private Session inetworkDatabase; @Logger Log log; @In("#{uiComponent['usersList']") HtmlDataTable usersTable; @Out public List<User> getUsers() { List<User> retUsers = null; try{ log.info("com.yourencore.innovationnetwork.action.UserManager.getUsers(): Trying to get users for - " + user.getUsername()); if(user != null){ Criteria criteria = inetworkDatabase.createCriteria(User.class); retUsers = criteria.list(); }else{ log.error("com.yourencore.innovationnetwork.action.UserManager.getUsers(): Can not retrieve User from Web Session"); } }catch(Exception e){ log.error("com.yourencore.innovationnetwork.action.UserManager.getUsers(): Error - " + e.toString()); } return retUsers; } public void userClick(ActionEvent event){ log.info("com.yourencore.innovationnetwork.action.UserManager.userClick(): User record clicked on "); User test = (User) usersTable.getRowData(); log.info("com.yourencore.innovationnetwork.action.UserManager.userClick(): %%%%%%%%%%%%%%% User record clicked on " + test.getUsername()); } }
-
4. Re: Class Loader Problem...
indyjones Aug 24, 2007 10:06 AM (in response to indyjones)ok...i know some one here can point me in the right direction...
Here is some more info...
I am using Facelets...
I am just trying to get the row the user clicked on using the dataTable and Ajax4jsf...
Ok, when I offered cookies on the Portal forum i got a response, how about pie? Everyone likes pie... :)
The HtmlDataTable class in the the jar within my WEB-INF/lib...
thanks
indy -
5. Re: Class Loader Problem...
luizhenrique Jul 14, 2011 6:59 PM (in response to indyjones)If exists many applications with richfaces do you need isolate it this with jboss. Create the jboss-web.xml in web-inf folder.
See this link http://thorgull.be/doku.php?id=tutorials:jboss:classloaderisolation.