Project

General

Profile

Download (1.4 KB) Statistics
| Branch: | Tag: | Revision:
1 e8409423 n.hoffmann
/**
2 f0b32c88 n.hoffmann
 * Copyright (C) 2007 EDIT
3 a3c56b93 Patrick Plitzner
 * European Distributed Institute of Taxonomy
4 f0b32c88 n.hoffmann
 * http://www.e-taxonomy.eu
5 a3c56b93 Patrick Plitzner
 *
6 f0b32c88 n.hoffmann
 * The contents of this file are subject to the Mozilla Public License Version 1.1
7
 * See LICENSE.TXT at the top of this package for the full license terms.
8
 */
9 e8409423 n.hoffmann
10 35861667 n.hoffmann
package eu.etaxonomy.taxeditor.operation;
11 e8409423 n.hoffmann
12 f0b32c88 n.hoffmann
import org.eclipse.core.runtime.Status;
13 e8409423 n.hoffmann
14
/**
15 f0b32c88 n.hoffmann
 * Implementors may register to operations. The postOperation method will get
16
 * called after any post operation
17 a3c56b93 Patrick Plitzner
 *
18 e8409423 n.hoffmann
 * @author n.hoffmann
19
 * @created 24.03.2009
20
 * @version 1.0
21
 */
22
public interface IPostOperationEnabled {
23 f0b32c88 n.hoffmann
24 e8409423 n.hoffmann
	/**
25 f0b32c88 n.hoffmann
	 * <p>
26
	 * This method will be called after executing an operation. If operation
27
	 * created a new object and the {@link IPostOperationEnabled} has to know
28
	 * about the object it should be passed to the {@link IPostOperationEnabled}
29
	 * </p>
30 a3c56b93 Patrick Plitzner
	 *
31 f0b32c88 n.hoffmann
	 * @param objectAffectedByOperation
32
	 *            a newly created object for example. May be <code>null</code>
33
	 * @return true if the method executed successfully. Returning false will
34
	 *         set the operations status to {@link Status.CANCEL_STATUS} which
35
	 *         might not be what you want.
36 e8409423 n.hoffmann
	 */
37 a3c56b93 Patrick Plitzner
	public boolean postOperation(Object objectAffectedByOperation);
38
39 a2353579 n.hoffmann
	/**
40 f0b32c88 n.hoffmann
	 * This method will get called after the execution took place and occasional
41
	 * cleanups were performed. This is typically the last thing to happen.
42 a3c56b93 Patrick Plitzner
	 *
43 3be6ef3e n.hoffmann
	 * @return a boolean.
44 a2353579 n.hoffmann
	 */
45
	public boolean onComplete();
46 a3c56b93 Patrick Plitzner
47 e8409423 n.hoffmann
}