What exactly does code like this mean:

qx.Class.define("my.class", {
...
  members: {
    foo: 1
  }
...
});

In particular, when will foo be initialized? Is foo now an instance variable
or a class variable?

The reason I ask is that in some very complicated code I am seeing behavior
that suggests foo is a class variable, not an instance variable. In other
words, when I call obj.hasOwnProperty('foo'), where obj is an instance of
class my.class, I get "false".

In contrast, when I put this code in the constructor:

  this.foo = 1

then each instance of my.class appears to get its own independent copy of
foo.

I'm wondering whether this is the advertised behavior, or whether something
in my complicated code is causing QooxDoo to behave this way.

Dave

-- 
View this message in context: 
http://www.nabble.com/Exact-meaning-of-member-attributes-tp25776434p25776434.html
Sent from the qooxdoo-devel mailing list archive at Nabble.com.


------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to