:plugins:sync cleanup
This commit is contained in:
parent
678c1adc9a
commit
d6281a5452
|
@ -132,7 +132,7 @@ class MainApp : DaggerApplication() {
|
|||
// log version
|
||||
disposable += repository.runTransaction(VersionChangeTransaction(BuildConfig.VERSION_NAME, BuildConfig.VERSION_CODE, gitRemote, commitHash)).subscribe()
|
||||
// log app start
|
||||
if (sp.getBoolean(info.nightscout.plugins.sync.R.string.key_ns_log_app_started_event, config.APS))
|
||||
if (sp.getBoolean(app.aaps.plugins.sync.R.string.key_ns_log_app_started_event, config.APS))
|
||||
disposable += repository
|
||||
.runTransaction(
|
||||
InsertIfNewByTimestampTherapyEventTransaction(
|
||||
|
@ -205,26 +205,26 @@ class MainApp : DaggerApplication() {
|
|||
// 3.1.0
|
||||
if (sp.contains("ns_wifionly")) {
|
||||
if (sp.getBoolean("ns_wifionly", false)) {
|
||||
sp.putBoolean(info.nightscout.plugins.sync.R.string.key_ns_cellular, false)
|
||||
sp.putBoolean(info.nightscout.plugins.sync.R.string.key_ns_wifi, true)
|
||||
sp.putBoolean(app.aaps.plugins.sync.R.string.key_ns_cellular, false)
|
||||
sp.putBoolean(app.aaps.plugins.sync.R.string.key_ns_wifi, true)
|
||||
} else {
|
||||
sp.putBoolean(info.nightscout.plugins.sync.R.string.key_ns_cellular, true)
|
||||
sp.putBoolean(info.nightscout.plugins.sync.R.string.key_ns_wifi, false)
|
||||
sp.putBoolean(app.aaps.plugins.sync.R.string.key_ns_cellular, true)
|
||||
sp.putBoolean(app.aaps.plugins.sync.R.string.key_ns_wifi, false)
|
||||
}
|
||||
sp.remove("ns_wifionly")
|
||||
}
|
||||
if (sp.contains("ns_charginonly")) {
|
||||
if (sp.getBoolean("ns_charginonly", false)) {
|
||||
sp.putBoolean(info.nightscout.plugins.sync.R.string.key_ns_battery, false)
|
||||
sp.putBoolean(info.nightscout.plugins.sync.R.string.key_ns_charging, true)
|
||||
sp.putBoolean(app.aaps.plugins.sync.R.string.key_ns_battery, false)
|
||||
sp.putBoolean(app.aaps.plugins.sync.R.string.key_ns_charging, true)
|
||||
} else {
|
||||
sp.putBoolean(info.nightscout.plugins.sync.R.string.key_ns_battery, true)
|
||||
sp.putBoolean(info.nightscout.plugins.sync.R.string.key_ns_charging, true)
|
||||
sp.putBoolean(app.aaps.plugins.sync.R.string.key_ns_battery, true)
|
||||
sp.putBoolean(app.aaps.plugins.sync.R.string.key_ns_charging, true)
|
||||
}
|
||||
sp.remove("ns_charginonly")
|
||||
}
|
||||
if (!sp.contains(info.nightscout.plugins.sync.R.string.key_ns_log_app_started_event))
|
||||
sp.putBoolean(info.nightscout.plugins.sync.R.string.key_ns_log_app_started_event, config.APS)
|
||||
if (!sp.contains(app.aaps.plugins.sync.R.string.key_ns_log_app_started_event))
|
||||
sp.putBoolean(app.aaps.plugins.sync.R.string.key_ns_log_app_started_event, config.APS)
|
||||
if (sp.getString(app.aaps.plugins.configuration.R.string.key_maintenance_logs_email, "") == "logs@androidaps.org")
|
||||
sp.putString(app.aaps.plugins.configuration.R.string.key_maintenance_logs_email, "logs@aaps.app")
|
||||
// fix values for theme switching
|
||||
|
|
|
@ -54,6 +54,11 @@ import app.aaps.plugins.source.GlunovoPlugin
|
|||
import app.aaps.plugins.source.IntelligoPlugin
|
||||
import app.aaps.plugins.source.PoctechPlugin
|
||||
import app.aaps.plugins.source.TomatoPlugin
|
||||
import app.aaps.plugins.sync.nsclient.NSClientPlugin
|
||||
import app.aaps.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import app.aaps.plugins.sync.openhumans.OpenHumansUploaderPlugin
|
||||
import app.aaps.plugins.sync.tidepool.TidepoolPlugin
|
||||
import app.aaps.plugins.sync.xdrip.XdripPlugin
|
||||
import dagger.android.support.AndroidSupportInjection
|
||||
import info.nightscout.androidaps.R
|
||||
import info.nightscout.androidaps.danaRKorean.DanaRKoreanPlugin
|
||||
|
@ -62,11 +67,6 @@ import info.nightscout.androidaps.danar.DanaRPlugin
|
|||
import info.nightscout.androidaps.plugins.pump.eopatch.EopatchPumpPlugin
|
||||
import info.nightscout.androidaps.plugins.pump.insight.LocalInsightPlugin
|
||||
import info.nightscout.androidaps.plugins.pump.medtronic.MedtronicPumpPlugin
|
||||
import info.nightscout.plugins.sync.nsclient.NSClientPlugin
|
||||
import info.nightscout.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import info.nightscout.plugins.sync.openhumans.OpenHumansUploaderPlugin
|
||||
import info.nightscout.plugins.sync.tidepool.TidepoolPlugin
|
||||
import info.nightscout.plugins.sync.xdrip.XdripPlugin
|
||||
import info.nightscout.pump.combo.ComboPlugin
|
||||
import info.nightscout.pump.combov2.ComboV2Plugin
|
||||
import info.nightscout.pump.diaconn.DiaconnG8Plugin
|
||||
|
@ -278,7 +278,11 @@ class MyPreferenceFragment : PreferenceFragmentCompat(), OnSharedPreferenceChang
|
|||
activity?.let {
|
||||
val title = rh.gs(app.aaps.core.ui.R.string.unsecure_fallback_biometric)
|
||||
val message =
|
||||
rh.gs(app.aaps.plugins.configuration.R.string.master_password_missing, rh.gs(app.aaps.plugins.configuration.R.string.configbuilder_general), rh.gs(app.aaps.plugins.configuration.R.string.protection))
|
||||
rh.gs(
|
||||
app.aaps.plugins.configuration.R.string.master_password_missing,
|
||||
rh.gs(app.aaps.plugins.configuration.R.string.configbuilder_general),
|
||||
rh.gs(app.aaps.plugins.configuration.R.string.protection)
|
||||
)
|
||||
OKDialog.show(it, title = title, message = message)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -11,6 +11,8 @@ import app.aaps.plugins.constraints.di.PluginsConstraintsModule
|
|||
import app.aaps.plugins.insulin.di.InsulinModule
|
||||
import app.aaps.plugins.main.di.PluginsModule
|
||||
import app.aaps.plugins.source.di.SourceModule
|
||||
import app.aaps.plugins.sync.di.OpenHumansModule
|
||||
import app.aaps.plugins.sync.di.SyncModule
|
||||
import app.aaps.shared.impl.di.SharedImplModule
|
||||
import dagger.BindsInstance
|
||||
import dagger.Component
|
||||
|
@ -25,8 +27,6 @@ import info.nightscout.androidaps.plugins.pump.medtronic.di.MedtronicModule
|
|||
import info.nightscout.androidaps.plugins.pump.omnipod.dash.di.OmnipodDashModule
|
||||
import info.nightscout.androidaps.plugins.pump.omnipod.eros.di.OmnipodErosModule
|
||||
import info.nightscout.database.impl.DatabaseModule
|
||||
import info.nightscout.plugins.sync.di.OpenHumansModule
|
||||
import info.nightscout.plugins.sync.di.SyncModule
|
||||
import info.nightscout.pump.combo.di.ComboModule
|
||||
import info.nightscout.pump.combov2.di.ComboV2Module
|
||||
import info.nightscout.pump.common.di.PumpCommonModule
|
||||
|
|
|
@ -46,6 +46,12 @@ import app.aaps.plugins.source.PoctechPlugin
|
|||
import app.aaps.plugins.source.RandomBgPlugin
|
||||
import app.aaps.plugins.source.TomatoPlugin
|
||||
import app.aaps.plugins.source.XdripSourcePlugin
|
||||
import app.aaps.plugins.sync.dataBroadcaster.DataBroadcastPlugin
|
||||
import app.aaps.plugins.sync.nsclient.NSClientPlugin
|
||||
import app.aaps.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import app.aaps.plugins.sync.openhumans.OpenHumansUploaderPlugin
|
||||
import app.aaps.plugins.sync.tidepool.TidepoolPlugin
|
||||
import app.aaps.plugins.sync.xdrip.XdripPlugin
|
||||
import dagger.Binds
|
||||
import dagger.Module
|
||||
import dagger.multibindings.IntKey
|
||||
|
@ -58,12 +64,6 @@ import info.nightscout.androidaps.plugins.pump.insight.LocalInsightPlugin
|
|||
import info.nightscout.androidaps.plugins.pump.medtronic.MedtronicPumpPlugin
|
||||
import info.nightscout.androidaps.plugins.pump.omnipod.dash.OmnipodDashPumpPlugin
|
||||
import info.nightscout.androidaps.plugins.pump.omnipod.eros.OmnipodErosPumpPlugin
|
||||
import info.nightscout.plugins.sync.dataBroadcaster.DataBroadcastPlugin
|
||||
import info.nightscout.plugins.sync.nsclient.NSClientPlugin
|
||||
import info.nightscout.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import info.nightscout.plugins.sync.openhumans.OpenHumansUploaderPlugin
|
||||
import info.nightscout.plugins.sync.tidepool.TidepoolPlugin
|
||||
import info.nightscout.plugins.sync.xdrip.XdripPlugin
|
||||
import info.nightscout.pump.combo.ComboPlugin
|
||||
import info.nightscout.pump.combov2.ComboV2Plugin
|
||||
import info.nightscout.pump.diaconn.DiaconnG8Plugin
|
||||
|
|
|
@ -10,8 +10,9 @@ apply from: "${project.rootDir}/core/main/android_module_dependencies.gradle"
|
|||
apply from: "${project.rootDir}/core/main/test_dependencies.gradle"
|
||||
apply from: "${project.rootDir}/core/main/allopen_dependencies.gradle"
|
||||
apply from: "${project.rootDir}/core/main/jacoco_global.gradle"
|
||||
|
||||
android {
|
||||
namespace 'info.nightscout.plugins.sync'
|
||||
namespace 'app.aaps.plugins.sync'
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
|
|
@ -1,11 +0,0 @@
|
|||
package info.nightscout.plugins.sync.nsclient.data;
|
||||
|
||||
/**
|
||||
* Created by mike on 11.06.2017.
|
||||
*/
|
||||
|
||||
public class AlarmAck {
|
||||
public Integer level = null;
|
||||
public String group = null;
|
||||
public Long silenceTime = null;
|
||||
}
|
|
@ -1,13 +1,9 @@
|
|||
package info.nightscout.plugins.sync.dataBroadcaster
|
||||
package app.aaps.plugins.sync.dataBroadcaster
|
||||
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import android.content.pm.ResolveInfo
|
||||
import android.os.Bundle
|
||||
import app.aaps.core.main.extensions.durationInMinutes
|
||||
import app.aaps.core.main.extensions.toStringFull
|
||||
import app.aaps.core.main.iob.round
|
||||
import app.aaps.core.main.utils.fabric.FabricPrivacy
|
||||
import app.aaps.core.interfaces.aps.Loop
|
||||
import app.aaps.core.interfaces.configuration.Config
|
||||
import app.aaps.core.interfaces.iob.GlucoseStatusProvider
|
||||
|
@ -32,9 +28,13 @@ import app.aaps.core.interfaces.rx.events.EventLoopUpdateGui
|
|||
import app.aaps.core.interfaces.rx.events.EventOverviewBolusProgress
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.interfaces.utils.DecimalFormatter
|
||||
import app.aaps.core.main.extensions.durationInMinutes
|
||||
import app.aaps.core.main.extensions.toStringFull
|
||||
import app.aaps.core.main.iob.round
|
||||
import app.aaps.core.main.utils.fabric.FabricPrivacy
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.shared.impl.extensions.safeQueryBroadcastReceivers
|
||||
import dagger.android.HasAndroidInjector
|
||||
import info.nightscout.plugins.sync.R
|
||||
import io.reactivex.rxjava3.disposables.CompositeDisposable
|
||||
import io.reactivex.rxjava3.kotlin.plusAssign
|
||||
import javax.inject.Inject
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.di
|
||||
package app.aaps.plugins.sync.di
|
||||
|
||||
import androidx.lifecycle.ViewModel
|
||||
import androidx.lifecycle.ViewModelProvider
|
||||
|
@ -36,5 +36,6 @@ internal annotation class ViewModelKey(val value: KClass<out ViewModel>)
|
|||
class ViewModelFactory @Inject constructor(
|
||||
private val viewModels: MutableMap<Class<out ViewModel>, @JvmSuppressWildcards Provider<ViewModel>>
|
||||
) : ViewModelProvider.Factory {
|
||||
|
||||
override fun <T : ViewModel> create(modelClass: Class<T>): T = viewModels[modelClass]?.get() as T
|
||||
}
|
|
@ -1,16 +1,16 @@
|
|||
package info.nightscout.plugins.sync.di
|
||||
package app.aaps.plugins.sync.di
|
||||
|
||||
import androidx.lifecycle.ViewModel
|
||||
import app.aaps.plugins.sync.openhumans.OpenHumansWorker
|
||||
import app.aaps.plugins.sync.openhumans.delegates.OHStateDelegate
|
||||
import app.aaps.plugins.sync.openhumans.ui.OHFragment
|
||||
import app.aaps.plugins.sync.openhumans.ui.OHLoginActivity
|
||||
import app.aaps.plugins.sync.openhumans.ui.OHLoginViewModel
|
||||
import dagger.Binds
|
||||
import dagger.Module
|
||||
import dagger.Provides
|
||||
import dagger.android.ContributesAndroidInjector
|
||||
import dagger.multibindings.IntoMap
|
||||
import info.nightscout.plugins.sync.openhumans.OpenHumansWorker
|
||||
import info.nightscout.plugins.sync.openhumans.delegates.OHStateDelegate
|
||||
import info.nightscout.plugins.sync.openhumans.ui.OHFragment
|
||||
import info.nightscout.plugins.sync.openhumans.ui.OHLoginActivity
|
||||
import info.nightscout.plugins.sync.openhumans.ui.OHLoginViewModel
|
||||
|
||||
@Module
|
||||
abstract class OpenHumansModule {
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.di
|
||||
package app.aaps.plugins.sync.di
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.WorkManager
|
||||
|
@ -7,33 +7,33 @@ import app.aaps.core.interfaces.nsclient.ProcessedDeviceStatusData
|
|||
import app.aaps.core.interfaces.nsclient.StoreDataForDb
|
||||
import app.aaps.core.interfaces.sync.DataSyncSelectorXdrip
|
||||
import app.aaps.core.interfaces.sync.XDripBroadcast
|
||||
import app.aaps.plugins.sync.nsShared.NSClientFragment
|
||||
import app.aaps.plugins.sync.nsShared.StoreDataForDbImpl
|
||||
import app.aaps.plugins.sync.nsclient.data.NSSettingsStatusImpl
|
||||
import app.aaps.plugins.sync.nsclient.data.ProcessedDeviceStatusDataImpl
|
||||
import app.aaps.plugins.sync.nsclient.services.NSClientService
|
||||
import app.aaps.plugins.sync.nsclient.workers.NSClientAddAckWorker
|
||||
import app.aaps.plugins.sync.nsclient.workers.NSClientAddUpdateWorker
|
||||
import app.aaps.plugins.sync.nsclient.workers.NSClientMbgWorker
|
||||
import app.aaps.plugins.sync.nsclient.workers.NSClientUpdateRemoveAckWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.DataSyncWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadBgWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadDeviceStatusWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadFoodsWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadLastModificationWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadProfileStoreWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadStatusWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadTreatmentsWorker
|
||||
import app.aaps.plugins.sync.tidepool.TidepoolFragment
|
||||
import app.aaps.plugins.sync.xdrip.DataSyncSelectorXdripImpl
|
||||
import app.aaps.plugins.sync.xdrip.XdripFragment
|
||||
import app.aaps.plugins.sync.xdrip.XdripPlugin
|
||||
import app.aaps.plugins.sync.xdrip.workers.XdripDataSyncWorker
|
||||
import dagger.Binds
|
||||
import dagger.Module
|
||||
import dagger.Provides
|
||||
import dagger.Reusable
|
||||
import dagger.android.ContributesAndroidInjector
|
||||
import info.nightscout.plugins.sync.nsShared.NSClientFragment
|
||||
import info.nightscout.plugins.sync.nsShared.StoreDataForDbImpl
|
||||
import info.nightscout.plugins.sync.nsclient.data.NSSettingsStatusImpl
|
||||
import info.nightscout.plugins.sync.nsclient.data.ProcessedDeviceStatusDataImpl
|
||||
import info.nightscout.plugins.sync.nsclient.services.NSClientService
|
||||
import info.nightscout.plugins.sync.nsclient.workers.NSClientAddAckWorker
|
||||
import info.nightscout.plugins.sync.nsclient.workers.NSClientAddUpdateWorker
|
||||
import info.nightscout.plugins.sync.nsclient.workers.NSClientMbgWorker
|
||||
import info.nightscout.plugins.sync.nsclient.workers.NSClientUpdateRemoveAckWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.DataSyncWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadBgWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadDeviceStatusWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadFoodsWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadLastModificationWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadProfileStoreWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadStatusWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadTreatmentsWorker
|
||||
import info.nightscout.plugins.sync.tidepool.TidepoolFragment
|
||||
import info.nightscout.plugins.sync.xdrip.DataSyncSelectorXdripImpl
|
||||
import info.nightscout.plugins.sync.xdrip.XdripFragment
|
||||
import info.nightscout.plugins.sync.xdrip.XdripPlugin
|
||||
import info.nightscout.plugins.sync.xdrip.workers.XdripDataSyncWorker
|
||||
|
||||
@Module(
|
||||
includes = [
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsShared
|
||||
package app.aaps.plugins.sync.nsShared
|
||||
|
||||
import app.aaps.core.interfaces.nsclient.NSAlarm
|
||||
import app.aaps.core.utils.JsonHelper
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsShared
|
||||
package app.aaps.plugins.sync.nsShared
|
||||
|
||||
import android.content.Context
|
||||
import android.os.Bundle
|
||||
|
@ -34,13 +34,13 @@ import app.aaps.core.main.utils.fabric.FabricPrivacy
|
|||
import app.aaps.core.ui.dialogs.OKDialog
|
||||
import app.aaps.core.utils.HtmlHelper
|
||||
import app.aaps.database.entities.UserEntry
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.databinding.NsClientFragmentBinding
|
||||
import app.aaps.plugins.sync.databinding.NsClientLogItemBinding
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiData
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiQueue
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import dagger.android.support.DaggerFragment
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.databinding.NsClientFragmentBinding
|
||||
import info.nightscout.plugins.sync.databinding.NsClientLogItemBinding
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiData
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiQueue
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import io.reactivex.rxjava3.core.Completable
|
||||
import io.reactivex.rxjava3.disposables.CompositeDisposable
|
||||
import io.reactivex.rxjava3.kotlin.plusAssign
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsShared
|
||||
package app.aaps.plugins.sync.nsShared
|
||||
|
||||
import app.aaps.core.interfaces.nsclient.NSSgv
|
||||
import app.aaps.core.utils.JsonHelper
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsShared
|
||||
package app.aaps.plugins.sync.nsShared
|
||||
|
||||
import app.aaps.annotations.OpenForTesting
|
||||
import app.aaps.core.interfaces.configuration.Config
|
||||
|
@ -34,20 +34,20 @@ import app.aaps.core.utils.JsonHelper
|
|||
import app.aaps.database.entities.Food
|
||||
import app.aaps.database.entities.GlucoseValue
|
||||
import app.aaps.database.transactions.TransactionGlucoseValue
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.nsclient.extensions.fromJson
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toBolus
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toBolusCalculatorResult
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toCarbs
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toEffectiveProfileSwitch
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toExtendedBolus
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toFood
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toOfflineEvent
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toProfileSwitch
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toTemporaryBasal
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toTemporaryTarget
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toTherapyEvent
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toTransactionGlucoseValue
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.nsclient.extensions.fromJson
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toBolus
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toBolusCalculatorResult
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toCarbs
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toEffectiveProfileSwitch
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toExtendedBolus
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toFood
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toOfflineEvent
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toProfileSwitch
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toTemporaryBasal
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toTemporaryTarget
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toTherapyEvent
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toTransactionGlucoseValue
|
||||
import org.json.JSONArray
|
||||
import org.json.JSONObject
|
||||
import javax.inject.Inject
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsShared
|
||||
package app.aaps.plugins.sync.nsShared
|
||||
|
||||
import android.os.SystemClock
|
||||
import app.aaps.core.interfaces.configuration.Config
|
||||
|
@ -31,6 +31,7 @@ import app.aaps.database.entities.TherapyEvent
|
|||
import app.aaps.database.entities.UserEntry
|
||||
import app.aaps.database.entities.ValueWithUnit
|
||||
import app.aaps.database.transactions.TransactionGlucoseValue
|
||||
import app.aaps.plugins.sync.R
|
||||
import info.nightscout.database.impl.AppRepository
|
||||
import info.nightscout.database.impl.transactions.CgmSourceTransaction
|
||||
import info.nightscout.database.impl.transactions.InvalidateBolusCalculatorResultTransaction
|
||||
|
@ -68,7 +69,6 @@ import info.nightscout.database.impl.transactions.UpdateNsIdProfileSwitchTransac
|
|||
import info.nightscout.database.impl.transactions.UpdateNsIdTemporaryBasalTransaction
|
||||
import info.nightscout.database.impl.transactions.UpdateNsIdTemporaryTargetTransaction
|
||||
import info.nightscout.database.impl.transactions.UpdateNsIdTherapyEventTransaction
|
||||
import info.nightscout.plugins.sync.R
|
||||
import java.util.concurrent.Executors
|
||||
import java.util.concurrent.ScheduledFuture
|
||||
import java.util.concurrent.TimeUnit
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsShared.events
|
||||
package app.aaps.plugins.sync.nsShared.events
|
||||
|
||||
import app.aaps.core.interfaces.rx.events.Event
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsShared.events
|
||||
package app.aaps.plugins.sync.nsShared.events
|
||||
|
||||
import android.content.Context
|
||||
import app.aaps.core.interfaces.rx.events.EventStatus
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsShared.events
|
||||
package app.aaps.plugins.sync.nsShared.events
|
||||
|
||||
import app.aaps.core.interfaces.rx.events.EventUpdateGui
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsShared.events
|
||||
package app.aaps.plugins.sync.nsShared.events
|
||||
|
||||
import app.aaps.core.interfaces.rx.events.EventUpdateGui
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsShared.events
|
||||
package app.aaps.plugins.sync.nsShared.events
|
||||
|
||||
import app.aaps.core.interfaces.rx.events.EventUpdateGui
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient
|
||||
package app.aaps.plugins.sync.nsclient
|
||||
|
||||
import app.aaps.core.interfaces.logging.AAPSLogger
|
||||
import app.aaps.core.interfaces.logging.LTag
|
||||
|
@ -12,10 +12,10 @@ import app.aaps.core.interfaces.sync.DataSyncSelector
|
|||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.utils.JsonHelper
|
||||
import app.aaps.core.utils.waitMillis
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiQueue
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import info.nightscout.database.impl.AppRepository
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiQueue
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import kotlinx.coroutines.CoroutineScope
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.SupervisorJob
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient
|
||||
package app.aaps.plugins.sync.nsclient
|
||||
|
||||
import android.content.ComponentName
|
||||
import android.content.Context
|
||||
|
@ -8,8 +8,6 @@ import android.os.IBinder
|
|||
import androidx.preference.PreferenceFragmentCompat
|
||||
import androidx.preference.PreferenceScreen
|
||||
import androidx.preference.SwitchPreference
|
||||
import app.aaps.core.main.extensions.toJson
|
||||
import app.aaps.core.main.utils.fabric.FabricPrivacy
|
||||
import app.aaps.core.interfaces.configuration.Config
|
||||
import app.aaps.core.interfaces.configuration.Constants
|
||||
import app.aaps.core.interfaces.logging.AAPSLogger
|
||||
|
@ -34,15 +32,17 @@ import app.aaps.core.interfaces.sync.NsClient
|
|||
import app.aaps.core.interfaces.sync.Sync
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.interfaces.utils.DecimalFormatter
|
||||
import app.aaps.core.main.extensions.toJson
|
||||
import app.aaps.core.main.utils.fabric.FabricPrivacy
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.nsShared.NSClientFragment
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientStatus
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiData
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import app.aaps.plugins.sync.nsclient.data.AlarmAck
|
||||
import app.aaps.plugins.sync.nsclient.extensions.toJson
|
||||
import app.aaps.plugins.sync.nsclient.services.NSClientService
|
||||
import dagger.android.HasAndroidInjector
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.nsShared.NSClientFragment
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientStatus
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiData
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import info.nightscout.plugins.sync.nsclient.data.AlarmAck
|
||||
import info.nightscout.plugins.sync.nsclient.extensions.toJson
|
||||
import info.nightscout.plugins.sync.nsclient.services.NSClientService
|
||||
import io.reactivex.rxjava3.disposables.CompositeDisposable
|
||||
import io.reactivex.rxjava3.kotlin.plusAssign
|
||||
import javax.inject.Inject
|
|
@ -1,7 +1,6 @@
|
|||
package info.nightscout.plugins.sync.nsclient
|
||||
package app.aaps.plugins.sync.nsclient
|
||||
|
||||
import app.aaps.annotations.OpenForTesting
|
||||
import app.aaps.core.main.utils.fabric.FabricPrivacy
|
||||
import app.aaps.core.interfaces.receivers.ReceiverStatusStore
|
||||
import app.aaps.core.interfaces.resources.ResourceHelper
|
||||
import app.aaps.core.interfaces.rx.AapsSchedulers
|
||||
|
@ -10,8 +9,9 @@ import app.aaps.core.interfaces.rx.events.EventChargingState
|
|||
import app.aaps.core.interfaces.rx.events.EventNetworkChange
|
||||
import app.aaps.core.interfaces.rx.events.EventPreferenceChange
|
||||
import app.aaps.core.interfaces.sharedPreferences.SP
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventConnectivityOptionChanged
|
||||
import app.aaps.core.main.utils.fabric.FabricPrivacy
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.nsShared.events.EventConnectivityOptionChanged
|
||||
import io.reactivex.rxjava3.disposables.CompositeDisposable
|
||||
import io.reactivex.rxjava3.kotlin.plusAssign
|
||||
import javax.inject.Inject
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.acks
|
||||
package app.aaps.plugins.sync.nsclient.acks
|
||||
|
||||
import androidx.work.OneTimeWorkRequest
|
||||
import app.aaps.core.interfaces.logging.AAPSLogger
|
||||
|
@ -8,8 +8,8 @@ import app.aaps.core.interfaces.rx.events.Event
|
|||
import app.aaps.core.interfaces.rx.events.EventNSClientRestart
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.utils.receivers.DataWorkerStorage
|
||||
import info.nightscout.plugins.sync.nsclient.services.NSClientService
|
||||
import info.nightscout.plugins.sync.nsclient.workers.NSClientAddAckWorker
|
||||
import app.aaps.plugins.sync.nsclient.services.NSClientService
|
||||
import app.aaps.plugins.sync.nsclient.workers.NSClientAddAckWorker
|
||||
import io.socket.client.Ack
|
||||
import org.json.JSONArray
|
||||
import org.json.JSONObject
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.acks
|
||||
package app.aaps.plugins.sync.nsclient.acks
|
||||
|
||||
import app.aaps.core.interfaces.rx.bus.RxBus
|
||||
import app.aaps.core.interfaces.rx.events.Event
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.acks
|
||||
package app.aaps.plugins.sync.nsclient.acks
|
||||
|
||||
import androidx.work.OneTimeWorkRequest
|
||||
import app.aaps.core.interfaces.logging.AAPSLogger
|
||||
|
@ -7,8 +7,8 @@ import app.aaps.core.interfaces.rx.bus.RxBus
|
|||
import app.aaps.core.interfaces.rx.events.Event
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.utils.receivers.DataWorkerStorage
|
||||
import info.nightscout.plugins.sync.nsclient.services.NSClientService
|
||||
import info.nightscout.plugins.sync.nsclient.workers.NSClientUpdateRemoveAckWorker
|
||||
import app.aaps.plugins.sync.nsclient.services.NSClientService
|
||||
import app.aaps.plugins.sync.nsclient.workers.NSClientUpdateRemoveAckWorker
|
||||
import io.socket.client.Ack
|
||||
import org.json.JSONException
|
||||
import org.json.JSONObject
|
|
@ -0,0 +1,11 @@
|
|||
package app.aaps.plugins.sync.nsclient.data
|
||||
|
||||
/**
|
||||
* Created by mike on 11.06.2017.
|
||||
*/
|
||||
class AlarmAck {
|
||||
|
||||
var level: Int? = null
|
||||
var group: String? = null
|
||||
var silenceTime: Long? = null
|
||||
}
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.data
|
||||
package app.aaps.plugins.sync.nsclient.data
|
||||
|
||||
import app.aaps.annotations.OpenForTesting
|
||||
import app.aaps.core.interfaces.configuration.Config
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.data
|
||||
package app.aaps.plugins.sync.nsclient.data
|
||||
|
||||
import app.aaps.core.utils.JsonHelper
|
||||
import org.json.JSONObject
|
|
@ -1,6 +1,6 @@
|
|||
@file:Suppress("SpellCheckingInspection")
|
||||
|
||||
package info.nightscout.plugins.sync.nsclient.data
|
||||
package app.aaps.plugins.sync.nsclient.data
|
||||
|
||||
import android.content.Context
|
||||
import app.aaps.annotations.OpenForTesting
|
||||
|
@ -20,7 +20,7 @@ import app.aaps.core.ui.dialogs.OKDialog
|
|||
import app.aaps.core.utils.JsonHelper
|
||||
import app.aaps.database.entities.UserEntry
|
||||
import app.aaps.database.entities.UserEntry.Action
|
||||
import info.nightscout.plugins.sync.R
|
||||
import app.aaps.plugins.sync.R
|
||||
import org.json.JSONException
|
||||
import org.json.JSONObject
|
||||
import javax.inject.Inject
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.data
|
||||
package app.aaps.plugins.sync.nsclient.data
|
||||
|
||||
import android.text.Spanned
|
||||
import app.aaps.core.interfaces.aps.APSResult
|
||||
|
@ -12,8 +12,8 @@ import app.aaps.core.interfaces.utils.Round
|
|||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.core.utils.HtmlHelper
|
||||
import app.aaps.core.utils.JsonHelper
|
||||
import app.aaps.plugins.sync.R
|
||||
import dagger.android.HasAndroidInjector
|
||||
import info.nightscout.plugins.sync.R
|
||||
import javax.inject.Inject
|
||||
import javax.inject.Singleton
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.extensions
|
||||
package app.aaps.plugins.sync.nsclient.extensions
|
||||
|
||||
import app.aaps.core.interfaces.profile.ProfileUtil
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.extensions
|
||||
package app.aaps.plugins.sync.nsclient.extensions
|
||||
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.utils.JsonHelper
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.extensions
|
||||
package app.aaps.plugins.sync.nsclient.extensions
|
||||
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.utils.JsonHelper
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.extensions
|
||||
package app.aaps.plugins.sync.nsclient.extensions
|
||||
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.database.entities.DeviceStatus
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.extensions
|
||||
package app.aaps.plugins.sync.nsclient.extensions
|
||||
|
||||
import app.aaps.core.interfaces.db.GlucoseUnit
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.extensions
|
||||
package app.aaps.plugins.sync.nsclient.extensions
|
||||
|
||||
import app.aaps.core.interfaces.profile.Profile
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.extensions
|
||||
package app.aaps.plugins.sync.nsclient.extensions
|
||||
|
||||
import app.aaps.core.utils.JsonHelper
|
||||
import app.aaps.database.entities.Food
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.extensions
|
||||
package app.aaps.plugins.sync.nsclient.extensions
|
||||
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.interfaces.utils.T
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.extensions
|
||||
package app.aaps.plugins.sync.nsclient.extensions
|
||||
|
||||
import app.aaps.core.interfaces.plugin.ActivePlugin
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.extensions
|
||||
package app.aaps.plugins.sync.nsclient.extensions
|
||||
|
||||
import app.aaps.core.interfaces.profile.Profile
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.extensions
|
||||
package app.aaps.plugins.sync.nsclient.extensions
|
||||
|
||||
import app.aaps.core.interfaces.configuration.Constants
|
||||
import app.aaps.core.interfaces.db.GlucoseUnit
|
|
@ -1,11 +1,11 @@
|
|||
package info.nightscout.plugins.sync.nsclient.extensions
|
||||
package app.aaps.plugins.sync.nsclient.extensions
|
||||
|
||||
import app.aaps.core.interfaces.db.GlucoseUnit
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.core.utils.JsonHelper
|
||||
import app.aaps.database.entities.TherapyEvent
|
||||
import info.nightscout.plugins.sync.nsclient.data.NSMbg
|
||||
import app.aaps.plugins.sync.nsclient.data.NSMbg
|
||||
import org.json.JSONObject
|
||||
|
||||
fun TherapyEvent.GlucoseUnit.toMainUnit(): GlucoseUnit =
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.services
|
||||
package app.aaps.plugins.sync.nsclient.services
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import android.content.Context
|
||||
|
@ -30,6 +30,21 @@ import app.aaps.core.nssdk.localmodel.devicestatus.NSDeviceStatus
|
|||
import app.aaps.core.utils.JsonHelper.safeGetString
|
||||
import app.aaps.core.utils.JsonHelper.safeGetStringAllowNull
|
||||
import app.aaps.core.utils.receivers.DataWorkerStorage
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.nsShared.NSAlarmObject
|
||||
import app.aaps.plugins.sync.nsShared.NsIncomingDataProcessor
|
||||
import app.aaps.plugins.sync.nsShared.events.EventConnectivityOptionChanged
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientStatus
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import app.aaps.plugins.sync.nsclient.DataSyncSelectorV1
|
||||
import app.aaps.plugins.sync.nsclient.NSClientPlugin
|
||||
import app.aaps.plugins.sync.nsclient.acks.NSAddAck
|
||||
import app.aaps.plugins.sync.nsclient.acks.NSAuthAck
|
||||
import app.aaps.plugins.sync.nsclient.acks.NSUpdateAck
|
||||
import app.aaps.plugins.sync.nsclient.data.AlarmAck
|
||||
import app.aaps.plugins.sync.nsclient.data.NSDeviceStatusHandler
|
||||
import app.aaps.plugins.sync.nsclient.workers.NSClientAddUpdateWorker
|
||||
import app.aaps.plugins.sync.nsclient.workers.NSClientMbgWorker
|
||||
import com.google.common.base.Charsets
|
||||
import com.google.common.hash.Hashing
|
||||
import com.google.gson.GsonBuilder
|
||||
|
@ -37,21 +52,6 @@ import com.google.gson.JsonDeserializer
|
|||
import dagger.android.DaggerService
|
||||
import dagger.android.HasAndroidInjector
|
||||
import info.nightscout.database.impl.AppRepository
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.nsShared.NSAlarmObject
|
||||
import info.nightscout.plugins.sync.nsShared.NsIncomingDataProcessor
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventConnectivityOptionChanged
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientStatus
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import info.nightscout.plugins.sync.nsclient.DataSyncSelectorV1
|
||||
import info.nightscout.plugins.sync.nsclient.NSClientPlugin
|
||||
import info.nightscout.plugins.sync.nsclient.acks.NSAddAck
|
||||
import info.nightscout.plugins.sync.nsclient.acks.NSAuthAck
|
||||
import info.nightscout.plugins.sync.nsclient.acks.NSUpdateAck
|
||||
import info.nightscout.plugins.sync.nsclient.data.AlarmAck
|
||||
import info.nightscout.plugins.sync.nsclient.data.NSDeviceStatusHandler
|
||||
import info.nightscout.plugins.sync.nsclient.workers.NSClientAddUpdateWorker
|
||||
import info.nightscout.plugins.sync.nsclient.workers.NSClientMbgWorker
|
||||
import io.reactivex.rxjava3.disposables.CompositeDisposable
|
||||
import io.reactivex.rxjava3.kotlin.plusAssign
|
||||
import io.socket.client.IO
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.workers
|
||||
package app.aaps.plugins.sync.nsclient.workers
|
||||
|
||||
import android.content.Context
|
||||
import android.os.SystemClock
|
||||
|
@ -26,9 +26,9 @@ import app.aaps.core.interfaces.sync.DataSyncSelector.PairTherapyEvent
|
|||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.utils.notifyAll
|
||||
import app.aaps.core.utils.receivers.DataWorkerStorage
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.nsclient.acks.NSAddAck
|
||||
import info.nightscout.database.impl.AppRepository
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.nsclient.acks.NSAddAck
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import javax.inject.Inject
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.workers
|
||||
package app.aaps.plugins.sync.nsclient.workers
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.WorkerParameters
|
||||
|
@ -25,12 +25,12 @@ import app.aaps.database.entities.ProfileSwitch
|
|||
import app.aaps.database.entities.TemporaryBasal
|
||||
import app.aaps.database.entities.TemporaryTarget
|
||||
import app.aaps.database.entities.TherapyEvent
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.nsclient.extensions.extendedBolusFromJson
|
||||
import app.aaps.plugins.sync.nsclient.extensions.fromJson
|
||||
import app.aaps.plugins.sync.nsclient.extensions.isEffectiveProfileSwitch
|
||||
import app.aaps.plugins.sync.nsclient.extensions.temporaryBasalFromJson
|
||||
import info.nightscout.database.impl.AppRepository
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.nsclient.extensions.extendedBolusFromJson
|
||||
import info.nightscout.plugins.sync.nsclient.extensions.fromJson
|
||||
import info.nightscout.plugins.sync.nsclient.extensions.isEffectiveProfileSwitch
|
||||
import info.nightscout.plugins.sync.nsclient.extensions.temporaryBasalFromJson
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import javax.inject.Inject
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.workers
|
||||
package app.aaps.plugins.sync.nsclient.workers
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.WorkerParameters
|
||||
|
@ -8,8 +8,8 @@ import app.aaps.core.interfaces.nsclient.StoreDataForDb
|
|||
import app.aaps.core.interfaces.sharedPreferences.SP
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.utils.receivers.DataWorkerStorage
|
||||
import info.nightscout.plugins.sync.nsclient.data.NSMbg
|
||||
import info.nightscout.plugins.sync.nsclient.extensions.therapyEventFromNsMbg
|
||||
import app.aaps.plugins.sync.nsclient.data.NSMbg
|
||||
import app.aaps.plugins.sync.nsclient.extensions.therapyEventFromNsMbg
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import javax.inject.Inject
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclient.workers
|
||||
package app.aaps.plugins.sync.nsclient.workers
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.WorkerParameters
|
||||
|
@ -21,8 +21,8 @@ import app.aaps.core.interfaces.sync.DataSyncSelector.PairTherapyEvent
|
|||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.utils.notifyAll
|
||||
import app.aaps.core.utils.receivers.DataWorkerStorage
|
||||
import app.aaps.plugins.sync.nsclient.acks.NSUpdateAck
|
||||
import info.nightscout.database.impl.AppRepository
|
||||
import info.nightscout.plugins.sync.nsclient.acks.NSUpdateAck
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import javax.inject.Inject
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3
|
||||
package app.aaps.plugins.sync.nsclientV3
|
||||
|
||||
import app.aaps.annotations.OpenForTesting
|
||||
import app.aaps.core.interfaces.configuration.Config
|
||||
|
@ -13,10 +13,10 @@ import app.aaps.core.interfaces.source.NSClientSource
|
|||
import app.aaps.core.interfaces.sync.DataSyncSelector
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.utils.JsonHelper
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiQueue
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import info.nightscout.database.impl.AppRepository
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiQueue
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import javax.inject.Inject
|
||||
import javax.inject.Singleton
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3
|
||||
package app.aaps.plugins.sync.nsclientV3
|
||||
|
||||
import android.content.Context
|
||||
import android.os.Handler
|
||||
|
@ -57,40 +57,40 @@ import app.aaps.core.nssdk.mapper.toNSTreatment
|
|||
import app.aaps.core.nssdk.remotemodel.LastModified
|
||||
import app.aaps.database.ValueWrapper
|
||||
import app.aaps.database.entities.interfaces.TraceableDBEntry
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.nsShared.NSAlarmObject
|
||||
import app.aaps.plugins.sync.nsShared.NSClientFragment
|
||||
import app.aaps.plugins.sync.nsShared.NsIncomingDataProcessor
|
||||
import app.aaps.plugins.sync.nsShared.events.EventConnectivityOptionChanged
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiData
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import app.aaps.plugins.sync.nsclient.ReceiverDelegate
|
||||
import app.aaps.plugins.sync.nsclient.data.NSDeviceStatusHandler
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSBolus
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSBolusWizard
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSCarbs
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSDeviceStatus
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSEffectiveProfileSwitch
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSExtendedBolus
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSFood
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSOfflineEvent
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSProfileSwitch
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSSvgV3
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSTemporaryBasal
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSTemporaryTarget
|
||||
import app.aaps.plugins.sync.nsclientV3.extensions.toNSTherapyEvent
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.DataSyncWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadBgWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadDeviceStatusWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadFoodsWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadLastModificationWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadProfileStoreWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadStatusWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.workers.LoadTreatmentsWorker
|
||||
import com.google.gson.Gson
|
||||
import com.google.gson.GsonBuilder
|
||||
import dagger.android.HasAndroidInjector
|
||||
import info.nightscout.database.impl.AppRepository
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.nsShared.NSAlarmObject
|
||||
import info.nightscout.plugins.sync.nsShared.NSClientFragment
|
||||
import info.nightscout.plugins.sync.nsShared.NsIncomingDataProcessor
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventConnectivityOptionChanged
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiData
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import info.nightscout.plugins.sync.nsclient.ReceiverDelegate
|
||||
import info.nightscout.plugins.sync.nsclient.data.NSDeviceStatusHandler
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSBolus
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSBolusWizard
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSCarbs
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSDeviceStatus
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSEffectiveProfileSwitch
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSExtendedBolus
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSFood
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSOfflineEvent
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSProfileSwitch
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSSvgV3
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSTemporaryBasal
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSTemporaryTarget
|
||||
import info.nightscout.plugins.sync.nsclientV3.extensions.toNSTherapyEvent
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.DataSyncWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadBgWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadDeviceStatusWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadFoodsWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadLastModificationWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadProfileStoreWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadStatusWorker
|
||||
import info.nightscout.plugins.sync.nsclientV3.workers.LoadTreatmentsWorker
|
||||
import io.reactivex.rxjava3.disposables.CompositeDisposable
|
||||
import io.reactivex.rxjava3.kotlin.plusAssign
|
||||
import io.socket.client.Ack
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.core.nssdk.localmodel.entry.NsUnits
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.core.nssdk.localmodel.treatment.EventType
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.core.nssdk.localmodel.treatment.EventType
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.nssdk.localmodel.devicestatus.NSDeviceStatus
|
||||
import app.aaps.database.entities.DeviceStatus
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.interfaces.utils.T
|
||||
|
@ -8,7 +8,7 @@ import app.aaps.core.nssdk.localmodel.treatment.EventType
|
|||
import app.aaps.core.nssdk.localmodel.treatment.NSEffectiveProfileSwitch
|
||||
import app.aaps.database.entities.EffectiveProfileSwitch
|
||||
import app.aaps.database.entities.embedments.InterfaceIDs
|
||||
import info.nightscout.plugins.sync.nsclient.extensions.fromConstant
|
||||
import app.aaps.plugins.sync.nsclient.extensions.fromConstant
|
||||
import java.security.InvalidParameterException
|
||||
|
||||
fun NSEffectiveProfileSwitch.toEffectiveProfileSwitch(dateUtil: DateUtil): EffectiveProfileSwitch? {
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.interfaces.profile.Profile
|
||||
import app.aaps.core.interfaces.utils.T
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.nssdk.localmodel.food.NSFood
|
||||
import app.aaps.database.entities.Food
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.core.nssdk.localmodel.entry.Direction
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.core.nssdk.localmodel.treatment.EventType
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.interfaces.plugin.ActivePlugin
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.interfaces.profile.Profile
|
||||
import app.aaps.core.interfaces.utils.T
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.core.nssdk.localmodel.entry.NsUnits
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.extensions
|
||||
package app.aaps.plugins.sync.nsclientV3.extensions
|
||||
|
||||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.core.nssdk.localmodel.entry.NsUnits
|
|
@ -1,14 +1,14 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.workers
|
||||
package app.aaps.plugins.sync.nsclientV3.workers
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.WorkerParameters
|
||||
import app.aaps.annotations.OpenForTesting
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.interfaces.plugin.ActivePlugin
|
||||
import app.aaps.core.interfaces.rx.bus.RxBus
|
||||
import app.aaps.core.interfaces.rx.events.EventNSClientNewLog
|
||||
import info.nightscout.plugins.sync.nsclientV3.DataSyncSelectorV3
|
||||
import info.nightscout.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.DataSyncSelectorV3
|
||||
import app.aaps.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import javax.inject.Inject
|
||||
|
|
@ -1,9 +1,8 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.workers
|
||||
package app.aaps.plugins.sync.nsclientV3.workers
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.WorkerParameters
|
||||
import androidx.work.workDataOf
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.interfaces.logging.LTag
|
||||
import app.aaps.core.interfaces.nsclient.StoreDataForDb
|
||||
import app.aaps.core.interfaces.rx.bus.RxBus
|
||||
|
@ -12,10 +11,11 @@ import app.aaps.core.interfaces.sharedPreferences.SP
|
|||
import app.aaps.core.interfaces.source.NSClientSource
|
||||
import app.aaps.core.interfaces.sync.NsClient
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import info.nightscout.plugins.sync.nsShared.NsIncomingDataProcessor
|
||||
import info.nightscout.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.nssdk.interfaces.NSAndroidClient
|
||||
import app.aaps.core.nssdk.localmodel.entry.NSSgvV3
|
||||
import app.aaps.plugins.sync.nsShared.NsIncomingDataProcessor
|
||||
import app.aaps.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import javax.inject.Inject
|
||||
import kotlin.math.max
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.workers
|
||||
package app.aaps.plugins.sync.nsclientV3.workers
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.WorkerParameters
|
||||
|
@ -9,8 +9,8 @@ import app.aaps.core.interfaces.utils.DateUtil
|
|||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.utils.receivers.DataWorkerStorage
|
||||
import info.nightscout.plugins.sync.nsclient.data.NSDeviceStatusHandler
|
||||
import info.nightscout.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import app.aaps.plugins.sync.nsclient.data.NSDeviceStatusHandler
|
||||
import app.aaps.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import javax.inject.Inject
|
||||
|
|
@ -1,17 +1,17 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.workers
|
||||
package app.aaps.plugins.sync.nsclientV3.workers
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.WorkerParameters
|
||||
import androidx.work.workDataOf
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.interfaces.logging.LTag
|
||||
import app.aaps.core.interfaces.nsclient.StoreDataForDb
|
||||
import app.aaps.core.interfaces.rx.bus.RxBus
|
||||
import app.aaps.core.interfaces.rx.events.EventNSClientNewLog
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import info.nightscout.plugins.sync.nsShared.NsIncomingDataProcessor
|
||||
import info.nightscout.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.nssdk.localmodel.food.NSFood
|
||||
import app.aaps.plugins.sync.nsShared.NsIncomingDataProcessor
|
||||
import app.aaps.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import javax.inject.Inject
|
||||
|
|
@ -1,13 +1,13 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.workers
|
||||
package app.aaps.plugins.sync.nsclientV3.workers
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.WorkerParameters
|
||||
import androidx.work.workDataOf
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.interfaces.logging.LTag
|
||||
import app.aaps.core.interfaces.rx.bus.RxBus
|
||||
import app.aaps.core.interfaces.rx.events.EventNSClientNewLog
|
||||
import info.nightscout.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import javax.inject.Inject
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.workers
|
||||
package app.aaps.plugins.sync.nsclientV3.workers
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.WorkerParameters
|
||||
|
@ -12,8 +12,8 @@ import app.aaps.core.main.utils.worker.LoggingWorker
|
|||
import app.aaps.core.nssdk.interfaces.NSAndroidClient
|
||||
import app.aaps.core.utils.JsonHelper
|
||||
import app.aaps.core.utils.receivers.DataWorkerStorage
|
||||
import info.nightscout.plugins.sync.nsShared.NsIncomingDataProcessor
|
||||
import info.nightscout.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import app.aaps.plugins.sync.nsShared.NsIncomingDataProcessor
|
||||
import app.aaps.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import org.json.JSONObject
|
||||
import javax.inject.Inject
|
|
@ -1,14 +1,14 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.workers
|
||||
package app.aaps.plugins.sync.nsclientV3.workers
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.WorkerParameters
|
||||
import androidx.work.workDataOf
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.interfaces.logging.LTag
|
||||
import app.aaps.core.interfaces.rx.bus.RxBus
|
||||
import app.aaps.core.interfaces.rx.events.EventNSClientNewLog
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import info.nightscout.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.plugins.sync.nsShared.events.EventNSClientUpdateGuiStatus
|
||||
import app.aaps.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import javax.inject.Inject
|
||||
|
|
@ -1,19 +1,19 @@
|
|||
package info.nightscout.plugins.sync.nsclientV3.workers
|
||||
package app.aaps.plugins.sync.nsclientV3.workers
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.WorkerParameters
|
||||
import androidx.work.workDataOf
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.interfaces.logging.LTag
|
||||
import app.aaps.core.interfaces.nsclient.StoreDataForDb
|
||||
import app.aaps.core.interfaces.rx.bus.RxBus
|
||||
import app.aaps.core.interfaces.rx.events.EventNSClientNewLog
|
||||
import app.aaps.core.interfaces.sync.NsClient
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import info.nightscout.plugins.sync.nsShared.NsIncomingDataProcessor
|
||||
import info.nightscout.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import app.aaps.core.main.utils.worker.LoggingWorker
|
||||
import app.aaps.core.nssdk.interfaces.NSAndroidClient
|
||||
import app.aaps.core.nssdk.localmodel.treatment.NSTreatment
|
||||
import app.aaps.plugins.sync.nsShared.NsIncomingDataProcessor
|
||||
import app.aaps.plugins.sync.nsclientV3.NSClientV3Plugin
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import javax.inject.Inject
|
||||
import kotlin.math.max
|
|
@ -1,6 +1,6 @@
|
|||
package info.nightscout.plugins.sync.openhumans
|
||||
package app.aaps.plugins.sync.openhumans
|
||||
|
||||
import java.util.*
|
||||
import java.util.Locale
|
||||
|
||||
internal fun String.isAllowedKey() = if (startsWith("ConfigBuilder_")) true else allowedKeys.contains(this.uppercase(Locale.ROOT))
|
||||
|
|
@ -1,11 +1,11 @@
|
|||
package info.nightscout.plugins.sync.openhumans
|
||||
package app.aaps.plugins.sync.openhumans
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import android.util.Base64
|
||||
import info.nightscout.plugins.sync.di.BaseUrl
|
||||
import info.nightscout.plugins.sync.di.ClientId
|
||||
import info.nightscout.plugins.sync.di.ClientSecret
|
||||
import info.nightscout.plugins.sync.di.RedirectUrl
|
||||
import app.aaps.plugins.sync.di.BaseUrl
|
||||
import app.aaps.plugins.sync.di.ClientId
|
||||
import app.aaps.plugins.sync.di.ClientSecret
|
||||
import app.aaps.plugins.sync.di.RedirectUrl
|
||||
import kotlinx.coroutines.ExperimentalCoroutinesApi
|
||||
import kotlinx.coroutines.suspendCancellableCoroutine
|
||||
import okhttp3.*
|
||||
|
@ -28,20 +28,25 @@ internal class OpenHumansAPI @Inject constructor(
|
|||
@RedirectUrl
|
||||
private val redirectUrl: String
|
||||
) {
|
||||
|
||||
private val authHeader = "Basic " + Base64.encodeToString("$clientId:$clientSecret".toByteArray(), Base64.NO_WRAP)
|
||||
private val client = OkHttpClient()
|
||||
|
||||
suspend fun exchangeBearerToken(bearerToken: String) = sendTokenRequest(FormBody.Builder()
|
||||
suspend fun exchangeBearerToken(bearerToken: String) = sendTokenRequest(
|
||||
FormBody.Builder()
|
||||
.add("grant_type", "authorization_code")
|
||||
.add("redirect_uri", redirectUrl)
|
||||
.add("code", bearerToken)
|
||||
.build())
|
||||
.build()
|
||||
)
|
||||
|
||||
suspend fun refreshAccessToken(refreshToken: String) = sendTokenRequest(FormBody.Builder()
|
||||
suspend fun refreshAccessToken(refreshToken: String) = sendTokenRequest(
|
||||
FormBody.Builder()
|
||||
.add("grant_type", "refresh_token")
|
||||
.add("redirect_uri", redirectUrl)
|
||||
.add("refresh_token", refreshToken)
|
||||
.build())
|
||||
.build()
|
||||
)
|
||||
|
||||
private suspend fun sendTokenRequest(body: FormBody): OAuthTokens {
|
||||
val timestamp = System.currentTimeMillis()
|
||||
|
@ -74,10 +79,12 @@ internal class OpenHumansAPI @Inject constructor(
|
|||
suspend fun prepareFileUpload(accessToken: String, fileName: String, metadata: FileMetadata): PreparedUpload {
|
||||
val request = Request.Builder()
|
||||
.url("$baseUrl/api/direct-sharing/project/files/upload/direct/?access_token=$accessToken")
|
||||
.post(FormBody.Builder()
|
||||
.post(
|
||||
FormBody.Builder()
|
||||
.add("filename", fileName)
|
||||
.add("metadata", metadata.toJSON().toString())
|
||||
.build())
|
||||
.build()
|
||||
)
|
||||
.build()
|
||||
val response = request.await()
|
||||
val json = response.body?.let { JSONObject(it.string()) }
|
||||
|
@ -108,9 +115,11 @@ internal class OpenHumansAPI @Inject constructor(
|
|||
suspend fun completeFileUpload(accessToken: String, fileId: String) {
|
||||
val request = Request.Builder()
|
||||
.url("$baseUrl/api/direct-sharing/project/files/upload/complete/?access_token=$accessToken")
|
||||
.post(FormBody.Builder()
|
||||
.post(
|
||||
FormBody.Builder()
|
||||
.add("file_id", fileId)
|
||||
.build())
|
||||
.build()
|
||||
)
|
||||
.build()
|
||||
val response = request.await()
|
||||
if (!response.isSuccessful) throw OHHttpException(response.code, response.message, null)
|
||||
|
@ -170,6 +179,7 @@ internal class OpenHumansAPI @Inject constructor(
|
|||
val meaning: String,
|
||||
val detail: String?
|
||||
) : RuntimeException() {
|
||||
|
||||
override val message: String get() = toString()
|
||||
}
|
||||
|
||||
|
@ -178,6 +188,7 @@ internal class OpenHumansAPI @Inject constructor(
|
|||
) : RuntimeException()
|
||||
|
||||
private companion object {
|
||||
|
||||
@SuppressLint("SimpleDateFormat")
|
||||
val iso8601DateFormatter = SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSXXX")
|
||||
}
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.openhumans
|
||||
package app.aaps.plugins.sync.openhumans
|
||||
|
||||
internal data class OpenHumansState(
|
||||
val accessToken: String,
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.openhumans
|
||||
package app.aaps.plugins.sync.openhumans
|
||||
|
||||
import android.app.NotificationChannel
|
||||
import android.app.NotificationManager
|
||||
|
@ -29,14 +29,14 @@ import app.aaps.core.interfaces.sharedPreferences.SP
|
|||
import app.aaps.core.interfaces.sync.Sync
|
||||
import app.aaps.database.entities.data.Block
|
||||
import app.aaps.database.entities.interfaces.TraceableDBEntry
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.openhumans.delegates.OHAppIDDelegate
|
||||
import app.aaps.plugins.sync.openhumans.delegates.OHCounterDelegate
|
||||
import app.aaps.plugins.sync.openhumans.delegates.OHStateDelegate
|
||||
import app.aaps.plugins.sync.openhumans.ui.OHFragment
|
||||
import app.aaps.plugins.sync.openhumans.ui.OHLoginActivity
|
||||
import dagger.android.HasAndroidInjector
|
||||
import info.nightscout.database.impl.AppRepository
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.openhumans.delegates.OHAppIDDelegate
|
||||
import info.nightscout.plugins.sync.openhumans.delegates.OHCounterDelegate
|
||||
import info.nightscout.plugins.sync.openhumans.delegates.OHStateDelegate
|
||||
import info.nightscout.plugins.sync.openhumans.ui.OHFragment
|
||||
import info.nightscout.plugins.sync.openhumans.ui.OHLoginActivity
|
||||
import io.reactivex.rxjava3.disposables.CompositeDisposable
|
||||
import io.reactivex.rxjava3.kotlin.plusAssign
|
||||
import kotlinx.coroutines.Dispatchers
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.openhumans
|
||||
package app.aaps.plugins.sync.openhumans
|
||||
|
||||
import android.content.Context
|
||||
import androidx.work.CoroutineWorker
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.openhumans.delegates
|
||||
package app.aaps.plugins.sync.openhumans.delegates
|
||||
|
||||
import app.aaps.core.interfaces.sharedPreferences.SP
|
||||
import java.util.UUID
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.openhumans.delegates
|
||||
package app.aaps.plugins.sync.openhumans.delegates
|
||||
|
||||
import app.aaps.core.interfaces.sharedPreferences.SP
|
||||
import javax.inject.Inject
|
|
@ -1,9 +1,9 @@
|
|||
package info.nightscout.plugins.sync.openhumans.delegates
|
||||
package app.aaps.plugins.sync.openhumans.delegates
|
||||
|
||||
import androidx.lifecycle.LiveData
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import app.aaps.core.interfaces.sharedPreferences.SP
|
||||
import info.nightscout.plugins.sync.openhumans.OpenHumansState
|
||||
import app.aaps.plugins.sync.openhumans.OpenHumansState
|
||||
import javax.inject.Inject
|
||||
import javax.inject.Singleton
|
||||
import kotlin.reflect.KProperty
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.openhumans.ui
|
||||
package app.aaps.plugins.sync.openhumans.ui
|
||||
|
||||
import android.content.Intent
|
||||
import android.os.Bundle
|
||||
|
@ -8,11 +8,11 @@ import android.view.ViewGroup
|
|||
import android.widget.TextView
|
||||
import androidx.appcompat.view.ContextThemeWrapper
|
||||
import androidx.lifecycle.LiveData
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.openhumans.OpenHumansState
|
||||
import app.aaps.plugins.sync.openhumans.OpenHumansUploaderPlugin
|
||||
import com.google.android.material.button.MaterialButton
|
||||
import dagger.android.support.DaggerFragment
|
||||
import info.nightscout.plugins.sync.openhumans.OpenHumansState
|
||||
import info.nightscout.plugins.sync.openhumans.OpenHumansUploaderPlugin
|
||||
import info.nightscout.plugins.sync.R
|
||||
import javax.inject.Inject
|
||||
|
||||
class OHFragment : DaggerFragment() {
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.openhumans.ui
|
||||
package app.aaps.plugins.sync.openhumans.ui
|
||||
|
||||
import android.content.Intent
|
||||
import android.net.Uri
|
||||
|
@ -13,12 +13,12 @@ import androidx.core.view.WindowCompat
|
|||
import androidx.core.view.WindowInsetsCompat
|
||||
import androidx.core.view.updatePadding
|
||||
import androidx.core.widget.NestedScrollView
|
||||
import app.aaps.core.ui.activities.TranslatedDaggerAppCompatActivity
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.di.AuthUrl
|
||||
import app.aaps.plugins.sync.di.ViewModelFactory
|
||||
import com.google.android.material.appbar.MaterialToolbar
|
||||
import com.google.android.material.button.MaterialButton
|
||||
import app.aaps.core.ui.activities.TranslatedDaggerAppCompatActivity
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.di.AuthUrl
|
||||
import info.nightscout.plugins.sync.di.ViewModelFactory
|
||||
import javax.inject.Inject
|
||||
|
||||
class OHLoginActivity : TranslatedDaggerAppCompatActivity() {
|
|
@ -1,9 +1,9 @@
|
|||
package info.nightscout.plugins.sync.openhumans.ui
|
||||
package app.aaps.plugins.sync.openhumans.ui
|
||||
|
||||
import androidx.lifecycle.LiveData
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import androidx.lifecycle.ViewModel
|
||||
import info.nightscout.plugins.sync.openhumans.OpenHumansUploaderPlugin
|
||||
import app.aaps.plugins.sync.openhumans.OpenHumansUploaderPlugin
|
||||
import kotlinx.coroutines.CoroutineScope
|
||||
import kotlinx.coroutines.MainScope
|
||||
import kotlinx.coroutines.launch
|
||||
|
@ -27,10 +27,12 @@ internal class OHLoginViewModel @Inject constructor(
|
|||
_state.value = State.WELCOME
|
||||
true
|
||||
}
|
||||
|
||||
State.CONFIRM -> {
|
||||
_state.value = State.CONSENT
|
||||
true
|
||||
}
|
||||
|
||||
else -> false
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool
|
||||
package app.aaps.plugins.sync.tidepool
|
||||
|
||||
import android.os.Bundle
|
||||
import android.view.LayoutInflater
|
||||
|
@ -11,18 +11,18 @@ import android.widget.ScrollView
|
|||
import androidx.core.view.MenuCompat
|
||||
import androidx.core.view.MenuProvider
|
||||
import androidx.lifecycle.Lifecycle
|
||||
import app.aaps.core.main.utils.fabric.FabricPrivacy
|
||||
import app.aaps.core.interfaces.resources.ResourceHelper
|
||||
import app.aaps.core.interfaces.rx.AapsSchedulers
|
||||
import app.aaps.core.interfaces.rx.bus.RxBus
|
||||
import app.aaps.core.interfaces.sharedPreferences.SP
|
||||
import app.aaps.core.main.utils.fabric.FabricPrivacy
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.databinding.TidepoolFragmentBinding
|
||||
import app.aaps.plugins.sync.tidepool.comm.TidepoolUploader
|
||||
import app.aaps.plugins.sync.tidepool.events.EventTidepoolDoUpload
|
||||
import app.aaps.plugins.sync.tidepool.events.EventTidepoolResetData
|
||||
import app.aaps.plugins.sync.tidepool.events.EventTidepoolUpdateGUI
|
||||
import dagger.android.support.DaggerFragment
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.databinding.TidepoolFragmentBinding
|
||||
import info.nightscout.plugins.sync.tidepool.comm.TidepoolUploader
|
||||
import info.nightscout.plugins.sync.tidepool.events.EventTidepoolDoUpload
|
||||
import info.nightscout.plugins.sync.tidepool.events.EventTidepoolResetData
|
||||
import info.nightscout.plugins.sync.tidepool.events.EventTidepoolUpdateGUI
|
||||
import io.reactivex.rxjava3.disposables.CompositeDisposable
|
||||
import io.reactivex.rxjava3.kotlin.plusAssign
|
||||
import javax.inject.Inject
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool
|
||||
package app.aaps.plugins.sync.tidepool
|
||||
|
||||
import android.content.Context
|
||||
import android.text.Spanned
|
||||
|
@ -24,17 +24,17 @@ import app.aaps.core.interfaces.ui.UiInteraction
|
|||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.core.main.utils.fabric.FabricPrivacy
|
||||
import app.aaps.core.utils.HtmlHelper
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.nsShared.events.EventConnectivityOptionChanged
|
||||
import app.aaps.plugins.sync.nsclient.ReceiverDelegate
|
||||
import app.aaps.plugins.sync.tidepool.comm.TidepoolUploader
|
||||
import app.aaps.plugins.sync.tidepool.comm.UploadChunk
|
||||
import app.aaps.plugins.sync.tidepool.events.EventTidepoolDoUpload
|
||||
import app.aaps.plugins.sync.tidepool.events.EventTidepoolResetData
|
||||
import app.aaps.plugins.sync.tidepool.events.EventTidepoolStatus
|
||||
import app.aaps.plugins.sync.tidepool.events.EventTidepoolUpdateGUI
|
||||
import app.aaps.plugins.sync.tidepool.utils.RateLimit
|
||||
import dagger.android.HasAndroidInjector
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.nsShared.events.EventConnectivityOptionChanged
|
||||
import info.nightscout.plugins.sync.nsclient.ReceiverDelegate
|
||||
import info.nightscout.plugins.sync.tidepool.comm.TidepoolUploader
|
||||
import info.nightscout.plugins.sync.tidepool.comm.UploadChunk
|
||||
import info.nightscout.plugins.sync.tidepool.events.EventTidepoolDoUpload
|
||||
import info.nightscout.plugins.sync.tidepool.events.EventTidepoolResetData
|
||||
import info.nightscout.plugins.sync.tidepool.events.EventTidepoolStatus
|
||||
import info.nightscout.plugins.sync.tidepool.events.EventTidepoolUpdateGUI
|
||||
import info.nightscout.plugins.sync.tidepool.utils.RateLimit
|
||||
import io.reactivex.rxjava3.disposables.CompositeDisposable
|
||||
import io.reactivex.rxjava3.kotlin.plusAssign
|
||||
import javax.inject.Inject
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool.comm
|
||||
package app.aaps.plugins.sync.tidepool.comm
|
||||
|
||||
import app.aaps.core.interfaces.logging.AAPSLogger
|
||||
import app.aaps.core.interfaces.logging.LTag
|
|
@ -1,7 +1,7 @@
|
|||
package info.nightscout.plugins.sync.tidepool.comm
|
||||
package app.aaps.plugins.sync.tidepool.comm
|
||||
|
||||
import info.nightscout.plugins.sync.tidepool.messages.AuthReplyMessage
|
||||
import info.nightscout.plugins.sync.tidepool.messages.DatasetReplyMessage
|
||||
import app.aaps.plugins.sync.tidepool.messages.AuthReplyMessage
|
||||
import app.aaps.plugins.sync.tidepool.messages.DatasetReplyMessage
|
||||
import okhttp3.Headers
|
||||
|
||||
class Session(
|
|
@ -1,8 +1,8 @@
|
|||
package info.nightscout.plugins.sync.tidepool.comm
|
||||
package app.aaps.plugins.sync.tidepool.comm
|
||||
|
||||
import info.nightscout.plugins.sync.tidepool.messages.AuthReplyMessage
|
||||
import info.nightscout.plugins.sync.tidepool.messages.DatasetReplyMessage
|
||||
import info.nightscout.plugins.sync.tidepool.messages.UploadReplyMessage
|
||||
import app.aaps.plugins.sync.tidepool.messages.AuthReplyMessage
|
||||
import app.aaps.plugins.sync.tidepool.messages.DatasetReplyMessage
|
||||
import app.aaps.plugins.sync.tidepool.messages.UploadReplyMessage
|
||||
import okhttp3.RequestBody
|
||||
import retrofit2.Call
|
||||
import retrofit2.http.Body
|
||||
|
@ -35,10 +35,12 @@ interface TidepoolApiService {
|
|||
fun deleteDataSet(@Header(SESSION_TOKEN_HEADER) token: String, @Path("dataSetId") id: String): Call<DatasetReplyMessage>
|
||||
|
||||
@GET("/v1/users/{userId}/data_sets")
|
||||
fun getOpenDataSets(@Header(SESSION_TOKEN_HEADER) token: String,
|
||||
fun getOpenDataSets(
|
||||
@Header(SESSION_TOKEN_HEADER) token: String,
|
||||
@Path("userId") id: String,
|
||||
@Query("client.name") clientName: String,
|
||||
@Query("size") size: Int): Call<List<DatasetReplyMessage>>
|
||||
@Query("size") size: Int
|
||||
): Call<List<DatasetReplyMessage>>
|
||||
|
||||
@GET("/v1/datasets/{dataSetId}")
|
||||
fun getDataSet(@Header(SESSION_TOKEN_HEADER) token: String, @Path("dataSetId") id: String): Call<DatasetReplyMessage>
|
|
@ -1,9 +1,9 @@
|
|||
package info.nightscout.plugins.sync.tidepool.comm
|
||||
package app.aaps.plugins.sync.tidepool.comm
|
||||
|
||||
import app.aaps.core.interfaces.logging.AAPSLogger
|
||||
import app.aaps.core.interfaces.logging.LTag
|
||||
import app.aaps.core.interfaces.rx.bus.RxBus
|
||||
import info.nightscout.plugins.sync.tidepool.events.EventTidepoolStatus
|
||||
import app.aaps.plugins.sync.tidepool.events.EventTidepoolStatus
|
||||
import retrofit2.Call
|
||||
import retrofit2.Callback
|
||||
import retrofit2.Response
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool.comm
|
||||
package app.aaps.plugins.sync.tidepool.comm
|
||||
|
||||
import android.content.Context
|
||||
import android.os.PowerManager
|
||||
|
@ -12,14 +12,14 @@ import app.aaps.core.interfaces.sharedPreferences.SP
|
|||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.core.ui.dialogs.OKDialog
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.nsclient.ReceiverDelegate
|
||||
import info.nightscout.plugins.sync.tidepool.events.EventTidepoolStatus
|
||||
import info.nightscout.plugins.sync.tidepool.messages.AuthReplyMessage
|
||||
import info.nightscout.plugins.sync.tidepool.messages.AuthRequestMessage
|
||||
import info.nightscout.plugins.sync.tidepool.messages.DatasetReplyMessage
|
||||
import info.nightscout.plugins.sync.tidepool.messages.OpenDatasetRequestMessage
|
||||
import info.nightscout.plugins.sync.tidepool.messages.UploadReplyMessage
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.nsclient.ReceiverDelegate
|
||||
import app.aaps.plugins.sync.tidepool.events.EventTidepoolStatus
|
||||
import app.aaps.plugins.sync.tidepool.messages.AuthReplyMessage
|
||||
import app.aaps.plugins.sync.tidepool.messages.AuthRequestMessage
|
||||
import app.aaps.plugins.sync.tidepool.messages.DatasetReplyMessage
|
||||
import app.aaps.plugins.sync.tidepool.messages.OpenDatasetRequestMessage
|
||||
import app.aaps.plugins.sync.tidepool.messages.UploadReplyMessage
|
||||
import okhttp3.MediaType.Companion.toMediaTypeOrNull
|
||||
import okhttp3.OkHttpClient
|
||||
import okhttp3.RequestBody.Companion.toRequestBody
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool.comm
|
||||
package app.aaps.plugins.sync.tidepool.comm
|
||||
|
||||
import app.aaps.core.interfaces.logging.AAPSLogger
|
||||
import app.aaps.core.interfaces.logging.LTag
|
||||
|
@ -11,17 +11,17 @@ import app.aaps.core.interfaces.utils.DateUtil
|
|||
import app.aaps.core.interfaces.utils.T
|
||||
import app.aaps.database.entities.EffectiveProfileSwitch
|
||||
import app.aaps.database.entities.TemporaryBasal
|
||||
import app.aaps.plugins.sync.R
|
||||
import app.aaps.plugins.sync.tidepool.elements.BasalElement
|
||||
import app.aaps.plugins.sync.tidepool.elements.BaseElement
|
||||
import app.aaps.plugins.sync.tidepool.elements.BloodGlucoseElement
|
||||
import app.aaps.plugins.sync.tidepool.elements.BolusElement
|
||||
import app.aaps.plugins.sync.tidepool.elements.ProfileElement
|
||||
import app.aaps.plugins.sync.tidepool.elements.SensorGlucoseElement
|
||||
import app.aaps.plugins.sync.tidepool.elements.WizardElement
|
||||
import app.aaps.plugins.sync.tidepool.events.EventTidepoolStatus
|
||||
import app.aaps.plugins.sync.tidepool.utils.GsonInstance
|
||||
import info.nightscout.database.impl.AppRepository
|
||||
import info.nightscout.plugins.sync.R
|
||||
import info.nightscout.plugins.sync.tidepool.elements.BasalElement
|
||||
import info.nightscout.plugins.sync.tidepool.elements.BaseElement
|
||||
import info.nightscout.plugins.sync.tidepool.elements.BloodGlucoseElement
|
||||
import info.nightscout.plugins.sync.tidepool.elements.BolusElement
|
||||
import info.nightscout.plugins.sync.tidepool.elements.ProfileElement
|
||||
import info.nightscout.plugins.sync.tidepool.elements.SensorGlucoseElement
|
||||
import info.nightscout.plugins.sync.tidepool.elements.WizardElement
|
||||
import info.nightscout.plugins.sync.tidepool.events.EventTidepoolStatus
|
||||
import info.nightscout.plugins.sync.tidepool.utils.GsonInstance
|
||||
import java.util.LinkedList
|
||||
import javax.inject.Inject
|
||||
import javax.inject.Singleton
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool.elements
|
||||
package app.aaps.plugins.sync.tidepool.elements
|
||||
|
||||
import app.aaps.core.interfaces.profile.Profile
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool.elements
|
||||
package app.aaps.plugins.sync.tidepool.elements
|
||||
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import com.google.gson.annotations.Expose
|
|
@ -1,10 +1,10 @@
|
|||
package info.nightscout.plugins.sync.tidepool.elements
|
||||
package app.aaps.plugins.sync.tidepool.elements
|
||||
|
||||
import app.aaps.core.interfaces.profile.ProfileUtil
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.database.entities.TherapyEvent
|
||||
import app.aaps.plugins.sync.nsclient.extensions.toMainUnit
|
||||
import com.google.gson.annotations.Expose
|
||||
import info.nightscout.plugins.sync.nsclient.extensions.toMainUnit
|
||||
import java.util.LinkedList
|
||||
import java.util.UUID
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool.elements
|
||||
package app.aaps.plugins.sync.tidepool.elements
|
||||
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.database.entities.Bolus
|
|
@ -1,12 +1,12 @@
|
|||
package info.nightscout.plugins.sync.tidepool.elements
|
||||
package app.aaps.plugins.sync.tidepool.elements
|
||||
|
||||
import app.aaps.core.interfaces.profile.Profile
|
||||
import app.aaps.core.interfaces.profile.ProfileUtil
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.core.main.profile.ProfileSealed
|
||||
import app.aaps.database.entities.EffectiveProfileSwitch
|
||||
import app.aaps.plugins.sync.tidepool.comm.TidepoolUploader
|
||||
import com.google.gson.annotations.Expose
|
||||
import info.nightscout.plugins.sync.tidepool.comm.TidepoolUploader
|
||||
import java.util.UUID
|
||||
|
||||
class ProfileElement(ps: EffectiveProfileSwitch, serialNumber: String, dateUtil: DateUtil, profileUtil: ProfileUtil) :
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool.elements
|
||||
package app.aaps.plugins.sync.tidepool.elements
|
||||
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.database.entities.GlucoseValue
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool.elements
|
||||
package app.aaps.plugins.sync.tidepool.elements
|
||||
|
||||
import app.aaps.core.interfaces.utils.DateUtil
|
||||
import app.aaps.database.entities.Bolus
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool.events
|
||||
package app.aaps.plugins.sync.tidepool.events
|
||||
|
||||
import app.aaps.core.interfaces.rx.events.Event
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool.events
|
||||
package app.aaps.plugins.sync.tidepool.events
|
||||
|
||||
import app.aaps.core.interfaces.rx.events.Event
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package info.nightscout.plugins.sync.tidepool.events
|
||||
package app.aaps.plugins.sync.tidepool.events
|
||||
|
||||
import app.aaps.core.interfaces.rx.events.Event
|
||||
import java.text.SimpleDateFormat
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue