Home
last modified time | relevance | path

Searched refs:WifiNetworkModel (Results 1 – 25 of 33) sorted by relevance

12

/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/pipeline/wifi/ui/model/
DWifiIcon.kt32 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
77 model: WifiNetworkModel, in fromModel()
82 is WifiNetworkModel.Unavailable -> Hidden in fromModel()
83 is WifiNetworkModel.Invalid -> Hidden in fromModel()
84 is WifiNetworkModel.CarrierMerged -> Hidden in fromModel()
85 is WifiNetworkModel.Inactive -> in fromModel()
94 is WifiNetworkModel.Active -> model.toIcon(showHotspotInfo, context) in fromModel()
97 private fun WifiNetworkModel.Active.toIcon( in toIcon() method
103 this.hotspotDeviceType == WifiNetworkModel.HotspotDeviceType.NONE in toIcon()
109 WifiNetworkModel.HotspotDeviceType.TABLET -> in toIcon()
[all …]
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/pipeline/wifi/shared/model/
DWifiNetworkModelTest.kt24 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel.Active.Companion.… in <lambda>()
25 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel.Companion.MIN_VAL… in <lambda>()
34 WifiNetworkModel.Active(NETWORK_ID, level = level) in <lambda>()
41 WifiNetworkModel.Active(NETWORK_ID, level = MIN_VALID_LEVEL - 1) in <lambda>()
46 WifiNetworkModel.Active(NETWORK_ID, level = MAX_VALID_LEVEL + 1) in <lambda>()
51 WifiNetworkModel.CarrierMerged(NETWORK_ID, INVALID_SUBSCRIPTION_ID, 1) in <lambda>()
57 WifiNetworkModel.Active( in <lambda>()
69 WifiNetworkModel.Active( in <lambda>()
81 WifiNetworkModel.Active( in <lambda>()
96 WifiNetworkModel.CarrierMerged( in <lambda>()
[all …]
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/pipeline/wifi/ui/viewmodel/
DWifiViewModelIconParameterizedTest.kt42 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel in <lambda>()
183 val network: WifiNetworkModel, in <lambda>()
208 WifiNetworkModel.CarrierMerged(NETWORK_ID, subscriptionId = 1, level = 1), in <lambda>()
213 network = WifiNetworkModel.Inactive, in <lambda>()
218 network = WifiNetworkModel.Active(NETWORK_ID, isValidated = false, level = 1), in <lambda>()
223 network = WifiNetworkModel.Active(NETWORK_ID, isValidated = true, level = 3), in <lambda>()
231 WifiNetworkModel.CarrierMerged(NETWORK_ID, subscriptionId = 1, level = 1), in <lambda>()
236 network = WifiNetworkModel.Inactive, in <lambda>()
241 network = WifiNetworkModel.Active(NETWORK_ID, isValidated = false, level = 2), in <lambda>()
246 network = WifiNetworkModel.Active(NETWORK_ID, isValidated = true, level = 1), in <lambda>()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/pipeline/wifi/data/repository/demo/
DDemoModeWifiDataSource.kt27 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel in <lambda>()
88 private fun String?.toHotspotDeviceType(): WifiNetworkModel.HotspotDeviceType { in <lambda>()
91 "none" -> WifiNetworkModel.HotspotDeviceType.NONE in <lambda>()
92 "unknown" -> WifiNetworkModel.HotspotDeviceType.UNKNOWN in <lambda>()
93 "phone" -> WifiNetworkModel.HotspotDeviceType.PHONE in <lambda>()
94 "tablet" -> WifiNetworkModel.HotspotDeviceType.TABLET in <lambda>()
95 "laptop" -> WifiNetworkModel.HotspotDeviceType.LAPTOP in <lambda>()
96 "watch" -> WifiNetworkModel.HotspotDeviceType.WATCH in <lambda>()
97 "auto" -> WifiNetworkModel.HotspotDeviceType.AUTO in <lambda>()
98 else -> WifiNetworkModel.HotspotDeviceType.INVALID in <lambda>()
DDemoWifiRepository.kt24 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel in <lambda>()
49 private val _wifiNetwork = MutableStateFlow<WifiNetworkModel>(WifiNetworkModel.Inactive) in <lambda>()
50 override val wifiNetwork: StateFlow<WifiNetworkModel> = _wifiNetwork in <lambda>()
52 private val _secondaryNetworks = MutableStateFlow<List<WifiNetworkModel>>(emptyList()) in <lambda>()
53 override val secondaryNetworks: StateFlow<List<WifiNetworkModel>> = _secondaryNetworks in <lambda>()
85 _wifiNetwork.value = WifiNetworkModel.Inactive in <lambda>()
102 private fun FakeWifiEventModel.Wifi.toWifiNetworkModel(): WifiNetworkModel = in <lambda>()
103 WifiNetworkModel.Active( in <lambda>()
117 private fun FakeWifiEventModel.CarrierMerged.toCarrierMergedModel(): WifiNetworkModel = in <lambda>()
118 WifiNetworkModel.CarrierMerged( in <lambda>()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/pipeline/wifi/domain/interactor/
DWifiInteractor.kt25 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel in <lambda>()
56 val wifiNetwork: Flow<WifiNetworkModel> in <lambda>()
80 is WifiNetworkModel.Unavailable -> null in info()
81 is WifiNetworkModel.Invalid -> null in info()
82 is WifiNetworkModel.Inactive -> null in info()
83 is WifiNetworkModel.CarrierMerged -> null in info()
84 is WifiNetworkModel.Active -> in info()
98 override val wifiNetwork: Flow<WifiNetworkModel> = wifiRepository.wifiNetwork
114 } else if (currentNetwork !is WifiNetworkModel.Active) { in currentNetwork()
123 currentNetwork: WifiNetworkModel.Active, in anyNonMatchingNetworkExists()
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/pipeline/wifi/data/repository/prod/
DWifiRepositoryImplTest.kt35 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
285 assertThat(latest is WifiNetworkModel.Active).isTrue() in wifiNetwork_primaryWifiNetworkAdded_flowHasNetwork()
286 val latestActive = latest as WifiNetworkModel.Active in wifiNetwork_primaryWifiNetworkAdded_flowHasNetwork()
305 assertThat(latest is WifiNetworkModel.Active).isTrue() in accessPointInfo_alwaysFalse()
306 val latestActive = latest as WifiNetworkModel.Active in accessPointInfo_alwaysFalse()
325 assertThat(latest).isEqualTo(WifiNetworkModel.Inactive) in wifiNetwork_unreachableLevel_inactiveNetwork()
341 assertThat(latest).isEqualTo(WifiNetworkModel.Inactive) in wifiNetwork_levelTooHigh_inactiveNetwork()
357 assertThat(latest).isEqualTo(WifiNetworkModel.Inactive) in wifiNetwork_levelTooLow_inactiveNetwork()
373 assertThat(latest).isInstanceOf(WifiNetworkModel.Active::class.java) in wifiNetwork_levelIsMax_activeNetworkWithMaxLevel()
374 assertThat((latest as WifiNetworkModel.Active).level).isEqualTo(WIFI_LEVEL_MAX) in wifiNetwork_levelIsMax_activeNetworkWithMaxLevel()
[all …]
/frameworks/base/packages/SystemUI/tests/utils/src/com/android/systemui/statusbar/pipeline/wifi/data/repository/
DFakeWifiRepository.kt21 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
34 private val _wifiNetwork: MutableStateFlow<WifiNetworkModel> =
35 MutableStateFlow(WifiNetworkModel.Inactive)
36 override val wifiNetwork: StateFlow<WifiNetworkModel> = _wifiNetwork
38 override val secondaryNetworks = MutableStateFlow<List<WifiNetworkModel>>(emptyList())
54 fun setWifiNetwork(wifiNetworkModel: WifiNetworkModel) { in setWifiNetwork()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/pipeline/wifi/data/repository/prod/
DWifiRepositoryImpl.kt47 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel in <lambda>()
48 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel.Inactive.toHotspo… in <lambda>()
153 newPrimaryNetwork: WifiNetworkModel = current.primaryNetwork, in <lambda>()
154 newSecondaryNetworks: List<WifiNetworkModel> = in <lambda>()
198 override val wifiNetwork: StateFlow<WifiNetworkModel> = in <lambda>()
209 override val secondaryNetworks: StateFlow<List<WifiNetworkModel>> = in <lambda>()
240 private fun WifiEntry.toPrimaryWifiNetworkModel(): WifiNetworkModel { in <lambda>()
249 private fun WifiEntry.toWifiNetworkModel(): WifiNetworkModel { in <lambda>()
257 private fun MergedCarrierEntry.convertCarrierMergedToModel(): WifiNetworkModel { in <lambda>()
259 WifiNetworkModel.Invalid(CARRIER_MERGED_INVALID_SUB_ID_REASON) in <lambda>()
[all …]
DDisabledWifiRepository.kt22 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
41 override val wifiNetwork: StateFlow<WifiNetworkModel> = MutableStateFlow(NETWORK).asStateFlow()
43 override val secondaryNetworks: StateFlow<List<WifiNetworkModel>> =
44 MutableStateFlow(emptyList<WifiNetworkModel>()).asStateFlow()
53 private val NETWORK = WifiNetworkModel.Unavailable
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/pipeline/wifi/shared/model/
DWifiNetworkModel.kt29 sealed class WifiNetworkModel : Diffable<WifiNetworkModel> { class
39 object Unavailable : WifiNetworkModel() {
41 override fun logDiffs(prevVal: WifiNetworkModel, row: TableRowLogger) { in toString()
68 ) : WifiNetworkModel() {
70 override fun logDiffs(prevVal: WifiNetworkModel, row: TableRowLogger) { in toString()
97 object Inactive : WifiNetworkModel() {
100 override fun logDiffs(prevVal: WifiNetworkModel, row: TableRowLogger) { in toString()
154 ) : WifiNetworkModel() {
164 override fun logDiffs(prevVal: WifiNetworkModel, row: TableRowLogger) { in logDiffs()
222 val hotspotDeviceType: HotspotDeviceType = WifiNetworkModel.HotspotDeviceType.NONE,
[all …]
/frameworks/base/packages/SystemUI/multivalentTests/src/com/android/systemui/statusbar/pipeline/wifi/domain/interactor/
DWifiInteractorImplTest.kt28 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
67 wifiRepository.setWifiNetwork(WifiNetworkModel.Unavailable) in ssid_unavailableNetwork_outputsNull()
81 wifiRepository.setWifiNetwork(WifiNetworkModel.Inactive) in ssid_inactiveNetwork_outputsNull()
96 WifiNetworkModel.CarrierMerged(networkId = 1, subscriptionId = 2, level = 1) in ssid_carrierMergedNetwork_outputsNull()
112 WifiNetworkModel.Active( in ssid_isPasspointAccessPoint_outputsPasspointName()
133 WifiNetworkModel.Active( in ssid_isOnlineSignUpForPasspoint_outputsPasspointName()
154 WifiNetworkModel.Active( in ssid_unknownSsid_outputsNull()
174 WifiNetworkModel.Active( in ssid_validSsid_outputsSsid()
236 WifiNetworkModel.Active( in wifiNetwork_matchesRepoWifiNetwork()
245 var latest: WifiNetworkModel? = null in wifiNetwork_matchesRepoWifiNetwork()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/pipeline/wifi/data/repository/
DWifiRepository.kt20 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
33 val wifiNetwork: StateFlow<WifiNetworkModel>
42 val secondaryNetworks: StateFlow<List<WifiNetworkModel>>
59 return currentNetwork is WifiNetworkModel.Active && currentNetwork.hasValidSsid() in isWifiConnectedWithValidSsid()
DWifiRepositorySwitcher.kt28 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel in <lambda>()
113 override val wifiNetwork: StateFlow<WifiNetworkModel> = in <lambda>()
118 override val secondaryNetworks: StateFlow<List<WifiNetworkModel>> = in <lambda>()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/pipeline/wifi/data/repository/demo/model/
DFakeWifiEventModel.kt20 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
33 val hotspotDeviceType: WifiNetworkModel.HotspotDeviceType =
34 WifiNetworkModel.HotspotDeviceType.NONE,
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/pipeline/mobile/data/repository/prod/
DCarrierMergedConnectionRepositoryTest.kt30 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
88 wifiRepository.setWifiNetwork(WifiNetworkModel.Inactive) in inactiveWifi_isDefault()
107 wifiRepository.setWifiNetwork(WifiNetworkModel.Active(networkId = NET_ID, level = 1)) in activeWifi_isDefault()
126 WifiNetworkModel.CarrierMerged( in carrierMergedWifi_isValidAndFieldsComeFromWifiNetwork()
147 WifiNetworkModel.CarrierMerged( in activity_comesFromWifiActivity()
185 WifiNetworkModel.CarrierMerged( in carrierMergedWifi_wrongSubId_isDefault()
207 WifiNetworkModel.CarrierMerged( in carrierMergedButNotEnabled_isDefault()
228 WifiNetworkModel.CarrierMerged( in carrierMergedButWifiNotDefault_isDefault()
248 WifiNetworkModel.CarrierMerged( in numberOfLevels_comesFromCarrierMerged()
312 WifiNetworkModel.CarrierMerged( in networkName_updatesOnNetworkUpdate()
DFullMobileConnectionRepositoryTest.kt43 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
514 WifiNetworkModel.CarrierMerged( in connectionInfo_logging_carrierMerged_getsUpdates()
526 WifiNetworkModel.CarrierMerged( in connectionInfo_logging_carrierMerged_getsUpdates()
567 WifiNetworkModel.CarrierMerged( in connectionInfo_logging_updatesWhenCarrierMergedUpdates()
580 WifiNetworkModel.CarrierMerged( in connectionInfo_logging_updatesWhenCarrierMergedUpdates()
634 WifiNetworkModel.CarrierMerged( in connectionInfo_logging_doesNotLogUpdatesForNotActiveRepo()
643 WifiNetworkModel.CarrierMerged( in connectionInfo_logging_doesNotLogUpdatesForNotActiveRepo()
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/pipeline/shared/ui/viewmodel/
DInternetTileViewModelTest.kt47 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
151 WifiNetworkModel.Active( in wifiDefaultAndActive()
181 WifiNetworkModel.Active( in wifiDefaultAndActive_hotspotNone()
185 hotspotDeviceType = WifiNetworkModel.HotspotDeviceType.NONE, in wifiDefaultAndActive_hotspotNone()
203 setWifiNetworkWithHotspot(WifiNetworkModel.HotspotDeviceType.TABLET) in wifiDefaultAndActive_hotspotTablet()
216 setWifiNetworkWithHotspot(WifiNetworkModel.HotspotDeviceType.LAPTOP) in wifiDefaultAndActive_hotspotLaptop()
229 setWifiNetworkWithHotspot(WifiNetworkModel.HotspotDeviceType.WATCH) in wifiDefaultAndActive_hotspotWatch()
242 setWifiNetworkWithHotspot(WifiNetworkModel.HotspotDeviceType.AUTO) in wifiDefaultAndActive_hotspotAuto()
255 setWifiNetworkWithHotspot(WifiNetworkModel.HotspotDeviceType.PHONE) in wifiDefaultAndActive_hotspotPhone()
268 setWifiNetworkWithHotspot(WifiNetworkModel.HotspotDeviceType.UNKNOWN) in wifiDefaultAndActive_hotspotUnknown()
[all …]
/frameworks/base/packages/SystemUI/multivalentTests/src/com/android/systemui/qs/tiles/impl/internet/domain/interactor/
DInternetTileDataInteractorTest.kt54 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel in <lambda>()
187 WifiNetworkModel.Active( in <lambda>()
223 WifiNetworkModel.Active( in <lambda>()
227 hotspotDeviceType = WifiNetworkModel.HotspotDeviceType.NONE, in <lambda>()
251 setWifiNetworkWithHotspot(WifiNetworkModel.HotspotDeviceType.TABLET) in <lambda>()
273 setWifiNetworkWithHotspot(WifiNetworkModel.HotspotDeviceType.LAPTOP) in <lambda>()
295 setWifiNetworkWithHotspot(WifiNetworkModel.HotspotDeviceType.WATCH) in <lambda>()
317 setWifiNetworkWithHotspot(WifiNetworkModel.HotspotDeviceType.AUTO) in <lambda>()
338 setWifiNetworkWithHotspot(WifiNetworkModel.HotspotDeviceType.PHONE) in <lambda>()
360 setWifiNetworkWithHotspot(WifiNetworkModel.HotspotDeviceType.UNKNOWN) in <lambda>()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/pipeline/mobile/data/repository/prod/
DCarrierMergedConnectionRepository.kt33 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel in <lambda>()
78 private val network: Flow<WifiNetworkModel.CarrierMerged?> = in <lambda>()
87 network !is WifiNetworkModel.CarrierMerged -> null in <lambda>()
120 if (it is WifiNetworkModel.CarrierMerged) { in <lambda>()
/frameworks/base/packages/SystemUI/multivalentTests/src/com/android/systemui/statusbar/pipeline/wifi/data/repository/prod/
DDisabledWifiRepositoryTest.kt23 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
53 assertThat(underTest.wifiNetwork.value).isEqualTo(WifiNetworkModel.Unavailable) in network_alwaysUnavailable()
/frameworks/base/packages/SystemUI/multivalentTests/src/com/android/systemui/statusbar/pipeline/wifi/ui/viewmodel/
DWifiViewModelTest.kt44 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
117 WifiNetworkModel.Active(NETWORK_ID, isValidated = true, level = 1) in wifiIcon_allLocationViewModelsReceiveSameData()
132 WifiNetworkModel.Active( in wifiIcon_validHotspot_hotspotIconNotShown()
136 hotspotDeviceType = WifiNetworkModel.HotspotDeviceType.LAPTOP, in wifiIcon_validHotspot_hotspotIconNotShown()
196 WifiNetworkModel.Active(NETWORK_ID, ssid = null, level = 1) in activity_nullSsid_outputsFalse_staticFlagOff()
221 WifiNetworkModel.Active(NETWORK_ID, ssid = null, level = 1) in activity_nullSsid_outputsFalse_staticFlagOn()
473 WifiNetworkModel.Active(NETWORK_ID, ssid = "AB", level = 1)
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/pipeline/satellite/domain/interactor/
DDeviceBasedSatelliteInteractor.kt29 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel in <lambda>()
82 wifiInteractor.wifiNetwork.map { it is WifiNetworkModel.Active } in <lambda>()
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/pipeline/satellite/ui/viewmodel/
DDeviceBasedSatelliteViewModelTest.kt34 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel
286 wifiRepository.setWifiNetwork(WifiNetworkModel.Active(networkId = 0, level = 1)) in icon_wifiIsActive()
292 wifiRepository.setWifiNetwork(WifiNetworkModel.Invalid("test")) in icon_wifiIsActive()
509 wifiRepository.setWifiNetwork(WifiNetworkModel.Active(networkId = 0, level = 1)) in carrierText_wifiIsActive()
515 wifiRepository.setWifiNetwork(WifiNetworkModel.Invalid("test")) in carrierText_wifiIsActive()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/pipeline/wifi/ui/viewmodel/
DWifiViewModel.kt32 import com.android.systemui.statusbar.pipeline.wifi.shared.model.WifiNetworkModel in <lambda>()
76 if (!isEnabled || isForceHidden || wifiNetwork is WifiNetworkModel.CarrierMerged) { in <lambda>()

12