158
|
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 * Port to the D programming language:
|
|
11 * Frank Benoit <benoit@tionex.de>
|
|
12 *******************************************************************************/
|
|
13 module dwtx.jface.contentassist.ISubjectControlContentAssistProcessor;
|
|
14
|
|
15 import dwt.dwthelper.utils;
|
|
16
|
|
17 import dwtx.jface.text.contentassist.ICompletionProposal;
|
|
18 import dwtx.jface.text.contentassist.IContentAssistProcessor;
|
|
19 import dwtx.jface.text.contentassist.IContextInformation;
|
|
20 import dwtx.jface.contentassist.IContentAssistSubjectControl;
|
|
21
|
|
22
|
|
23 /**
|
|
24 * Extension interface for {@link dwtx.jface.text.contentassist.IContentAssistProcessor}
|
|
25 * which provides the context for the
|
|
26 * {@linkplain dwtx.jface.contentassist.ISubjectControlContentAssistant subject control content assistant}.
|
|
27 *
|
|
28 * @since 3.0
|
|
29 * @deprecated As of 3.2, replaced by Platform UI's field assist support
|
|
30 */
|
|
31 public interface ISubjectControlContentAssistProcessor : IContentAssistProcessor {
|
|
32
|
|
33 /**
|
|
34 * Returns a list of completion proposals based on the specified location
|
|
35 * within the document that corresponds to the current cursor position
|
|
36 * within the text viewer.
|
|
37 *
|
|
38 * @param contentAssistSubjectControl the content assist subject control whose
|
|
39 * document is used to compute the proposals
|
|
40 * @param documentOffset an offset within the document for which
|
|
41 * completions should be computed
|
|
42 * @return an array of completion proposals or <code>null</code> if no
|
|
43 * proposals are possible
|
|
44 */
|
|
45 ICompletionProposal[] computeCompletionProposals(IContentAssistSubjectControl contentAssistSubjectControl, int documentOffset);
|
|
46
|
|
47 /**
|
|
48 * Returns information about possible contexts based on the specified
|
|
49 * location within the document that corresponds to the current cursor
|
|
50 * position within the content assist subject control.
|
|
51 *
|
|
52 * @param contentAssistSubjectControl the content assist subject control whose
|
|
53 * document is used to compute the possible contexts
|
|
54 * @param documentOffset an offset within the document for which context
|
|
55 * information should be computed
|
|
56 * @return an array of context information objects or <code>null</code>
|
|
57 * if no context could be found
|
|
58 */
|
|
59 IContextInformation[] computeContextInformation(IContentAssistSubjectControl contentAssistSubjectControl, int documentOffset);
|
|
60 }
|