Flex facet build configration
Hi guys,
How can I change flex facet build configuration?
FacetType type = FacetTypeRegistry.getInstance().findFacetType("flex"); for (Module module : ModuleManager.getInstance(project).getModules()) { Facet facet = FacetManager.getInstance(module).getFacetByType(type.getId()); facet.getConfiguration(). }
Can't find the correct API to access it.
Thanks
请先登录再写评论。
Unfortunately Flex Support plugin in IntelliJ IDEA is not open sourced and doesn't have publicly open API.
Seems logical then that I should be able to voverride this settings with reflection?
When I come to think of it, I can simply(?) manipulate the iml file to change the settings I need.
Is there an easy way to get and set properties inside the iml file?
I would like to manipulate the options inside the flex facet.
IntelliJ IDEA license doesn't allow reverse engineering.
Any XML manipulating API will work.
Hi Alexander,
I am trying to adjust my plugin to version 11.1.
This code stopped to work:
FacetType type = FacetTypeRegistry.getInstance().findFacetType("flex");I used this to test if module is of type flex: facet != null
How can I fix this please?
There are no Java modules with Flex facets in 11.1, only Flash modules left. Module type check is the same as before: ModuleType.get(module) == FlexModuleType.getInstance(). FlashBuildConfigurations are accessed via FlexBuildConfigurationManager class. But again, this API is not open, and decompilation and reverse engineereing is not allowed by the license.
Thanks :)
Regarding what is allowed by the license, changing the *.iml file programatically in the file system is allowed?
Yes