Skip to main content



      Home
Home » Eclipse Projects » Oomph » Deleting a variable from user.setup
Deleting a variable from user.setup [message #1800992] Thu, 10 January 2019 12:42 Go to next message
Eclipse UserFriend
Is it possible to delete a variable from the user.setup using a setup task? Is it possible to delete it programmatically? I checked around oomph and could not find it. Thanks.
Re: Deleting a variable from user.setup [message #1801008 is a reply to message #1800992] Thu, 10 January 2019 22:19 Go to previous messageGo to next message
Eclipse UserFriend
No, there's no task to delete tasks. Yes of course it's possible programmatically, given you can do this in the editor by selecting it and hitting Delete. Programmatically, these are all modeled with EMF, so if you have the SetupTask instance, it's an EObject, and you can use org.eclipse.emf.ecore.util.EcoreUtil.delete(EObject, boolean) to remove it.

Perhaps you can explain the motivation for what you're trying to achieve. Why would you want to delete a variable instead of just not using it?
Re: Deleting a variable from user.setup [message #1801061 is a reply to message #1801008] Fri, 11 January 2019 14:07 Go to previous messageGo to next message
Eclipse UserFriend
Thanks for the valuable information. In this post you indicated that if the install.root variable is in the user.setup it will override it. I would like to delete it if it is there so that the variable defined in my setup will take precedence.
Re: Deleting a variable from user.setup [message #1801107 is a reply to message #1801061] Sun, 13 January 2019 22:28 Go to previous message
Eclipse UserFriend
I see, though this seems like an example of not using that variable, though that might not be so practical because other variables depend on it. Though in the end, it's probably these other variables that you can override directly.

I don't think removing variables from the user.setup (or anywhere else) is a practical goal for a setup task. There must be a better way to achieve that. E.g., perhaps a property or annotation on a variable to indicate that it's value shouldn't be overridden by a variable in a scope that would normally override it...
Previous Topic:-Doomph.p2.pool argument
Next Topic:2018-12 Eclipse Installation Error
Goto Forum:
  


Current Time: Thu Jul 03 17:10:41 EDT 2025

Powered by FUDForum. Page generated in 0.03504 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top