01: /*******************************************************************************
02: * Copyright (c) 2000, 2006 IBM Corporation and others.
03: * All rights reserved. This program and the accompanying materials
04: * are made available under the terms of the Eclipse Public License v1.0
05: * which accompanies this distribution, and is available at
06: * http://www.eclipse.org/legal/epl-v10.html
07: *
08: * Contributors:
09: * IBM Corporation - initial API and implementation
10: *******************************************************************************/package org.eclipse.jface.contentassist;
11:
12: import org.eclipse.jface.text.contentassist.ICompletionProposal;
13: import org.eclipse.jface.text.contentassist.IContentAssistProcessor;
14: import org.eclipse.jface.text.contentassist.IContextInformation;
15:
16: /**
17: * Extension interface for {@link org.eclipse.jface.text.contentassist.IContentAssistProcessor}
18: * which provides the context for the
19: * {@linkplain org.eclipse.jface.contentassist.ISubjectControlContentAssistant subject control content assistant}.
20: *
21: * @since 3.0
22: * @deprecated As of 3.2, replaced by Platform UI's field assist support
23: */
24: public interface ISubjectControlContentAssistProcessor extends
25: IContentAssistProcessor {
26:
27: /**
28: * Returns a list of completion proposals based on the specified location
29: * within the document that corresponds to the current cursor position
30: * within the text viewer.
31: *
32: * @param contentAssistSubjectControl the content assist subject control whose
33: * document is used to compute the proposals
34: * @param documentOffset an offset within the document for which
35: * completions should be computed
36: * @return an array of completion proposals or <code>null</code> if no
37: * proposals are possible
38: */
39: ICompletionProposal[] computeCompletionProposals(
40: IContentAssistSubjectControl contentAssistSubjectControl,
41: int documentOffset);
42:
43: /**
44: * Returns information about possible contexts based on the specified
45: * location within the document that corresponds to the current cursor
46: * position within the content assist subject control.
47: *
48: * @param contentAssistSubjectControl the content assist subject control whose
49: * document is used to compute the possible contexts
50: * @param documentOffset an offset within the document for which context
51: * information should be computed
52: * @return an array of context information objects or <code>null</code>
53: * if no context could be found
54: */
55: IContextInformation[] computeContextInformation(
56: IContentAssistSubjectControl contentAssistSubjectControl,
57: int documentOffset);
58: }
|