[jboss-user] [JBoss Seam] - Re: Navigating depth in object graph

angelogalvao do-not-reply at jboss.com
Thu Jul 27 08:04:51 EDT 2006

"petemuir" wrote : If it's not required then set it to null.
  | You could also do it in an action method  - client.setAddress(new Address()); if you want more control over whether an address is created or not.
  | Sorry, my code wasn't complete - you would need a association annotation with at least cascade=PERSIST

That is my problem :( , because if i put, for example, my address to null i will have a "javax.faces.el.PropertyNotFoundException: Base is null: bla bla..." if i try to submit something like <h:inputText id="addressNumberInput" value="#{cliente.address.number}"/>... 

My solution is put this in action method like you say, but i have a lot of relationships in the client, with address, sex, etc... i think this give a lot of work and make my code ugly....

That why i say that ognl null handler thats ww use is cool if getAddress return null he instanciates a new one the time i need, so if no address was typed no address is create, that saomething like that in EL???

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3961263#3961263

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3961263

More information about the jboss-user mailing list