From: Gavin_King/Cirrus%<CI...@ci...> - 2002-03-01 12:32:39
|
Well, I've decided I'm going to have to "refactor" the collection code. It turns out that we really *do* need to be able to do things like clone the entire state of a collection + fully diff the state of two collections. I liked my shortcut method of dirty checking for a while, but now its becoming a real hassle to do other things where I really need to capture the whole state (eg. caching). The codebase is now full of ugly workarounds for collections because they don't have this ability. This means there will be no new features or bugfixes from me until this job is finished. cross-transaction caching is sort of implemented, but I'm sure there are problems there. What I will do is add a method clone(Object x) to the Type interface. Then all mutable types will be expected to implement this. (immutable types can just return x). I will change the implemntation of equals() for collections to diff the object graph instead of doing ==. Then I can simplify a heap of code on RelationalDatabaseSession and just generally look a hellavalot more elegant. |