Re: AbstractMethodError question

2009-12-12 Thread Keith Irwin
I figured out the problem and thought I'd note it here. When you "proxy" and object, the proxy code calls the constructor of the object BEFORE it registers its own methods as overrides for the object's methods. If the constructor calls methods, they'll be its own implementations rather those of t

Re: AbstractMethodError question

2009-12-11 Thread Keith Irwin
On Dec 11, 3:31 pm, ataggart wrote: > On Dec 11, 12:27 pm, Keith Irwin wrote: > > Folks-- > > > I've got a class I can't change which has an abstract method I'd like > > to override using the proxy macro in Clojure. > > > The class looks something like: > > > public abstract class Foo { > > >

Re: AbstractMethodError question

2009-12-11 Thread Keith Irwin
On Dec 11, 3:33 pm, ataggart wrote: > On Dec 11, 12:44 pm, Keith Irwin wrote: > > > > > > > On Fri, Dec 11, 2009 at 12:27 PM, Keith Irwin wrote: > > > public abstract class Foo { > > > >    private Map stuff; > > > >    private void initStuff() { > > > >        stuff = new HashMap(); > > >   

Re: AbstractMethodError question

2009-12-11 Thread ataggart
On Dec 11, 12:44 pm, Keith Irwin wrote: > On Fri, Dec 11, 2009 at 12:27 PM, Keith Irwin wrote: > > public abstract class Foo { > > >    private Map stuff; > > >    private void initStuff() { > > >        stuff = new HashMap(); > >        stuff.put("a", new Object()); > >        addStuff(stuff);

Re: AbstractMethodError question

2009-12-11 Thread ataggart
On Dec 11, 12:27 pm, Keith Irwin wrote: > Folks-- > > I've got a class I can't change which has an abstract method I'd like > to override using the proxy macro in Clojure. > > The class looks something like: > > public abstract class Foo { > >    private Map stuff; > >    private void initStuff(

Re: AbstractMethodError question

2009-12-11 Thread Keith Irwin
On Fri, Dec 11, 2009 at 12:27 PM, Keith Irwin wrote: > public abstract class Foo { > >    private Map stuff; > >    private void initStuff() { > >        stuff = new HashMap(); >        stuff.put("a", new Object()); >        addStuff(stuff); >    } > >    protected void abstract addStuff(Map stuf

AbstractMethodError question

2009-12-11 Thread Keith Irwin
Folks-- I've got a class I can't change which has an abstract method I'd like to override using the proxy macro in Clojure. The class looks something like: public abstract class Foo {    private Map stuff;    private void initStuff() {        stuff = new HashMap();        stuff.put("a", new O