KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > jface > dialogs > IDialogBlockedHandler


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  *******************************************************************************/

11 package org.eclipse.jface.dialogs;
12
13 import org.eclipse.core.runtime.IProgressMonitor;
14 import org.eclipse.core.runtime.IStatus;
15 import org.eclipse.jface.wizard.WizardDialog;
16 import org.eclipse.swt.widgets.Shell;
17
18 /**
19  * The IDialogBlockedHandler is the handler used by
20  * JFace to provide extra information when a
21  * blocking has occured. There is one static instance
22  * of this class used by WizardDialog and ModalContext.
23  * @see org.eclipse.core.runtime.IProgressMonitorWithBlocking#clearBlocked()
24  * @see org.eclipse.core.runtime.IProgressMonitorWithBlocking#setBlocked(IStatus)
25  * @see WizardDialog
26  * @since 3.0
27  */

28 public interface IDialogBlockedHandler {
29     /**
30      * The blockage has been cleared. Clear the
31      * extra information and resume.
32      */

33     public void clearBlocked();
34
35     /**
36      * A blockage has occured. Show the blockage and
37      * forward any actions to blockingMonitor.
38      * <b>NOTE:</b> This will open any blocked notification immediately
39      * even if there is a modal shell open.
40      *
41      * @param parentShell The shell this is being sent from. If the parent
42      * shell is <code>null</code> the behavior will be the same as
43      * IDialogBlockedHandler#showBlocked(IProgressMonitor, IStatus, String)
44      *
45      * @param blocking The monitor to forward to. This is most
46      * important for calls to <code>cancel()</code>.
47      * @param blockingStatus The status that describes the blockage
48      * @param blockedName The name of the locked operation.
49      * @see IDialogBlockedHandler#showBlocked(IProgressMonitor, IStatus, String)
50      */

51     public void showBlocked(Shell parentShell, IProgressMonitor blocking,
52             IStatus blockingStatus, String JavaDoc blockedName);
53
54     /**
55      * A blockage has occured. Show the blockage when there is
56      * no longer any modal shells in the UI and forward any actions
57      * to blockingMonitor.
58      *
59      * <b>NOTE:</b> As no shell has been specified this method will
60      * not open any blocked notification until all other modal shells
61      * have been closed.
62      *
63      * @param blocking The monitor to forward to. This is most
64      * important for calls to <code>cancel()</code>.
65      * @param blockingStatus The status that describes the blockage
66      * @param blockedName The name of the locked operation.
67      */

68     public void showBlocked(IProgressMonitor blocking, IStatus blockingStatus,
69             String JavaDoc blockedName);
70 }
71
Popular Tags