Is there even a way to do this without autowiring? I need to externalize a few properties (like locations of images for example), so how should I do this? If I try creating these values as literal String typed objects in my application context, and try to autowire these, nothing happens, my properties are not set in my class. Eg:
Code:
<!-- applicationContext.xml -->
<object id="myProperty" class="String">
<constructor-arg value="my proeprtyasdfawefasdf"/>
</object>
Code:
<!-- application.mxml -->
<fx:Declarations>
<!-- shortened for brevity's sake :) -->
<ioc:FlexXMLApplicationContext id="applicationContext"/>
</fx:Declarations>
<fx:Script>
...
[Autowired(name="myProperty")]
public function set myProperty(value:String):void {
throw new Error("it works!");
}
...
</fx:Script>
Running the code snippet above will result in no error being thrown (an error should be thrown when the myProperty property is set.)