AUTOSENS logging cleanup

This commit is contained in:
Milos Kozak 2018-07-27 11:35:32 +02:00
parent 8639a8ec59
commit 1e68165c82
11 changed files with 20 additions and 10 deletions

View file

@ -67,4 +67,7 @@ public class Constants {
//SMS Communicator //SMS Communicator
public static final long SMS_CONFIRM_TIMEOUT = T.mins(5).msecs(); public static final long SMS_CONFIRM_TIMEOUT = T.mins(5).msecs();
// logging
public static final String AUTOSENS = "AUTOSENS";
} }

View file

@ -26,7 +26,7 @@ import info.nightscout.utils.SP;
*/ */
public class AutosensData implements DataPointWithLabelInterface { public class AutosensData implements DataPointWithLabelInterface {
private static Logger log = LoggerFactory.getLogger("AUTOSENS"); private static Logger log = LoggerFactory.getLogger(Constants.AUTOSENS);
public void setChartTime(long chartTime) { public void setChartTime(long chartTime) {
this.chartTime = chartTime; this.chartTime = chartTime;

View file

@ -5,11 +5,13 @@ import org.json.JSONObject;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import info.nightscout.androidaps.Constants;
/** /**
* Created by mike on 06.01.2017. * Created by mike on 06.01.2017.
*/ */
public class AutosensResult { public class AutosensResult {
private static Logger log = LoggerFactory.getLogger("AUTOSENS"); private static Logger log = LoggerFactory.getLogger(Constants.AUTOSENS);
//default values to show when autosens algorithm is not called //default values to show when autosens algorithm is not called
public double ratio = 1d; public double ratio = 1d;

View file

@ -49,7 +49,7 @@ import static info.nightscout.utils.DateUtil.now;
*/ */
public class IobCobCalculatorPlugin extends PluginBase { public class IobCobCalculatorPlugin extends PluginBase {
private Logger log = LoggerFactory.getLogger("AUTOSENS"); private Logger log = LoggerFactory.getLogger(Constants.AUTOSENS);
private static IobCobCalculatorPlugin plugin = null; private static IobCobCalculatorPlugin plugin = null;

View file

@ -43,7 +43,7 @@ import static java.util.Calendar.MINUTE;
*/ */
public class IobCobOref1Thread extends Thread { public class IobCobOref1Thread extends Thread {
private static Logger log = LoggerFactory.getLogger("AUTOSENS"); private static Logger log = LoggerFactory.getLogger(Constants.AUTOSENS);
private final Event cause; private final Event cause;
private IobCobCalculatorPlugin iobCobCalculatorPlugin; private IobCobCalculatorPlugin iobCobCalculatorPlugin;

View file

@ -42,7 +42,7 @@ import static info.nightscout.utils.DateUtil.now;
*/ */
public class IobCobThread extends Thread { public class IobCobThread extends Thread {
private static Logger log = LoggerFactory.getLogger("AUTOSENS"); private static Logger log = LoggerFactory.getLogger(Constants.AUTOSENS);
private final Event cause; private final Event cause;
private IobCobCalculatorPlugin iobCobCalculatorPlugin; private IobCobCalculatorPlugin iobCobCalculatorPlugin;

View file

@ -4,6 +4,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import info.nightscout.androidaps.Config; import info.nightscout.androidaps.Config;
import info.nightscout.androidaps.Constants;
import info.nightscout.androidaps.R; import info.nightscout.androidaps.R;
import info.nightscout.androidaps.interfaces.PluginBase; import info.nightscout.androidaps.interfaces.PluginBase;
import info.nightscout.androidaps.interfaces.PluginDescription; import info.nightscout.androidaps.interfaces.PluginDescription;
@ -16,7 +17,7 @@ import info.nightscout.utils.SafeParse;
public abstract class AbstractSensitivityPlugin extends PluginBase implements SensitivityInterface { public abstract class AbstractSensitivityPlugin extends PluginBase implements SensitivityInterface {
private static final Logger log = LoggerFactory.getLogger("AUTOSENS"); private static final Logger log = LoggerFactory.getLogger(Constants.AUTOSENS);
public AbstractSensitivityPlugin(PluginDescription pluginDescription) { public AbstractSensitivityPlugin(PluginDescription pluginDescription) {
super(pluginDescription); super(pluginDescription);

View file

@ -11,6 +11,7 @@ import java.util.Date;
import java.util.List; import java.util.List;
import info.nightscout.androidaps.Config; import info.nightscout.androidaps.Config;
import info.nightscout.androidaps.Constants;
import info.nightscout.androidaps.MainApp; import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R; import info.nightscout.androidaps.R;
import info.nightscout.androidaps.data.Profile; import info.nightscout.androidaps.data.Profile;
@ -28,7 +29,7 @@ import info.nightscout.utils.SP;
*/ */
public class SensitivityAAPSPlugin extends AbstractSensitivityPlugin { public class SensitivityAAPSPlugin extends AbstractSensitivityPlugin {
private static Logger log = LoggerFactory.getLogger("AUTOSENS"); private static Logger log = LoggerFactory.getLogger(Constants.AUTOSENS);
static SensitivityAAPSPlugin plugin = null; static SensitivityAAPSPlugin plugin = null;

View file

@ -11,6 +11,7 @@ import java.util.Date;
import java.util.List; import java.util.List;
import info.nightscout.androidaps.Config; import info.nightscout.androidaps.Config;
import info.nightscout.androidaps.Constants;
import info.nightscout.androidaps.MainApp; import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R; import info.nightscout.androidaps.R;
import info.nightscout.androidaps.data.Profile; import info.nightscout.androidaps.data.Profile;
@ -27,7 +28,7 @@ import info.nightscout.utils.DateUtil;
*/ */
public class SensitivityOref0Plugin extends AbstractSensitivityPlugin { public class SensitivityOref0Plugin extends AbstractSensitivityPlugin {
private static Logger log = LoggerFactory.getLogger("AUTOSENS"); private static Logger log = LoggerFactory.getLogger(Constants.AUTOSENS);
static SensitivityOref0Plugin plugin = null; static SensitivityOref0Plugin plugin = null;

View file

@ -11,6 +11,7 @@ import java.util.Date;
import java.util.List; import java.util.List;
import info.nightscout.androidaps.Config; import info.nightscout.androidaps.Config;
import info.nightscout.androidaps.Constants;
import info.nightscout.androidaps.MainApp; import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R; import info.nightscout.androidaps.R;
import info.nightscout.androidaps.data.Profile; import info.nightscout.androidaps.data.Profile;
@ -27,7 +28,7 @@ import info.nightscout.utils.DateUtil;
*/ */
public class SensitivityOref1Plugin extends AbstractSensitivityPlugin { public class SensitivityOref1Plugin extends AbstractSensitivityPlugin {
private static Logger log = LoggerFactory.getLogger("AUTOSENS"); private static Logger log = LoggerFactory.getLogger(Constants.AUTOSENS);
static SensitivityOref1Plugin plugin = null; static SensitivityOref1Plugin plugin = null;

View file

@ -9,6 +9,7 @@ import java.util.Date;
import java.util.List; import java.util.List;
import info.nightscout.androidaps.Config; import info.nightscout.androidaps.Config;
import info.nightscout.androidaps.Constants;
import info.nightscout.androidaps.MainApp; import info.nightscout.androidaps.MainApp;
import info.nightscout.androidaps.R; import info.nightscout.androidaps.R;
import info.nightscout.androidaps.data.Profile; import info.nightscout.androidaps.data.Profile;
@ -26,7 +27,7 @@ import info.nightscout.utils.SP;
*/ */
public class SensitivityWeightedAveragePlugin extends AbstractSensitivityPlugin { public class SensitivityWeightedAveragePlugin extends AbstractSensitivityPlugin {
private static Logger log = LoggerFactory.getLogger("AUTOSENS"); private static Logger log = LoggerFactory.getLogger(Constants.AUTOSENS);
private static SensitivityWeightedAveragePlugin plugin = null; private static SensitivityWeightedAveragePlugin plugin = null;