|Performance implication of using xtextResource.getContents().get(0) [message #1817917]
||Tue, 03 December 2019 06:03
| Neeraj Bhusare
Registered: July 2009
While profiling a piece of code, I replaced the call to
After making the change, I saw a drastic reduction in the time taken by the the method that contained in the above code.
The code `xtextResource.getContents().get(0)`, internally invokes the associated JVMModelInferrer which took most of the method execution time. My objective was to get hold of the root-object, at the same time avoid the call to the JVMModelInferrer, and the above change seems to fit the bill.
Is this a recommended thing to do? Can someone please confirm?
Twitter : @NeerajBhusare
Blog : https://nbhusare.github.io/
Best regards, Neeraj
Powered by FUDForum
. Page generated in 0.01803 seconds