Page 1 of 1

loadConfig API suggestion

Posted: 27 Jun 2011, 16:11
by levancho
Hi,

in the future releases is it possible to add an API method to smartFox loadConfig to accept XML or XMLList as an optional parameter?
problem is that
I am integrated smartfox API into my Flex framework that already has its own xml configuration API and I do not want to load another XML file, I can just get those properties (XML /XMLList ) from my main xml and then if there was an api I would just pass that to loadConfig method which in turn instead of making service call to load xml would read my xml parameter and configure SmartFox ?

Posted: 27 Jun 2011, 20:14
by Bax
If you load the settings in a different way, then simply pass them to the appropriate methods (for example the connect method).

Posted: 28 Jun 2011, 07:08
by levancho
that's what I am doing right now, but I found another workaround,

I just load a dummy smartfox config to triger creation of configData object on smartfox and and then manually override all those properties from my properties object like this :

Code: Select all

	for (var i:String in props) {
				if(_smartFox.config.hasOwnProperty(i)) {
					_smartFox.config[i] =props[i];
				}
		
			}