01: /*******************************************************************************
02: * Copyright (c) 2004, 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.pde.internal.ui.tests.macro;
11:
12: import org.eclipse.core.runtime.IStatus;
13: import org.eclipse.swt.widgets.Shell;
14:
15: /**
16: * Classes that implement this interface are registered with
17: * the macro manager to handle cases where the user interrupted
18: * the recording process to insert a named index. Upon playback,
19: * index handler will be called to handle the named index
20: * when reached in the script.
21: *
22: * @since 3.1
23: */
24:
25: public interface IIndexHandler {
26: /**
27: * Evaluates the state of the platform at the provided script
28: * index. Error status returned from the method will cause
29: * the script manager to stop the script execution and
30: * throw a <code>CoreException</code>.
31: *
32: * @param shell the active shell when the index was reached
33: * @param indexId the unique identifier of the index
34: * inserted in the script
35: * @return <code>Status.OK_STATUS</code> if the script can proceed, or
36: * an error status otherwise.
37: */
38: IStatus processIndex(Shell shell, String indexId);
39: }
|