-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: IUserType and Equals
PostPosted: Tue Aug 04, 2009 2:06 pm 
Newbie

Joined: Tue Jan 17, 2006 8:33 pm
Posts: 4
I have an IUserType that maps a class to a database column. I can't figure out how to properly deal with dirtyness though. Since when a user edits a property of the class, they do not create a new instance of it. Thus Equals receives the same instance twice. And it's always equal.

I'm wondering about some hack, like storing the data on the class twice, so I can have 'old data' to compare to, and then hacking up Equals. I don't like that though. I'd appreciate something like IsDirty on IUserType, that I could return true from if the property has changed.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.