]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics/src/org/simantics/AutosavePreferences.java
Migrated source code from Simantics SVN
[simantics/platform.git] / bundles / org.simantics / src / org / simantics / AutosavePreferences.java
diff --git a/bundles/org.simantics/src/org/simantics/AutosavePreferences.java b/bundles/org.simantics/src/org/simantics/AutosavePreferences.java
new file mode 100644 (file)
index 0000000..4a008e7
--- /dev/null
@@ -0,0 +1,47 @@
+/*******************************************************************************\r
+ * Copyright (c) 2012 Association for Decentralized Information Management\r
+ * in Industry THTH ry.\r
+ * All rights reserved. This program and the accompanying materials\r
+ * are made available under the terms of the Eclipse Public License v1.0\r
+ * which accompanies this distribution, and is available at\r
+ * http://www.eclipse.org/legal/epl-v10.html\r
+ *\r
+ * Contributors:\r
+ *     Semantum Oy - initial API and implementation\r
+ *******************************************************************************/\r
+package org.simantics;\r
+\r
+import org.simantics.internal.Activator;\r
+\r
+/**\r
+ * @author Tuukka Lehtonen <tuukka.lehtonen@semantum.fi>\r
+ */\r
+public class AutosavePreferences {\r
+\r
+    /**\r
+     * The system property name that can be used to externally enable/disable\r
+     * the current database connection virtual graph auto-save feature.\r
+     * \r
+     * Set the value to "false" to globally disable virtual graph autosave.\r
+     * Otherwise the preference {@link #P_VG_AUTOSAVE_ENABLED} will govern the\r
+     * enabled-state of the feature.\r
+     */\r
+    public static final String  SYSTEM_PROPERTY_AUTOSAVE     = "db.vg.autosave";\r
+\r
+    public static final String  P_NODE                       = Activator.PLUGIN_ID;\r
+\r
+    /**\r
+     * Preference for defining the enabled state of virtual graph autosave.\r
+     */\r
+    public static final String  P_VG_AUTOSAVE_ENABLED        = "virtualgraph.autosave.enabled"; //$NON-NLS-1$\r
+\r
+    /**\r
+     * Preference for defining the virtual graph autosave period time in\r
+     * seconds.\r
+     */\r
+    public static final String  P_VG_AUTOSAVE_INTERVAL       = "virtualgraph.autosave.interval"; //$NON-NLS-1$\r
+\r
+    public static final boolean DEFAULT_VG_AUTOSAVE_ENABLED  = true;\r
+    public static final int     DEFAULT_VG_AUTOSAVE_INTERVAL = 90;\r
+\r
+}\r