For JSF, it updates values even if the values haven't changed. So I
check for that condition and if so, I don't actually update anything.
The safety issue is that DataObjects are only equal if it's the same
object in memory. So assigning another seemingly identical object
would sneak through.
I eventually (last week) wrote a new equals() method for my
BaseDataObject class that makes DataObjects equal if their ObjectId
value is equal. I'm hoping that will do what I want, but I'm a bit
nervous about changing DataObject equality.
On 8/3/06, Øyvind Harboe <[EMAIL PROTECTED]> wrote:
Super!
> // TODO: needed for JSF
> Object oldValue = readProperty(propName);
> if (oldValue == value)
> {
> // NOOP
> return;
> }
> if (null != oldValue)
> {
> if (oldValue.equals(value))
> {
> // NOOP
> // IMPLEMENT: not sure if this is safe!
What does this comment mean?
--
Øyvind Harboe
http://www.zylin.com