[jboss-user] [JBoss Seam] - Re: two @datamodel in one sessionbean?
jdijkmeijer
do-not-reply at jboss.com
Sun Sep 16 12:06:46 EDT 2007
That doesnot work for me, behavior is a bit strange and I hope I didnt mess up. See code below:
| package nl.jeroen.testdb.persist;
|
| import java.io.Serializable;
| import java.util.List;
|
| import javax.ejb.Remove;
| import javax.ejb.Stateful;
|
| import nl.jeroen.testdb.session.IApplicationSession;
|
| import org.jboss.seam.ScopeType;
| import org.jboss.seam.annotations.Destroy;
| import org.jboss.seam.annotations.In;
| import org.jboss.seam.annotations.Logger;
| import org.jboss.seam.annotations.Name;
| import org.jboss.seam.annotations.Scope;
| import org.jboss.seam.annotations.datamodel.DataModel;
| import org.jboss.seam.annotations.datamodel.DataModelSelection;
| import org.jboss.seam.log.Log;
|
| @Scope(ScopeType.SESSION)
| @Stateful
| @Name("zzz")
| public class RoleSubjectMgrBean implements Serializable, RoleSubjectMgr {
| private static final long serialVersionUID = -9145745003284315431L;
|
| @Logger
| Log logger;
|
| @DataModel(value="list1")
| private List<String> list1;
|
| @DataModelSelection(value="focusList1")
| private String focusList1;
| public List<String> getList1() {
| return list1;
| }
|
| public void setList1(List<String> list1) {
| this.list1 = list1;
| }
|
| public String getFocusList1() {
| return focusList1;
| }
|
| public void setFocusList1(String focusList1) {
| this.focusList1 = focusList1;
| }
|
| @DataModel(value="list2")
| private List<String> list2;
|
| @DataModelSelection(value="focusList2")
| private String focusList2;
|
| public List<String> getList2() {
| return list2;
| }
| public void setList2(List<String> l2) {
| this.list2 = l2;
| }
| public String getFocusList2() {
| return focusList2;
| }
|
| public void setFocusList2(String focusList2) {
| this.focusList2 = focusList2;
| }
|
| @Destroy @Remove
| public void destroy() {
| }
|
| }
|
This fails the only way for me to get this working (deploy) is removing the second dataModel(Selection) tags and removing value=".." for dataModelSelection tags, the value=".." for the datamodel doesnot seem to do any harm nor good.
the errors are still the same errors on deployment of sessionbean:
| 17:25:47,588 INFO [org.jboss.seam.Component] Component: zzz, scope: SESSION, type: STATEFUL_SESSION_BEAN, class: nl.jeroen.testdb.persist.RoleSubjectMgrBean, JNDI: spuytear/RoleSubjectMgrBean/local
| 17:25:47,671 INFO [com.icesoft.faces.util.event.servlet.ContextEventRepeater] Servlet Context Name: null, Server Info: JBossWeb/2.0.0.GA
| 17:25:47,673 WARN [org.jboss.system.ServiceController] Problem starting service jboss.web.deployment:war=spuytwar.war,id=1280645147
| org.jboss.deployment.DeploymentException: URL file:/Applications/jboss-4.2.0.GA/server/default/tmp/deploy/tmp55177spuytear.ear-contents/spuytwar-exp.war/ deployment failed
| at org.jboss.web.tomcat.service.TomcatDeployer.performDeployInternal(TomcatDeployer.java:379)
| at org.jboss.web.tomcat.service.TomcatDeployer.performDeploy(TomcatDeployer.java:104)
|
thanks for your time,
jeroen.
ps ICEFaces is on version 1.6.0
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4084818#4084818
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4084818
More information about the jboss-user
mailing list