blob: 678a914b974f8657130ee79de926e5f3ea1e2718 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
|
/*******************************************************************************
* Copyright (c) 2002, 2005 QNX Software Systems and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* QNX Software Systems - Initial API and implementation
*******************************************************************************/
package org.eclipse.cdt.internal.ui.editor;
import java.util.Iterator;
import org.eclipse.cdt.core.model.ITranslationUnit;
import org.eclipse.swt.graphics.Image;
import org.eclipse.swt.widgets.Display;
/**
* ICAnnotation
*
* Interface of annotations representing markers
* and problems.
*
* @see org.eclipse.core.resources.IMarker
* @see org.eclipse.jdt.core.compiler.IProblem
*/
public interface ICAnnotation {
/**
* @see org.eclipse.jface.text.source.Annotation#getType()
*/
String getType();
/**
* @see org.eclipse.jface.text.source.Annotation#isPersistent()
*/
boolean isPersistent();
/**
* @see org.eclipse.jface.text.source.Annotation#isMarkedDeleted()
*/
boolean isMarkedDeleted();
/**
* @see org.eclipse.jface.text.source.Annotation#getText()
*/
String getText();
/**
* Returns whether this annotation is overlaid.
*
* @return <code>true</code> if overlaid
*/
boolean hasOverlay();
/**
* Returns the overlay of this annotation.
*
* @return the annotation's overlay
*/
ICAnnotation getOverlay();
/**
* Returns an iterator for iterating over the
* annotation which are overlaid by this annotation.
*
* @return an iterator over the overlaid annotaions
*/
Iterator getOverlaidIterator();
/**
* Adds the given annotation to the list of
* annotations which are overlaid by this annotations.
*
* @param annotation the problem annoation
*/
void addOverlaid(ICAnnotation annotation);
/**
* Removes the given annotation from the list of
* annotations which are overlaid by this annotation.
*
* @param annotation the problem annoation
*/
void removeOverlaid(ICAnnotation annotation);
/**
* Tells whether this annotation is a problem
* annotation.
*
* @return <code>true</code> if it is a problem annotation
*/
boolean isProblem();
/**
* Returns the compilation unit corresponding to the document on which the annotation is set
* or <code>null</code> if no corresponding co0mpilationunit exists.
*/
ITranslationUnit getTranslationUnit();
String[] getArguments();
int getId();
Image getImage(Display display);
}
|