public interface ICodeAssist {
/**
- * Performs code completion at the given offset position in this compilation unit,
- * reporting results to the given completion requestor. The <code>offset</code>
- * is the 0-based index of the character, after which code assist is desired.
- * An <code>offset</code> of -1 indicates to code assist at the beginning of this
- * compilation unit.
- *
- * @param offset the given offset position
- * @param requestor the given completion requestor
- *
- * @exception JavaModelException if code assist could not be performed. Reasons include:<ul>
- * <li>This Java element does not exist (ELEMENT_DOES_NOT_EXIST)</li>
- * <li> The position specified is < -1 or is greater than this compilation unit's
- * source length (INDEX_OUT_OF_BOUNDS)
- * </ul>
- *
- * @exception IllegalArgumentException if <code>requestor</code> is <code>null</code>
+ * Performs code completion at the given offset position in this compilation
+ * unit, reporting results to the given completion requestor. The
+ * <code>offset</code> is the 0-based index of the character, after which
+ * code assist is desired. An <code>offset</code> of -1 indicates to code
+ * assist at the beginning of this compilation unit.
+ *
+ * @param offset
+ * the given offset position
+ * @param requestor
+ * the given completion requestor
+ *
+ * @exception JavaModelException
+ * if code assist could not be performed. Reasons include:
+ * <ul>
+ * <li>This Java element does not exist
+ * (ELEMENT_DOES_NOT_EXIST)</li>
+ * <li> The position specified is < -1 or is greater than
+ * this compilation unit's source length
+ * (INDEX_OUT_OF_BOUNDS)
+ * </ul>
+ *
+ * @exception IllegalArgumentException
+ * if <code>requestor</code> is <code>null</code>
* @deprecated Use {@link #codeComplete(int, ICompletionRequestor)} instead.
*/
void codeComplete(int offset, ICodeCompletionRequestor requestor)
- throws JavaModelException;
+ throws JavaModelException;
+
/**
- * Performs code completion at the given offset position in this compilation unit,
- * reporting results to the given completion requestor. The <code>offset</code>
- * is the 0-based index of the character, after which code assist is desired.
- * An <code>offset</code> of -1 indicates to code assist at the beginning of this
- * compilation unit.
- *
- * @param offset the given offset position
- * @param requestor the given completion requestor
- * @exception JavaModelException if code assist could not be performed. Reasons include:<ul>
- * <li>This Java element does not exist (ELEMENT_DOES_NOT_EXIST)</li>
- * <li> The position specified is < -1 or is greater than this compilation unit's
- * source length (INDEX_OUT_OF_BOUNDS)
- * </ul>
- *
- * @exception IllegalArgumentException if <code>requestor</code> is <code>null</code>
+ * Performs code completion at the given offset position in this compilation
+ * unit, reporting results to the given completion requestor. The
+ * <code>offset</code> is the 0-based index of the character, after which
+ * code assist is desired. An <code>offset</code> of -1 indicates to code
+ * assist at the beginning of this compilation unit.
+ *
+ * @param offset
+ * the given offset position
+ * @param requestor
+ * the given completion requestor
+ * @exception JavaModelException
+ * if code assist could not be performed. Reasons include:
+ * <ul>
+ * <li>This Java element does not exist
+ * (ELEMENT_DOES_NOT_EXIST)</li>
+ * <li> The position specified is < -1 or is greater than
+ * this compilation unit's source length
+ * (INDEX_OUT_OF_BOUNDS)
+ * </ul>
+ *
+ * @exception IllegalArgumentException
+ * if <code>requestor</code> is <code>null</code>
* @since 2.0
- */
- // TODO (jerome - once CompletionRequestor is working) @ deprecated Use {@link #codeComplete(int, CompletionRequestor)} instead.
+ */
+ // TODO (jerome - once CompletionRequestor is working) @ deprecated Use
+ // {@link #codeComplete(int, CompletionRequestor)} instead.
void codeComplete(int offset, ICompletionRequestor requestor)
- throws JavaModelException;
-
+ throws JavaModelException;
+
/**
* <b>DO NOT USE</b>: This API element was added in anticipation of J2SE
* 1.5 support, which is planned for the next release of Eclipse after 3.0.
* It is currently unimplemented, and the API may change slightly before
* reaching its final form.
* <p>
- * Performs code completion at the given offset position in this compilation unit,
- * reporting results to the given completion requestor. The <code>offset</code>
- * is the 0-based index of the character, after which code assist is desired.
- * An <code>offset</code> of -1 indicates to code assist at the beginning of this
- * compilation unit.
+ * Performs code completion at the given offset position in this compilation
+ * unit, reporting results to the given completion requestor. The
+ * <code>offset</code> is the 0-based index of the character, after which
+ * code assist is desired. An <code>offset</code> of -1 indicates to code
+ * assist at the beginning of this compilation unit.
* <p>
- *
- * @param offset the given offset position
- * @param requestor the given completion requestor
- * @exception JavaModelException if code assist could not be performed. Reasons include:<ul>
- * <li>This Java element does not exist (ELEMENT_DOES_NOT_EXIST)</li>
- * <li> The position specified is < -1 or is greater than this compilation unit's
- * source length (INDEX_OUT_OF_BOUNDS)
- * </ul>
- *
- * @exception IllegalArgumentException if <code>requestor</code> is <code>null</code>
+ *
+ * @param offset
+ * the given offset position
+ * @param requestor
+ * the given completion requestor
+ * @exception JavaModelException
+ * if code assist could not be performed. Reasons include:
+ * <ul>
+ * <li>This Java element does not exist
+ * (ELEMENT_DOES_NOT_EXIST)</li>
+ * <li> The position specified is < -1 or is greater than
+ * this compilation unit's source length
+ * (INDEX_OUT_OF_BOUNDS)
+ * </ul>
+ *
+ * @exception IllegalArgumentException
+ * if <code>requestor</code> is <code>null</code>
* @since 3.0
- */
+ */
void codeComplete(int offset, CompletionRequestor requestor)
- throws JavaModelException;
-
+ throws JavaModelException;
+
/**
- * Performs code completion at the given offset position in this compilation unit,
- * reporting results to the given completion requestor. The <code>offset</code>
- * is the 0-based index of the character, after which code assist is desired.
- * An <code>offset</code> of -1 indicates to code assist at the beginning of this
- * compilation unit.
- * It considers types in the working copies with the given owner first. In other words,
- * the owner's working copies will take precedence over their original compilation units
- * in the workspace.
+ * Performs code completion at the given offset position in this compilation
+ * unit, reporting results to the given completion requestor. The
+ * <code>offset</code> is the 0-based index of the character, after which
+ * code assist is desired. An <code>offset</code> of -1 indicates to code
+ * assist at the beginning of this compilation unit. It considers types in
+ * the working copies with the given owner first. In other words, the
+ * owner's working copies will take precedence over their original
+ * compilation units in the workspace.
* <p>
- * Note that if a working copy is empty, it will be as if the original compilation
- * unit had been deleted.
+ * Note that if a working copy is empty, it will be as if the original
+ * compilation unit had been deleted.
* </p>
- *
- * @param offset the given offset position
- * @param requestor the given completion requestor
- * @param owner the owner of working copies that take precedence over their original compilation units
- * @exception JavaModelException if code assist could not be performed. Reasons include:<ul>
- * <li>This Java element does not exist (ELEMENT_DOES_NOT_EXIST)</li>
- * <li> The position specified is < -1 or is greater than this compilation unit's
- * source length (INDEX_OUT_OF_BOUNDS)
- * </ul>
- *
- * @exception IllegalArgumentException if <code>requestor</code> is <code>null</code>
+ *
+ * @param offset
+ * the given offset position
+ * @param requestor
+ * the given completion requestor
+ * @param owner
+ * the owner of working copies that take precedence over their
+ * original compilation units
+ * @exception JavaModelException
+ * if code assist could not be performed. Reasons include:
+ * <ul>
+ * <li>This Java element does not exist
+ * (ELEMENT_DOES_NOT_EXIST)</li>
+ * <li> The position specified is < -1 or is greater than
+ * this compilation unit's source length
+ * (INDEX_OUT_OF_BOUNDS)
+ * </ul>
+ *
+ * @exception IllegalArgumentException
+ * if <code>requestor</code> is <code>null</code>
* @since 3.0
*/
- // TODO (jerome - once CompletionRequestor is working) @ deprecated Use {@link #codeComplete(int, CompletionRequestor, WorkingCopyOwner)} instead.
- void codeComplete(int offset, ICompletionRequestor requestor, WorkingCopyOwner owner)
- throws JavaModelException;
+ // TODO (jerome - once CompletionRequestor is working) @ deprecated Use
+ // {@link #codeComplete(int, CompletionRequestor, WorkingCopyOwner)}
+ // instead.
+ void codeComplete(int offset, ICompletionRequestor requestor,
+ WorkingCopyOwner owner) throws JavaModelException;
/**
* <b>DO NOT USE</b>: This API element was added in anticipation of J2SE
* It is currently unimplemented, and the API may change slightly before
* reaching its final form.
* <p>
- * Performs code completion at the given offset position in this compilation unit,
- * reporting results to the given completion requestor. The <code>offset</code>
- * is the 0-based index of the character, after which code assist is desired.
- * An <code>offset</code> of -1 indicates to code assist at the beginning of this
- * compilation unit.
- * It considers types in the working copies with the given owner first. In other words,
- * the owner's working copies will take precedence over their original compilation units
- * in the workspace.
+ * Performs code completion at the given offset position in this compilation
+ * unit, reporting results to the given completion requestor. The
+ * <code>offset</code> is the 0-based index of the character, after which
+ * code assist is desired. An <code>offset</code> of -1 indicates to code
+ * assist at the beginning of this compilation unit. It considers types in
+ * the working copies with the given owner first. In other words, the
+ * owner's working copies will take precedence over their original
+ * compilation units in the workspace.
* <p>
- * Note that if a working copy is empty, it will be as if the original compilation
- * unit had been deleted.
+ * Note that if a working copy is empty, it will be as if the original
+ * compilation unit had been deleted.
* </p>
- *
- * @param offset the given offset position
- * @param requestor the given completion requestor
- * @param owner the owner of working copies that take precedence over their original compilation units
- * @exception JavaModelException if code assist could not be performed. Reasons include:<ul>
- * <li>This Java element does not exist (ELEMENT_DOES_NOT_EXIST)</li>
- * <li> The position specified is < -1 or is greater than this compilation unit's
- * source length (INDEX_OUT_OF_BOUNDS)
- * </ul>
- *
- * @exception IllegalArgumentException if <code>requestor</code> is <code>null</code>
+ *
+ * @param offset
+ * the given offset position
+ * @param requestor
+ * the given completion requestor
+ * @param owner
+ * the owner of working copies that take precedence over their
+ * original compilation units
+ * @exception JavaModelException
+ * if code assist could not be performed. Reasons include:
+ * <ul>
+ * <li>This Java element does not exist
+ * (ELEMENT_DOES_NOT_EXIST)</li>
+ * <li> The position specified is < -1 or is greater than
+ * this compilation unit's source length
+ * (INDEX_OUT_OF_BOUNDS)
+ * </ul>
+ *
+ * @exception IllegalArgumentException
+ * if <code>requestor</code> is <code>null</code>
* @since 3.0
*/
- void codeComplete(int offset, CompletionRequestor requestor, WorkingCopyOwner owner)
- throws JavaModelException;
+ void codeComplete(int offset, CompletionRequestor requestor,
+ WorkingCopyOwner owner) throws JavaModelException;
/**
- * Returns the Java elements correspondiing to the given selected text in this compilation unit.
- * The <code>offset</code> is the 0-based index of the first selected character.
- * The <code>length</code> is the number of selected characters.
+ * Returns the Java elements correspondiing to the given selected text in
+ * this compilation unit. The <code>offset</code> is the 0-based index of
+ * the first selected character. The <code>length</code> is the number of
+ * selected characters.
*
- * @param offset the given offset position
- * @param length the number of selected characters
+ * @param offset
+ * the given offset position
+ * @param length
+ * the number of selected characters
* @return the Java elements correspondiing to the given selected text
- *
- * @exception JavaModelException if code resolve could not be performed. Reasons include:
- * <li>This Java element does not exist (ELEMENT_DOES_NOT_EXIST)</li>
- * <li> The range specified is not within this element's
- * source range (INDEX_OUT_OF_BOUNDS)
- * </ul>
- *
+ *
+ * @exception JavaModelException
+ * if code resolve could not be performed. Reasons include:
+ * <li>This Java element does not exist
+ * (ELEMENT_DOES_NOT_EXIST)</li>
+ * <li> The range specified is not within this element's
+ * source range (INDEX_OUT_OF_BOUNDS)
+ * </ul>
+ *
*/
IJavaElement[] codeSelect(int offset, int length) throws JavaModelException;
+
/**
- * Returns the Java elements correspondiing to the given selected text in this compilation unit.
- * The <code>offset</code> is the 0-based index of the first selected character.
- * The <code>length</code> is the number of selected characters.
- * It considers types in the working copies with the given owner first. In other words,
- * the owner's working copies will take precedence over their original compilation units
- * in the workspace.
+ * Returns the Java elements correspondiing to the given selected text in
+ * this compilation unit. The <code>offset</code> is the 0-based index of
+ * the first selected character. The <code>length</code> is the number of
+ * selected characters. It considers types in the working copies with the
+ * given owner first. In other words, the owner's working copies will take
+ * precedence over their original compilation units in the workspace.
* <p>
- * Note that if a working copy is empty, it will be as if the original compilation
- * unit had been deleted.
+ * Note that if a working copy is empty, it will be as if the original
+ * compilation unit had been deleted.
* </p>
*
- * @param offset the given offset position
- * @param length the number of selected characters
- * @param owner the owner of working copies that take precedence over their original compilation units
+ * @param offset
+ * the given offset position
+ * @param length
+ * the number of selected characters
+ * @param owner
+ * the owner of working copies that take precedence over their
+ * original compilation units
* @return the Java elements correspondiing to the given selected text
- *
- * @exception JavaModelException if code resolve could not be performed. Reasons include:
- * <li>This Java element does not exist (ELEMENT_DOES_NOT_EXIST)</li>
- * <li> The range specified is not within this element's
- * source range (INDEX_OUT_OF_BOUNDS)
- * </ul>
+ *
+ * @exception JavaModelException
+ * if code resolve could not be performed. Reasons include:
+ * <li>This Java element does not exist
+ * (ELEMENT_DOES_NOT_EXIST)</li>
+ * <li> The range specified is not within this element's
+ * source range (INDEX_OUT_OF_BOUNDS)
+ * </ul>
* @since 3.0
*/
- IJavaElement[] codeSelect(int offset, int length, WorkingCopyOwner owner) throws JavaModelException;
+ IJavaElement[] codeSelect(int offset, int length, WorkingCopyOwner owner)
+ throws JavaModelException;
}