Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Gendoc » Changing global variable value(Is it possible to change the value of a global "variable"?)
Changing global variable value [message #1704127] Fri, 07 August 2015 13:46 Go to next message
Yves BERNARD is currently offline Yves BERNARDFriend
Messages: 152
Registered: July 2014
Senior Member
According to the GenDoc documentation gPut() can be used to:
Quote:
Link a value to a specific key. This variable can be used all over the document (including other gendoc parts) using gGet


Actually if it's possibel to create a new global value using gPut() it appears that once set, this value cannot be changed. If so, the name "variable" is usurpated since this is rather a constant.

Did I missed something?


Yves
Re: Changing global variable value [message #1704132 is a reply to message #1704127] Fri, 07 August 2015 14:26 Go to previous messageGo to next message
Tristan Faure is currently offline Tristan FaureFriend
Messages: 460
Registered: July 2009
Senior Member
No you don't miss something
actually gPut mechanism should replace the value the second time, but Acceleo uses a cache for queries.
This means that once a query is called in an Acceleo template it will always return the same value for the same parameter that explain why gPut works only the first time. We should change the documentation to prevent users




Re: Changing global variable value [message #1704137 is a reply to message #1704132] Fri, 07 August 2015 14:48 Go to previous message
Yves BERNARD is currently offline Yves BERNARDFriend
Messages: 152
Registered: July 2014
Senior Member
Thanks for this information!

By the way, it appears that this cache can be disabled in the Acceleo Prefences. It works now! Smile


Yves
Previous Topic:Unexpected paragraph marks
Next Topic:Requiremt export
Goto Forum:
  


Current Time: Fri Apr 19 10:03:51 GMT 2024

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

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

Back to the top