01: /*******************************************************************************
02: * Copyright (c) 2000, 2005 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.text.information;
11:
12: import org.eclipse.jface.text.IRegion;
13: import org.eclipse.jface.text.ITextViewer;
14:
15: /**
16: * Extends {@link org.eclipse.jface.text.information.IInformationProvider} with
17: * the ability to provide the element for a given subject.
18: *
19: * @see org.eclipse.jface.text.information.IInformationProvider
20: * @since 2.1
21: */
22: public interface IInformationProviderExtension {
23:
24: /**
25: * Returns the element for the given subject or <code>null</code> if
26: * no element is available.
27: * <p>
28: * Implementers should ignore the text returned by {@link IInformationProvider#getInformation(ITextViewer, IRegion)}.
29: * </p>
30: *
31: * @param textViewer the viewer in whose document the subject is contained
32: * @param subject the text region constituting the information subject
33: * @return the element for the subject
34: *
35: * @see IInformationProvider#getInformation(ITextViewer, IRegion)
36: * @see org.eclipse.jface.text.ITextViewer
37: */
38: Object getInformation2(ITextViewer textViewer, IRegion subject);
39: }
|