Files
depot/src/java/com/samskivert
Michael Bayne 830e830100 Nixed these two updatePartial() convenience methods because they are
dangerous. The "key" (which identifies the rows you want to change) was
[ColumnExp, Comparable, ...] and the data that you would be changing was
[ColumnExp, Object]. So if you happened to pass a comparable object as the
first value you wanted to change, say:

updatePartial(FooRecord.class, FooRecord.FOO_ID, 5, FooRecord.BAR_ID, 6,
              FooRecord.BAZ, "biffle")

the compiler would think you wanted to use FOO_ID and BAR_ID as a key rather
than FOO_ID as a key and BAR_ID as something to be updated. Either way, it's
not clear what you want, so it should go. Now you have to create a Key():

updatePartial(new Key<FooRecord>(FooRecord.clsas, FooRecord.FOO_ID, 5,
                                 FooRecord.BAR_ID, 6),
              FooRecord.BAZ, "biffle")

or

updatePartial(new Key<FooRecord>(FooRecord.clsas, FooRecord.FOO_ID, 5),
              FooRecord.BAR_ID, 6, FooRecord.BAZ, "biffle")

None of our code was doing this anyway. We were already using Key everywhere or
the (Class, Comparable) method for records with a single column as primary key.
2009-03-10 23:30:36 +00:00
..
2008-11-16 07:53:22 +00:00