1
/*******************************************************************************
2
* Copyright (c) 2015 Dominik Braemer.
3
* All rights reserved. This program and the accompanying materials
4
* are made available under the terms of the GNU Public License v3.0
5
* which accompanies this distribution, and is available at
6
* http://www.gnu.org/licenses/gpl.html
7
******************************************************************************/
1
8
package com.blogspot.thedsweb.util;
3
10
public class Database {
4
//Path for every configuration file
5
final public static String PATHMIN = "/var/lib/yawls/min_value.txt";
6
final public static String PATHMAX = "/var/lib/yawls/max_value.txt";
7
final public static String PATHLAST = "/var/lib/yawls/last_value.txt";
8
final public static String PATHLIB = "/var/lib/yawls";
9
final public static String PATHTOCONFIG = "/etc/";
10
final public static String PATHTOCONFIGFILE = "/etc/yawls.properties";
12
//Path for library file
13
final public static String PATHTOXML = "/usr/share/yawls/lbpcascade_frontalface.xml";
16
final public static String PATHMAIN = "/usr/share/yawls/yawls_gui.glade";
17
final public static String PATHABOUT = "/usr/share/yawls/yawls_about.glade";
18
final public static String PATHCALIB = "/usr/share/yawls/yawls_calibrate.glade";
19
final public static String PATHERROR = "/usr/share/yawls/yawls_error.glade";
20
final public static String PATHICON = "/usr/share/yawls/yawls_icon_64x64.png";
23
final public static String PATHPID = "/var/run/yawls.pid";
24
final public static String PATHLOCK = "/tmp/yawls.lock";
25
final public static String PATHLOCKDAEMON = "/tmp/yawls-calibration.lock";
26
final public static String PATHLOCKCONFIG = "/tmp/yawls-configuration.lock";
28
//Path for every battery information file needed
29
final public static String PATHCHARGENOW = "/sys/class/power_supply/BAT0/charge_now";
30
final public static String PATHCHARGEFULL = "/sys/class/power_supply/BAT0/charge_full";
32
//List of external Links
33
final public static String QUESTIONS = "https://answers.launchpad.net/yawls";
36
final public static String CONFIGCONTENT = "#face Detect dim the screen if no one is in front of the camera\n" +
37
"#Set true to enable or false to disable face detection\n" +
38
"faceDetect = false\n\n" +
39
"#Minimum time between camera activations in milliseconds\n" +
40
"lowerLimit = 500\n\n" +
41
"#Maximum time between camera activations in milliseconds\n" +
42
"upperLimit = 30000\n\n" +
43
"#Minimum time increase between camera activations in milliseconds if nothing to do\n" +
44
"minIncrease = 100\n\n" +
45
"#Maximum time increase between camera activations in milliseconds if nothing to do\n" +
46
"maxIncrease = 500\n\n" +
47
"#Value for darkening threshold in percent (0-100)\n" +
48
"#For example a value of 25 means that the current brightness\n" +
49
"#has to be less than 75 percent of the last measured brightness.\n" +
50
"darkeningThreshold = 50\n\n" +
51
"#Value for brightening threshold in percent (0-100)\n" +
52
"#For example a value of 10 means that the current brightness\n" +
53
"#has to be greater than 110 percent of the last measured brightness.\n" +
54
"brighteningThreshold = 25";
11
// Path for every configuration file
12
public final static String PATHMIN = "/var/lib/yawls/min_value.txt";
13
public final static String PATHMAX = "/var/lib/yawls/max_value.txt";
14
public final static String PATHLAST = "/var/lib/yawls/last_value.txt";
15
public final static String PATHLIB = "/var/lib/yawls";
16
public final static String PATHTOCONFIG = "/etc/";
17
public final static String PATHTOCONFIGFILE = "/etc/yawls.properties";
19
// Path for library file
20
public final static String PATHTOXML = "/usr/share/yawls/lbpcascade_frontalface.xml";
23
public final static String PATHMAIN = "/usr/share/yawls/yawls_gui.glade";
24
public final static String PATHABOUT = "/usr/share/yawls/yawls_about.glade";
25
public final static String PATHCALIB = "/usr/share/yawls/yawls_calibrate.glade";
26
public final static String PATHERROR = "/usr/share/yawls/yawls_error.glade";
27
public final static String PATHICON = "/usr/share/yawls/yawls_icon_64x64.png";
29
// Path for lock files
30
public final static String PATHPID = "/var/run/yawls.pid";
31
public final static String PATHLOCK = "/tmp/yawls.lock";
32
public final static String PATHLOCKDAEMON = "/tmp/yawls-calibration.lock";
33
public final static String PATHLOCKCONFIG = "/tmp/yawls-configuration.lock";
35
// Path for every battery information file needed
36
public final static String PATHCHARGENOW = "/sys/class/power_supply/BAT0/charge_now";
37
public final static String PATHCHARGEFULL = "/sys/class/power_supply/BAT0/charge_full";
39
// List of external Links
40
public final static String QUESTIONS = "https://answers.launchpad.net/yawls";
43
public final static String CONFIGCONTENT = "#face Detect dim the screen if no one is in front of the camera\n"
44
+ "#Set true to enable or false to disable face detection\n"
45
+ "faceDetect = false\n\n"
46
+ "#Minimum time between camera activations in milliseconds\n"
47
+ "lowerLimit = 500\n\n"
48
+ "#Maximum time between camera activations in milliseconds\n"
49
+ "upperLimit = 30000\n\n"
50
+ "#Minimum time increase between camera activations in milliseconds if nothing to do\n"
51
+ "minIncrease = 100\n\n"
52
+ "#Maximum time increase between camera activations in milliseconds if nothing to do\n"
53
+ "maxIncrease = 500\n\n"
54
+ "#Value for darkening threshold in percent (0-100)\n"
55
+ "#For example a value of 25 means that the current brightness\n"
56
+ "#has to be less than 75 percent of the last measured brightness.\n"
57
+ "darkeningThreshold = 50\n\n"
58
+ "#Value for brightening threshold in percent (0-100)\n"
59
+ "#For example a value of 10 means that the current brightness\n"
60
+ "#has to be greater than 110 percent of the last measured brightness.\n"
61
+ "brighteningThreshold = 25";