src/share/classes/com/sun/source/util/Trees.java

changeset 308
03944ee4fac4
parent 184
905e151a185a
child 554
9d9f26857129
equal deleted inserted replaced
307:ca063536e4a6 308:03944ee4fac4
33 import javax.lang.model.element.ExecutableElement; 33 import javax.lang.model.element.ExecutableElement;
34 import javax.lang.model.element.TypeElement; 34 import javax.lang.model.element.TypeElement;
35 import javax.lang.model.type.DeclaredType; 35 import javax.lang.model.type.DeclaredType;
36 import javax.lang.model.type.ErrorType; 36 import javax.lang.model.type.ErrorType;
37 import javax.lang.model.type.TypeMirror; 37 import javax.lang.model.type.TypeMirror;
38 import javax.tools.Diagnostic;
38 import javax.tools.JavaCompiler.CompilationTask; 39 import javax.tools.JavaCompiler.CompilationTask;
39 40
40 import com.sun.source.tree.ClassTree; 41 import com.sun.source.tree.ClassTree;
41 import com.sun.source.tree.CompilationUnitTree; 42 import com.sun.source.tree.CompilationUnitTree;
42 import com.sun.source.tree.MethodTree; 43 import com.sun.source.tree.MethodTree;
180 public abstract boolean isAccessible(Scope scope, Element member, DeclaredType type); 181 public abstract boolean isAccessible(Scope scope, Element member, DeclaredType type);
181 182
182 /** 183 /**
183 * Gets the original type from the ErrorType object. 184 * Gets the original type from the ErrorType object.
184 * @param errorType The errorType for which we want to get the original type. 185 * @param errorType The errorType for which we want to get the original type.
185 * @returns javax.lang.model.type.TypeMirror corresponding to the original type, replaced by the ErrorType. 186 * @return javax.lang.model.type.TypeMirror corresponding to the original type, replaced by the ErrorType.
186 */ 187 */
187 public abstract TypeMirror getOriginalType(ErrorType errorType); 188 public abstract TypeMirror getOriginalType(ErrorType errorType);
189
190 /**
191 * Prints a message of the specified kind at the location of the
192 * tree within the provided compilation unit
193 *
194 * @param kind the kind of message
195 * @param msg the message, or an empty string if none
196 * @param t the tree to use as a position hint
197 * @param root the compilation unit that contains tree
198 */
199 public abstract void printMessage(Diagnostic.Kind kind, CharSequence msg,
200 com.sun.source.tree.Tree t,
201 com.sun.source.tree.CompilationUnitTree root);
188 } 202 }

mercurial