1 package org.simantics.db.procore.ui;
\r
5 import org.eclipse.swt.widgets.Shell;
\r
6 import org.simantics.db.exception.InternalException;
\r
7 import org.simantics.db.procore.ui.internal.UI;
\r
9 public class Auxiliary {
\r
11 * @param shell for the user interface.
\r
12 * @param exception thrown from server.
\r
13 * @return true if server can be started.
\r
15 public static boolean beforeStart(Shell shell, File folder) throws InternalException {
\r
16 boolean skipPurge = "true".equals(System.getProperty("org.simantics.db.procore.ui.skipPurge"));
\r
19 return UI.purge(shell, folder);
\r
22 * @param shell for the user interface.
\r
23 * @param exception thrown from server start.
\r
24 * @return true if problem with server start was successfully fixed.
\r
26 public static boolean handleStart(Shell shell, InternalException exception) throws InternalException {
\r
27 return UI.handleStart(shell, exception);
\r
30 * @param shell for the user interface.
\r
31 * @param folder of the database.
\r
32 * @return true if deletion was successful.
\r
34 public static boolean delete(Shell shell, File folder) {
\r
35 return UI.delete(shell, folder);
\r
38 * @param shell for the user interface.
\r
39 * @param folder of the database.
\r
40 * @return true if purge was successful.
\r
42 public static boolean purge(Shell shell, File folder) {
\r
43 return UI.purge(shell, folder);
\r