tpdi
unread,Jan 3, 2012, 5:51:06 PM1/3/12Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to ServiceStack .NET Open Source REST Web Services Framework
So I have a service, for example, that registers (creates) a user. I
want my service to get the user properties, validate them, and persist
them. In my business layer I have a User class, with properties Name,
Password, Email.
In my service, I want to collect those three properties, plus an
additional ConfirmPassword property. I won't persist this, I'll just
check in my validation that Password == ConfirmPassword.
Should I just wrap:
public class UserDTO {
public User user {get; set; }
public string ConfirmPassword { get; set ;}
// other non-persisted book-keeping info
}
or is there a better idiom to use?
Thanks,
Tom