Re: [qooxdoo-devel] Convert qx.core.Object to map

2009-08-08 Thread Martin Wittemann
Hello Christian, you can just use the Serializer I recently added: http://demo.qooxdoo.org/devel/apiviewer/#qx.util.Serializer I can serialize your object to json and parse it back to a javascript object. If thats too much overhead, just take a look at the code and see how you could implement

Re: [qooxdoo-devel] Convert qx.core.Object to map

2009-08-07 Thread panyasan
Sorry, the snippet was wrong: qx.Class.getProperties( qx.Class.getByName( object.classname ) ).forEach( function(property){ resultMap[property] = object.get( property ); },this); panyasan wrote: > > Hello, > > how do I convert a qx.core.Object object with its properties t

[qooxdoo-devel] Convert qx.core.Object to map

2009-08-07 Thread panyasan
Hello, how do I convert a qx.core.Object object with its properties to a simple JavaScript map? I was trying var resultMap = {}; qx.Class.getProperties( qx.Class.getByName( object.classname ) ).forEach( function(property){ resultMap[property] = this.getModel().get( property )