Re: Mutating state in java super classes

2009-10-08 Thread C. Florian Ebeling
>> Neither gen-class nor proxy seem to mention how one can access or >> mutate member variables.  I would have thought instance variables >> would be accessible and mutatable within some kind of binding... > > gen-class has an :exposes option that allows you to create > getter and setter methods f

Re: Mutating state in java super classes

2009-09-15 Thread Chouser
On Tue, Sep 15, 2009 at 7:15 AM, Rick Moynihan wrote: > > Hi all, > > I'm looking at extending a java class in clojure, however I can't find > any mention of how to access or change state within my super class > object e.g. given a java class like this: > > public class Foo { >   protected int fo

Mutating state in java super classes

2009-09-15 Thread Rick Moynihan
Hi all, I'm looking at extending a java class in clojure, however I can't find any mention of how to access or change state within my super class object e.g. given a java class like this: public class Foo { protected int foo = 10; // ... } How can I write the equivalent of this in clojure