KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > jdt > core > ICorrectionRequestor


1 /*******************************************************************************
2  * Copyright (c) 2000, 2006 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11 package org.eclipse.jdt.core;
12
13 /**
14  * A callback interface for receiving java problem correction.
15  *
16  * @since 2.0
17  */

18 public interface ICorrectionRequestor {
19 /**
20  * Notification of a class correction.
21  *
22  * @param packageName Declaring package name of the class.
23  * @param className Name of the class.
24  * @param correctionName The correction for the class.
25  * @param modifiers The modifiers of the class.
26  * @param correctionStart The start position of insertion of the correction of the class.
27  * @param correctionEnd The end position of insertion of the correction of the class.
28  *
29  * NOTE - All package and type names are presented in their readable form:
30  * Package names are in the form "a.b.c".
31  * Nested type names are in the qualified form "A.M".
32  * The default package is represented by an empty array.
33  */

34 void acceptClass(
35     char[] packageName,
36     char[] className,
37     char[] correctionName,
38     int modifiers,
39     int correctionStart,
40     int correctionEnd);
41 /**
42  * Notification of a field correction.
43  *
44  * @param declaringTypePackageName Name of the package in which the type that contains this field is declared.
45  * @param declaringTypeName Name of the type declaring this field.
46  * @param name Name of the field.
47  * @param typePackageName Name of the package in which the type of this field is declared.
48  * @param typeName Name of the type of this field.
49  * @param correctionName The correction for the field.
50  * @param modifiers The modifiers of this field.
51  * @param correctionStart The start position of insertion of the correction of this field.
52  * @param correctionEnd The end position of insertion of the correction of this field.
53  *
54  * NOTE - All package and type names are presented in their readable form:
55  * Package names are in the form "a.b.c".
56  * Base types are in the form "int" or "boolean".
57  * Array types are in the qualified form "M[]" or "int[]".
58  * Nested type names are in the qualified form "A.M".
59  * The default package is represented by an empty array.
60  */

61 void acceptField(
62     char[] declaringTypePackageName,
63     char[] declaringTypeName,
64     char[] name,
65     char[] typePackageName,
66     char[] typeName,
67     char[] correctionName,
68     int modifiers,
69     int correctionStart,
70     int correctionEnd);
71 /**
72  * Notification of an interface correction.
73  *
74  * @param packageName Declaring package name of the interface.
75  * @param interfaceName Name of the interface.
76  * @param correctionName The correction for the interface.
77  * Can include ';' for imported interfaces.
78  * @param modifiers The modifiers of the interface.
79  * @param correctionStart The start position of insertion of the correction of the interface.
80  * @param correctionEnd The end position of insertion of the correction of the interface.
81  *
82  * NOTE - All package and type names are presented in their readable form:
83  * Package names are in the form "a.b.c".
84  * Nested type names are in the qualified form "A.M".
85  * The default package is represented by an empty array.
86  */

87 void acceptInterface(
88     char[] packageName,
89     char[] interfaceName,
90     char[] correctionName,
91     int modifiers,
92     int correctionStart,
93     int correctionEnd);
94 /**
95  * Notification of a local variable correction.
96  *
97  * @param name Name of the local variable.
98  * @param typePackageName Name of the package in which the type of this local variable is declared.
99  * @param typeName Name of the type of this local variable.
100  * @param modifiers The modifiers of this local variable.
101  * @param correctionStart The start position of insertion of the correction of this local variable.
102  * @param correctionEnd The end position of insertion of the correction of this local variable.
103  *
104  * NOTE - All package and type names are presented in their readable form:
105  * Package names are in the form "a.b.c".
106  * Base types are in the form "int" or "boolean".
107  * Array types are in the qualified form "M[]" or "int[]".
108  * Nested type names are in the qualified form "A.M".
109  * The default package is represented by an empty array.
110  */

111 void acceptLocalVariable(
112     char[] name,
113     char[] typePackageName,
114     char[] typeName,
115     int modifiers,
116     int correctionStart,
117     int correctionEnd);
118 /**
119  * Notification of a method correction.
120  *
121  * @param declaringTypePackageName Name of the package in which the type that contains this method is declared.
122  * @param declaringTypeName Name of the type declaring this method.
123  * @param selector Name of the method.
124  * @param parameterPackageNames Names of the packages in which the parameter types are declared.
125  * Should contain as many elements as parameterTypeNames.
126  * @param parameterTypeNames Names of the parameter types.
127  * Should contain as many elements as parameterPackageNames.
128  * @param parameterNames Names of the parameters.
129  * Should contain as many elements as parameterPackageNames.
130  * @param returnTypePackageName Name of the package in which the return type is declared.
131  * @param returnTypeName Name of the return type of this method, should be <code>null</code> for a constructor.
132  * @param correctionName The correction for the method.
133  * Can include zero, one or two brackets. If the closing bracket is included, then the cursor should be placed before it.
134  * @param modifiers The modifiers of this method.
135  * @param correctionStart The start position of insertion of the correction of this method.
136  * @param correctionEnd The end position of insertion of the correction of this method.
137  *
138  * NOTE - All package and type names are presented in their readable form:
139  * Package names are in the form "a.b.c".
140  * Base types are in the form "int" or "boolean".
141  * Array types are in the qualified form "M[]" or "int[]".
142  * Nested type names are in the qualified form "A.M".
143  * The default package is represented by an empty array.
144  *
145  * NOTE: parameter names can be retrieved from the source model after the user selects a specific method.
146  */

147 void acceptMethod(
148     char[] declaringTypePackageName,
149     char[] declaringTypeName,
150     char[] selector,
151     char[][] parameterPackageNames,
152     char[][] parameterTypeNames,
153     char[][] parameterNames,
154     char[] returnTypePackageName,
155     char[] returnTypeName,
156     char[] correctionName,
157     int modifiers,
158     int correctionStart,
159     int correctionEnd);
160 /**
161  * Notification of a package correction.
162  *
163  * @param packageName The package name.
164  * @param correctionName The correction for the package.
165  * Can include '.*;' for imports.
166  * @param correctionStart The start position of insertion of the correction of this package.
167  * @param correctionEnd The end position of insertion of the correction of this package.
168  *
169  * NOTE - All package names are presented in their readable form:
170  * Package names are in the form "a.b.c".
171  * The default package is represented by an empty array.
172  */

173 void acceptPackage(
174     char[] packageName,
175     char[] correctionName,
176     int correctionStart,
177     int correctionEnd);
178 }
179
Popular Tags