1) Moved net.sourceforge.phpeclipse.ui\src\net\sourceforge\phpdt back to net.sourcefo...
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / ui / text / folding / IJavaFoldingStructureProvider.java
1 /*******************************************************************************
2  * Copyright (c) 2000, 2003 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Common Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/cpl-v10.html
7  *
8  * Contributors:
9  *     IBM Corporation - initial API and implementation
10  *******************************************************************************/
11 package net.sourceforge.phpdt.ui.text.folding;
12
13 import org.eclipse.jface.text.source.projection.ProjectionViewer;
14 import org.eclipse.ui.texteditor.ITextEditor;
15
16 /**
17  * Contributors to the
18  * <code>net.sourceforge.phpdt.ui.foldingStructureProvider</code> extension
19  * point must specify an implementation of this interface which will create and
20  * maintain
21  * {@link org.eclipse.jface.text.source.projection.ProjectionAnnotation} objects
22  * as understood by
23  * {@link org.eclipse.jface.text.source.projection.ProjectionViewer}.
24  * <p>
25  * Clients may implement this interface.
26  * </p>
27  * 
28  * @since 3.0
29  */
30 public interface IJavaFoldingStructureProvider {
31
32         /**
33          * Installs this structure provider on the given editor and viewer.
34          * Implementations should observe the projection events generated by
35          * <code>viewer</code> and enable / disable generation of projection
36          * structure accordingly.
37          * 
38          * @param editor
39          *            the editor that this provider works on
40          * @param viewer
41          *            the projection viewer that displays the annotations created by
42          *            this structure provider
43          */
44         public abstract void install(ITextEditor editor, ProjectionViewer viewer);
45
46         /**
47          * Uninstalls this structure provider. Any references to editors or viewers
48          * should be cleared.
49          */
50         public abstract void uninstall();
51
52         /**
53          * (Re-)initializes the structure provided by the receiver.
54          */
55         public abstract void initialize();
56 }