Library.ModifiableModel - HOW-TO addRoot/removeRoot
Hi,
I need to remove a library (jar) from module libraries list, so I do:
Unfortunatelly the library named libURL (full path to it, prefixed jar:// and suffixed !/) is not removed from its root.
The same library was added calling:
addRoot(libURL, OrderRootType.CLASSES);
Could someone tell me please, what is wrong here?
Kind regards,
Pavlin
请先登录再写评论。
Pavlin Zahariev wrote:
To remove a library, call LibraryTable.removeLibrary().
To remove a root from library, call Library.ModifiableModel.removeRoot().
Do not forget to commit ModifiableModel afterwards.
Friendly,
Dmitry
--
Dmitry Lomov
Software Developer
JetBrains Inc.
http://www.jetbrains.com
"Develop with pleasure!"