implemented user management, fixes #803. Minor refactorings.
[taxeditor.git] / taxeditor-store / src / main / java / eu / etaxonomy / taxeditor / store / StoreUtil.java
1 // $Id$
2 /**
3 * Copyright (C) 2007 EDIT
4 * European Distributed Institute of Taxonomy
5 * http://www.e-taxonomy.eu
6 *
7 * The contents of this file are subject to the Mozilla Public License Version 1.1
8 * See LICENSE.TXT at the top of this package for the full license terms.
9 */
10
11 package eu.etaxonomy.taxeditor.store;
12
13 import java.util.UUID;
14
15 import org.eclipse.core.commands.operations.IOperationHistory;
16 import org.eclipse.core.commands.operations.IUndoContext;
17 import org.eclipse.jface.action.IStatusLineManager;
18
19 import eu.etaxonomy.taxeditor.model.AbstractUtility;
20 import eu.etaxonomy.taxeditor.store.internal.TaxeditorStorePlugin;
21
22 /**
23 * @author n.hoffmann
24 * @created 11.05.2009
25 * @version 1.0
26 */
27 public class StoreUtil extends AbstractUtility {
28
29 public static void checktaxonExists(UUID fromString) {
30 // if (CdmStore.getTaxonService().getTaxonByUuid(UUID.fromString(uuid)) == null) {
31 // logger.warn("Couldn't find taxon with UUID " + uuid);
32 // return null;
33 // }
34 }
35
36 public static IOperationHistory getOperationHistory() {
37 return TaxeditorStorePlugin.getDefault().getWorkbench().
38 getOperationSupport().getOperationHistory();
39 }
40
41 public static void setStatusLineManager(IStatusLineManager manager) {
42 statusLineManager = manager;
43 }
44
45
46 public static IUndoContext getUndoContext(){
47 return IOperationHistory.GLOBAL_UNDO_CONTEXT;
48 }
49 }