<>Some initial general thoughts:I completely agree with that. If the sensor were to know about specific *DT, then we would not be taking full advantage of the Eclipse platform. I did not know about the FileFilterPattern method on the server-side. I think using the server side functions is currently the best approach as well. This means that, I do not need to do anything extra for collecting basic activity data on C/C++ files. Is the file filtering function currently an option on the server-side on the Analysis page? I did not see such filtering, but I might have overlooked. If it is not currently there, I guess it means I will need to get into that part of the development at some point, right? * However, there do appear to be some Java-specific stuff that's crept into the code. It seems To my understanding, one Java specific part in the code is in the ResourceChangeAdapter where the Java build errors are detected (detectBuildProblem method). The other part is obviously the JavaElementChangedAdapter. I looked at the detectBuildProblem method a little more carefully now, and I noticed one problem. It is written in such a way that it skips non-java files. It gets the file that is open in the active editor, checks its extension, and returns if it is not java. This works perfectly, if the java file is active and is saved which yields to auto build. However, if you disable auto build, and do a Build Project on a Java Project when there is a non-java file opened in the active editor then the function returns without getting the build errors even though the project is built. Finding this out made me think that checking active file extension may not be the most robust way to decide which action to chose. Once a better way is found, it is just a matter of one line of code to change in this method to collect CDT build errors. markers = fileEditorInput.getFile().findMarkers( IJavaModelMarker.JAVA_MODEL_PROBLEM_MARKER, true, IResource.DEPTH_INFINITE); should be changed with markers = fileEditorInput.getFile().findMarkers( ICModelMarker.C_MODEL_PROBLEM_MARKER, true, IResource.DEPTH_INFINITE); For the *ElementChangedAdapter, I already wrote the CElementChangedAdapter that would replace JavaElementChangedAdapter. I think both of these listeners may be added to the sensor since they are listeners in different nature. The workbench should call the proper one. I added CoreModel.getDefault().addElementChangedListener(new CElementChangedAdapter(this)) and the proper listener has responded to changes. This property will not be there anymore:-) This explains the existence of the sensor.properties and why it is not a good idea to make it tool specific. Now that I think of it again, I should have targeted the Eclipse Sensor customization instead of sensor.properties file. Why cannot a specific sensor (Eclipse Sensor, in my case) have preferences which could further customize the sensor just for collecting data about the inherently language specific functions? These preferences would not in any way affect the sensor.properties file nor would they affect the common "point of contact" for every sensor. If the user is working on a Java project she might configure the sensor so that it deals only with Java build errors or Java element changes. This way, it would also be very easy to switch between *DTs for language specific functions. Apart from that, the sensor would continue to collect activity data regardless of the *DT. Just another idea:-) Thank you for the time you take to answer my questions, thank you for your interest in my effort. The 'installer" project sounds good and I think it is a necessity. If I can meet my project's deadlines and if I can find more spare time I would be interested in that as well. But it is too hard for me to say anything now:-). Cheers, Turker |
- [HACKYSTAT-DEV-L:11] Re: CDT and hackyEclipse Michael Paulding
- [HACKYSTAT-DEV-L:12] Re: CDT and hackyEclipse Philip Johnson
- [HACKYSTAT-DEV-L:20] Re: CDT and hackyEclipse Turker Keskinpala
- [HACKYSTAT-DEV-L:20] Re: CDT and hackyEclip... Philip Johnson
- [HACKYSTAT-DEV-L:21] Re: CDT and hackyE... Takuya Yamashita
- [HACKYSTAT-DEV-L:26] Re: CDT and h... Takuya Yamashita
- [HACKYSTAT-DEV-L:40] Re: CDT a... Turker Keskinpala
- [HACKYSTAT-DEV-L:74] Re: C... Turker Keskinpala
- [HACKYSTAT-DEV-L:76] Re: C... Philip Johnson
- [HACKYSTAT-DEV-L:78] Re: C... Turker Keskinpala
- [HACKYSTAT-DEV-L:80] Re: C... Philip Johnson
- [HACKYSTAT-DEV-L:81] Re: C... Turker Keskinpala
- [HACKYSTAT-DEV-L:22] Re: CDT and hackyE... Takuya Yamashita
