Marker problem [message #131523] |
Thu, 18 September 2003 05:07  |
Eclipse User |
|
|
|
Originally posted by: parag.sawant.patni.com
Hi,
I have been facing a problem. Was wondering how to resolve the same.
I have created a plug-in to open a file in a file editor.
The contents are editable and need to be validated before saving the file.
Now when I open two files say File1 and File2 with the plugin,
and work on the first one.
I get a validation error Error 1 since I enter an invalid property. A
marker is created to display that to the user in the Task list.
Now I shift to File 2 and enter a valid change in the file and save. Since
there was no error, there is no marker for the same. However even the
earlier marker gets deleted in the process.
I am following the following sequence:
1. Open file
2. (user makes some changes)
3. validation
4. success ---> No marker is created
5. failure ---> Earlier markers deleted (since if there was an earlier
error,
it has to be removed)
New marker is created with the Error message.
Please tell me if I am doing anything wrong.
How do I create a separate marker for every file that I open so that I can
delete markers specific to only that file?
|
|
|
|
|
Re: Marker problem [message #131604 is a reply to message #131591] |
Thu, 18 September 2003 06:09  |
Eclipse User |
|
|
|
Originally posted by: daniel.megert.gmx.net
Parag Sawant wrote:
>Hi Dani,
>
>How do I associate a marker to each of the file (resource) I open?
>
>
see IResourcle.createMarker, IResource.deleteMarkers
>If I can get this right, I can also attach and remove the same from the
>respective resource.
>
>Do I have to specify it as persistent using the extension point of the
>problemmarker??
>
>
No.
>regards,
>Parag
>
>
>Daniel Megert wrote:
>
>
>
>>Do you attach/remove the marker to/from the right resource i.e. file1
>>and file2?
>>
>>
>
>
>
>>Dani
>>
>>
>
>
>
>>PCS wrote:
>>
>>
>
>
>
>>>Hi,
>>>
>>>I have been facing a problem. Was wondering how to resolve the same.
>>>
>>>I have created a plug-in to open a file in a file editor.
>>>The contents are editable and need to be validated before saving the file.
>>>
>>>Now when I open two files say File1 and File2 with the plugin,
>>>and work on the first one.
>>>I get a validation error Error 1 since I enter an invalid property. A
>>>marker is created to display that to the user in the Task list.
>>>
>>>Now I shift to File 2 and enter a valid change in the file and save. Since
>>>there was no error, there is no marker for the same. However even the
>>>earlier marker gets deleted in the process.
>>>
>>>I am following the following sequence:
>>>
>>>1. Open file
>>>2. (user makes some changes)
>>>3. validation
>>>4. success ---> No marker is created
>>>5. failure ---> Earlier markers deleted (since if there was an earlier
>>>error,
>>> it has to be removed)
>>> New marker is created with the Error message.
>>>
>>>Please tell me if I am doing anything wrong.
>>>How do I create a separate marker for every file that I open so that I can
>>>delete markers specific to only that file?
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>
>
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.03554 seconds