Hi,
I'd like to have a class like that :
| @Entity
| public class MyUser
| extends XXX
| {
| private String login;
|
| protected MyUser()
| {
| // used by EJB3
| }
|
| public MyUser(String login)
| {
| this.setLogin(login);
| }
|
| public String getLogin()
| {
| return this.login;
| }
|
| protected void setLogin(String login)
| {
| this.login = login;
| }
| }
|
ie. the setter for the immutable business key (login) is NOT public, which
seems to be a good practice to me.
But in a user creation form, Seam requires the setter to be public in order to
use #{user.login}. Is there some nice way to achieve this kind of encapsulation
?
Thanks,
David
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4068700#4068700
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4068700
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user