@tokamakdev/plugin-location 0.1.0-beta.107 → 0.1.0-beta.114

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,997 @@
1
+ // Generated by `tok bindings` from the Android 35 SDK: android.location, android.content.Context, android.os.CancellationSignal, android.os.SystemClock, java.util.concurrent.Executor, java.util.function.Consumer. Do not edit.
2
+ @file:Suppress("DEPRECATION", "OVERRIDE_DEPRECATION", "UNCHECKED_CAST")
3
+ @file:SuppressLint("MissingPermission")
4
+
5
+ package com.tokamak.bindings.location
6
+
7
+ import android.annotation.SuppressLint
8
+ import android.os.Build
9
+ import com.tokamak.runtime.TokamakBinding
10
+ import com.tokamak.runtime.TokamakHost
11
+ import com.tokamak.runtime.TokamakPlugin
12
+ import com.tokamak.runtime.TokamakPluginBytesReply
13
+ import com.tokamak.runtime.TokamakPluginError
14
+
15
+ class Bindings(private val host: TokamakHost) : TokamakPlugin {
16
+ override val id = "location/android"
17
+
18
+ override fun callBytes(method: String, payload: ByteArray, reply: TokamakPluginBytesReply): (() -> Unit)? {
19
+ val b = TokamakBinding(payload, host.resources, reply)
20
+ return when (method.substringBefore('#')) {
21
+ "Location" -> callLocation(method, b)
22
+ "Address" -> callAddress(method, b)
23
+ "Criteria" -> callCriteria(method, b)
24
+ "Geocoder" -> callGeocoder(method, b)
25
+ "Geocoder.GeocodeListener" -> callGeocoder_GeocodeListener(method, b)
26
+ "GnssAntennaInfo" -> callGnssAntennaInfo(method, b)
27
+ "GnssAntennaInfo.Builder" -> callGnssAntennaInfo_Builder(method, b)
28
+ "GnssAntennaInfo.Listener" -> callGnssAntennaInfo_Listener(method, b)
29
+ "GnssAntennaInfo.PhaseCenterOffset" -> callGnssAntennaInfo_PhaseCenterOffset(method, b)
30
+ "GnssAntennaInfo.SphericalCorrections" -> callGnssAntennaInfo_SphericalCorrections(method, b)
31
+ "GnssAutomaticGainControl" -> callGnssAutomaticGainControl(method, b)
32
+ "GnssAutomaticGainControl.Builder" -> callGnssAutomaticGainControl_Builder(method, b)
33
+ "GnssCapabilities" -> callGnssCapabilities(method, b)
34
+ "GnssCapabilities.Builder" -> callGnssCapabilities_Builder(method, b)
35
+ "GnssClock" -> callGnssClock(method, b)
36
+ "GnssMeasurement" -> callGnssMeasurement(method, b)
37
+ "GnssMeasurementRequest" -> callGnssMeasurementRequest(method, b)
38
+ "GnssMeasurementRequest.Builder" -> callGnssMeasurementRequest_Builder(method, b)
39
+ "GnssMeasurementsEvent" -> callGnssMeasurementsEvent(method, b)
40
+ "GnssMeasurementsEvent.Builder" -> callGnssMeasurementsEvent_Builder(method, b)
41
+ "GnssMeasurementsEvent.Callback" -> callGnssMeasurementsEvent_Callback(method, b)
42
+ "GnssNavigationMessage" -> callGnssNavigationMessage(method, b)
43
+ "GnssNavigationMessage.Callback" -> callGnssNavigationMessage_Callback(method, b)
44
+ "GnssSignalType" -> callGnssSignalType(method, b)
45
+ "GnssStatus" -> callGnssStatus(method, b)
46
+ "GnssStatus.Builder" -> callGnssStatus_Builder(method, b)
47
+ "GnssStatus.Callback" -> callGnssStatus_Callback(method, b)
48
+ "GpsSatellite" -> callGpsSatellite(method, b)
49
+ "GpsStatus" -> callGpsStatus(method, b)
50
+ "GpsStatus.Listener" -> callGpsStatus_Listener(method, b)
51
+ "GpsStatus.NmeaListener" -> callGpsStatus_NmeaListener(method, b)
52
+ "LocationListener" -> callLocationListener(method, b)
53
+ "LocationManager" -> callLocationManager(method, b)
54
+ "LocationProvider" -> callLocationProvider(method, b)
55
+ "LocationRequest" -> callLocationRequest(method, b)
56
+ "LocationRequest.Builder" -> callLocationRequest_Builder(method, b)
57
+ "OnNmeaMessageListener" -> callOnNmeaMessageListener(method, b)
58
+ "SettingInjectorService" -> callSettingInjectorService(method, b)
59
+ "Context" -> callContext(method, b)
60
+ "Context.BindServiceFlags" -> callContext_BindServiceFlags(method, b)
61
+ "CancellationSignal" -> callCancellationSignal(method, b)
62
+ "CancellationSignal.OnCancelListener" -> callCancellationSignal_OnCancelListener(method, b)
63
+ "SystemClock" -> callSystemClock(method, b)
64
+ "Consumer" -> callConsumer(method, b)
65
+ else -> b.unsupported(method)
66
+ }
67
+ }
68
+
69
+ override fun subscribeBytes(method: String, payload: ByteArray, reply: TokamakPluginBytesReply): () -> Unit {
70
+ val b = TokamakBinding(payload, host.resources, reply)
71
+ return when (method) {
72
+ "Geocoder.GeocodeListener" -> {
73
+ if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable
74
+ b.implement { Geocoder_GeocodeListenerImplementation(it) }
75
+ }
76
+ "GnssAntennaInfo.Listener" -> {
77
+ if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable
78
+ b.implement { GnssAntennaInfo_ListenerImplementation(it) }
79
+ }
80
+ "GnssMeasurementsEvent.Callback" -> {
81
+ if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable
82
+ b.implement { GnssMeasurementsEvent_CallbackImplementation(it) }
83
+ }
84
+ "GnssNavigationMessage.Callback" -> {
85
+ if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable
86
+ b.implement { GnssNavigationMessage_CallbackImplementation(it) }
87
+ }
88
+ "GnssStatus.Callback" -> {
89
+ if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable
90
+ b.implement { GnssStatus_CallbackImplementation(it) }
91
+ }
92
+ "GpsStatus.Listener" -> {
93
+ if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable
94
+ b.implement { GpsStatus_ListenerImplementation(it) }
95
+ }
96
+ "GpsStatus.NmeaListener" -> {
97
+ if (Build.VERSION.SDK_INT < 5) throw TokamakBinding.unavailable
98
+ b.implement { GpsStatus_NmeaListenerImplementation(it) }
99
+ }
100
+ "LocationListener" -> {
101
+ b.implement { LocationListenerImplementation(it) }
102
+ }
103
+ "OnNmeaMessageListener" -> {
104
+ if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable
105
+ b.implement { OnNmeaMessageListenerImplementation(it) }
106
+ }
107
+ "CancellationSignal.OnCancelListener" -> {
108
+ if (Build.VERSION.SDK_INT < 16) throw TokamakBinding.unavailable
109
+ b.implement { CancellationSignal_OnCancelListenerImplementation(it) }
110
+ }
111
+ "Consumer" -> {
112
+ if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable
113
+ b.implement { ConsumerImplementation(it) }
114
+ }
115
+ else -> throw TokamakPluginError.notSupported("$method is not supported")
116
+ }
117
+ }
118
+
119
+ private fun callLocation(method: String, b: TokamakBinding): (() -> Unit)? =
120
+ when (method) {
121
+ "Location#<init>(Ljava/lang/String;)V" -> b.run { b.encode(android.location.Location(b.optional(b[0]) { x1 -> b.string(x1) })) }
122
+ "Location#<init>(Landroid/location/Location;)V" -> b.run { b.encode(android.location.Location(b.obj(b[0], android.location.Location::class.java))) }
123
+ "Location#set(Landroid/location/Location;)V" -> b.run { b.target(android.location.Location::class.java).set(b.obj(b[0], android.location.Location::class.java)); null }
124
+ "Location#reset()V" -> b.run { b.target(android.location.Location::class.java).reset(); null }
125
+ "Location#distanceTo(Landroid/location/Location;)F" -> b.run { b.encode(b.target(android.location.Location::class.java).distanceTo(b.obj(b[0], android.location.Location::class.java))) }
126
+ "Location#bearingTo(Landroid/location/Location;)F" -> b.run { b.encode(b.target(android.location.Location::class.java).bearingTo(b.obj(b[0], android.location.Location::class.java))) }
127
+ "Location#getProvider()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Location::class.java).getProvider()) }
128
+ "Location#setProvider(Ljava/lang/String;)V" -> b.run { b.target(android.location.Location::class.java).setProvider(b.optional(b[0]) { x1 -> b.string(x1) }); null }
129
+ "Location#getTime()J" -> b.run { b.encode(b.target(android.location.Location::class.java).getTime()) }
130
+ "Location#setTime(J)V" -> b.run { b.target(android.location.Location::class.java).setTime(b.long(b[0])); null }
131
+ "Location#getLatitude()D" -> b.run { b.encode(b.target(android.location.Location::class.java).getLatitude()) }
132
+ "Location#setLatitude(D)V" -> b.run { b.target(android.location.Location::class.java).setLatitude(b.double(b[0])); null }
133
+ "Location#getLongitude()D" -> b.run { b.encode(b.target(android.location.Location::class.java).getLongitude()) }
134
+ "Location#setLongitude(D)V" -> b.run { b.target(android.location.Location::class.java).setLongitude(b.double(b[0])); null }
135
+ "Location#getAccuracy()F" -> b.run { b.encode(b.target(android.location.Location::class.java).getAccuracy()) }
136
+ "Location#setAccuracy(F)V" -> b.run { b.target(android.location.Location::class.java).setAccuracy(b.float(b[0])); null }
137
+ "Location#hasAccuracy()Z" -> b.run { b.encode(b.target(android.location.Location::class.java).hasAccuracy()) }
138
+ "Location#removeAccuracy()V" -> b.run { b.target(android.location.Location::class.java).removeAccuracy(); null }
139
+ "Location#getAltitude()D" -> b.run { b.encode(b.target(android.location.Location::class.java).getAltitude()) }
140
+ "Location#setAltitude(D)V" -> b.run { b.target(android.location.Location::class.java).setAltitude(b.double(b[0])); null }
141
+ "Location#hasAltitude()Z" -> b.run { b.encode(b.target(android.location.Location::class.java).hasAltitude()) }
142
+ "Location#removeAltitude()V" -> b.run { b.target(android.location.Location::class.java).removeAltitude(); null }
143
+ "Location#getSpeed()F" -> b.run { b.encode(b.target(android.location.Location::class.java).getSpeed()) }
144
+ "Location#setSpeed(F)V" -> b.run { b.target(android.location.Location::class.java).setSpeed(b.float(b[0])); null }
145
+ "Location#hasSpeed()Z" -> b.run { b.encode(b.target(android.location.Location::class.java).hasSpeed()) }
146
+ "Location#removeSpeed()V" -> b.run { b.target(android.location.Location::class.java).removeSpeed(); null }
147
+ "Location#getBearing()F" -> b.run { b.encode(b.target(android.location.Location::class.java).getBearing()) }
148
+ "Location#setBearing(F)V" -> b.run { b.target(android.location.Location::class.java).setBearing(b.float(b[0])); null }
149
+ "Location#hasBearing()Z" -> b.run { b.encode(b.target(android.location.Location::class.java).hasBearing()) }
150
+ "Location#removeBearing()V" -> b.run { b.target(android.location.Location::class.java).removeBearing(); null }
151
+ "Location#equals(Ljava/lang/Object;)Z" -> b.run { b.encode(b.target(android.location.Location::class.java).equals(b.optional(b[0]) { x1 -> b.any(x1) })) }
152
+ "Location#hashCode()I" -> b.run { b.encode(b.target(android.location.Location::class.java).hashCode()) }
153
+ "Location#toString()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Location::class.java).toString()) }
154
+ "Location#describeContents()I" -> b.run { b.encode(b.target(android.location.Location::class.java).describeContents()) }
155
+ "Location#convert(DI)Ljava/lang/String;" -> b.run { b.encode(android.location.Location.convert(b.double(b[0]), b.int(b[1]))) }
156
+ "Location#convert(Ljava/lang/String;)D" -> b.run { b.encode(android.location.Location.convert(b.string(b[0]))) }
157
+ "Location#distanceBetween(DDDD[F)V" -> b.run { android.location.Location.distanceBetween(b.double(b[0]), b.double(b[1]), b.double(b[2]), b.double(b[3]), b.optional(b[4]) { x1 -> b.list(x1) { x2 -> b.float(x2) }.toFloatArray() }); null }
158
+ "Location#getElapsedRealtimeNanos()J" -> b.run { if (Build.VERSION.SDK_INT < 17) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).getElapsedRealtimeNanos()) }
159
+ "Location#setElapsedRealtimeNanos(J)V" -> b.run { if (Build.VERSION.SDK_INT < 17) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).setElapsedRealtimeNanos(b.long(b[0])); null }
160
+ "Location#isFromMockProvider()Z" -> b.run { if (Build.VERSION.SDK_INT < 18) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).isFromMockProvider()) }
161
+ "Location#getVerticalAccuracyMeters()F" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).getVerticalAccuracyMeters()) }
162
+ "Location#setVerticalAccuracyMeters(F)V" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).setVerticalAccuracyMeters(b.float(b[0])); null }
163
+ "Location#hasVerticalAccuracy()Z" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).hasVerticalAccuracy()) }
164
+ "Location#getSpeedAccuracyMetersPerSecond()F" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).getSpeedAccuracyMetersPerSecond()) }
165
+ "Location#setSpeedAccuracyMetersPerSecond(F)V" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).setSpeedAccuracyMetersPerSecond(b.float(b[0])); null }
166
+ "Location#hasSpeedAccuracy()Z" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).hasSpeedAccuracy()) }
167
+ "Location#getBearingAccuracyDegrees()F" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).getBearingAccuracyDegrees()) }
168
+ "Location#setBearingAccuracyDegrees(F)V" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).setBearingAccuracyDegrees(b.float(b[0])); null }
169
+ "Location#hasBearingAccuracy()Z" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).hasBearingAccuracy()) }
170
+ "Location#getElapsedRealtimeUncertaintyNanos()D" -> b.run { if (Build.VERSION.SDK_INT < 29) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).getElapsedRealtimeUncertaintyNanos()) }
171
+ "Location#setElapsedRealtimeUncertaintyNanos(D)V" -> b.run { if (Build.VERSION.SDK_INT < 29) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).setElapsedRealtimeUncertaintyNanos(b.double(b[0])); null }
172
+ "Location#hasElapsedRealtimeUncertaintyNanos()Z" -> b.run { if (Build.VERSION.SDK_INT < 29) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).hasElapsedRealtimeUncertaintyNanos()) }
173
+ "Location#isMock()Z" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).isMock()) }
174
+ "Location#setMock(Z)V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).setMock(b.boolean(b[0])); null }
175
+ "Location#getElapsedRealtimeMillis()J" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).getElapsedRealtimeMillis()) }
176
+ "Location#getElapsedRealtimeAgeMillis()J" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).getElapsedRealtimeAgeMillis()) }
177
+ "Location#getElapsedRealtimeAgeMillis(J)J" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).getElapsedRealtimeAgeMillis(b.long(b[0]))) }
178
+ "Location#removeElapsedRealtimeUncertaintyNanos()V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).removeElapsedRealtimeUncertaintyNanos(); null }
179
+ "Location#removeVerticalAccuracy()V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).removeVerticalAccuracy(); null }
180
+ "Location#removeSpeedAccuracy()V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).removeSpeedAccuracy(); null }
181
+ "Location#removeBearingAccuracy()V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).removeBearingAccuracy(); null }
182
+ "Location#isComplete()Z" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).isComplete()) }
183
+ "Location#getMslAltitudeMeters()D" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).getMslAltitudeMeters()) }
184
+ "Location#setMslAltitudeMeters(D)V" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).setMslAltitudeMeters(b.double(b[0])); null }
185
+ "Location#hasMslAltitude()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).hasMslAltitude()) }
186
+ "Location#removeMslAltitude()V" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).removeMslAltitude(); null }
187
+ "Location#getMslAltitudeAccuracyMeters()F" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).getMslAltitudeAccuracyMeters()) }
188
+ "Location#setMslAltitudeAccuracyMeters(F)V" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).setMslAltitudeAccuracyMeters(b.float(b[0])); null }
189
+ "Location#hasMslAltitudeAccuracy()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Location::class.java).hasMslAltitudeAccuracy()) }
190
+ "Location#removeMslAltitudeAccuracy()V" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.target(android.location.Location::class.java).removeMslAltitudeAccuracy(); null }
191
+ else -> b.unsupported(method)
192
+ }
193
+
194
+ private fun callAddress(method: String, b: TokamakBinding): (() -> Unit)? =
195
+ when (method) {
196
+ "Address#getMaxAddressLineIndex()I" -> b.run { b.encode(b.target(android.location.Address::class.java).getMaxAddressLineIndex()) }
197
+ "Address#getAddressLine(I)Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Address::class.java).getAddressLine(b.int(b[0]))) }
198
+ "Address#setAddressLine(ILjava/lang/String;)V" -> b.run { b.target(android.location.Address::class.java).setAddressLine(b.int(b[0]), b.optional(b[1]) { x1 -> b.string(x1) }); null }
199
+ "Address#getFeatureName()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Address::class.java).getFeatureName()) }
200
+ "Address#setFeatureName(Ljava/lang/String;)V" -> b.run { b.target(android.location.Address::class.java).setFeatureName(b.optional(b[0]) { x1 -> b.string(x1) }); null }
201
+ "Address#getAdminArea()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Address::class.java).getAdminArea()) }
202
+ "Address#setAdminArea(Ljava/lang/String;)V" -> b.run { b.target(android.location.Address::class.java).setAdminArea(b.optional(b[0]) { x1 -> b.string(x1) }); null }
203
+ "Address#getSubAdminArea()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Address::class.java).getSubAdminArea()) }
204
+ "Address#setSubAdminArea(Ljava/lang/String;)V" -> b.run { b.target(android.location.Address::class.java).setSubAdminArea(b.optional(b[0]) { x1 -> b.string(x1) }); null }
205
+ "Address#getLocality()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Address::class.java).getLocality()) }
206
+ "Address#setLocality(Ljava/lang/String;)V" -> b.run { b.target(android.location.Address::class.java).setLocality(b.optional(b[0]) { x1 -> b.string(x1) }); null }
207
+ "Address#getThoroughfare()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Address::class.java).getThoroughfare()) }
208
+ "Address#setThoroughfare(Ljava/lang/String;)V" -> b.run { b.target(android.location.Address::class.java).setThoroughfare(b.optional(b[0]) { x1 -> b.string(x1) }); null }
209
+ "Address#getPostalCode()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Address::class.java).getPostalCode()) }
210
+ "Address#setPostalCode(Ljava/lang/String;)V" -> b.run { b.target(android.location.Address::class.java).setPostalCode(b.optional(b[0]) { x1 -> b.string(x1) }); null }
211
+ "Address#getCountryCode()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Address::class.java).getCountryCode()) }
212
+ "Address#setCountryCode(Ljava/lang/String;)V" -> b.run { b.target(android.location.Address::class.java).setCountryCode(b.optional(b[0]) { x1 -> b.string(x1) }); null }
213
+ "Address#getCountryName()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Address::class.java).getCountryName()) }
214
+ "Address#setCountryName(Ljava/lang/String;)V" -> b.run { b.target(android.location.Address::class.java).setCountryName(b.optional(b[0]) { x1 -> b.string(x1) }); null }
215
+ "Address#hasLatitude()Z" -> b.run { b.encode(b.target(android.location.Address::class.java).hasLatitude()) }
216
+ "Address#getLatitude()D" -> b.run { b.encode(b.target(android.location.Address::class.java).getLatitude()) }
217
+ "Address#setLatitude(D)V" -> b.run { b.target(android.location.Address::class.java).setLatitude(b.double(b[0])); null }
218
+ "Address#clearLatitude()V" -> b.run { b.target(android.location.Address::class.java).clearLatitude(); null }
219
+ "Address#hasLongitude()Z" -> b.run { b.encode(b.target(android.location.Address::class.java).hasLongitude()) }
220
+ "Address#getLongitude()D" -> b.run { b.encode(b.target(android.location.Address::class.java).getLongitude()) }
221
+ "Address#setLongitude(D)V" -> b.run { b.target(android.location.Address::class.java).setLongitude(b.double(b[0])); null }
222
+ "Address#clearLongitude()V" -> b.run { b.target(android.location.Address::class.java).clearLongitude(); null }
223
+ "Address#getPhone()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Address::class.java).getPhone()) }
224
+ "Address#setPhone(Ljava/lang/String;)V" -> b.run { b.target(android.location.Address::class.java).setPhone(b.optional(b[0]) { x1 -> b.string(x1) }); null }
225
+ "Address#getUrl()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Address::class.java).getUrl()) }
226
+ "Address#setUrl(Ljava/lang/String;)V" -> b.run { b.target(android.location.Address::class.java).setUrl(b.optional(b[0]) { x1 -> b.string(x1) }); null }
227
+ "Address#toString()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Address::class.java).toString()) }
228
+ "Address#describeContents()I" -> b.run { b.encode(b.target(android.location.Address::class.java).describeContents()) }
229
+ "Address#getSubLocality()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 4) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Address::class.java).getSubLocality()) }
230
+ "Address#setSubLocality(Ljava/lang/String;)V" -> b.run { if (Build.VERSION.SDK_INT < 4) throw TokamakBinding.unavailable; b.target(android.location.Address::class.java).setSubLocality(b.optional(b[0]) { x1 -> b.string(x1) }); null }
231
+ "Address#getSubThoroughfare()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 4) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Address::class.java).getSubThoroughfare()) }
232
+ "Address#setSubThoroughfare(Ljava/lang/String;)V" -> b.run { if (Build.VERSION.SDK_INT < 4) throw TokamakBinding.unavailable; b.target(android.location.Address::class.java).setSubThoroughfare(b.optional(b[0]) { x1 -> b.string(x1) }); null }
233
+ "Address#getPremises()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 4) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Address::class.java).getPremises()) }
234
+ "Address#setPremises(Ljava/lang/String;)V" -> b.run { if (Build.VERSION.SDK_INT < 4) throw TokamakBinding.unavailable; b.target(android.location.Address::class.java).setPremises(b.optional(b[0]) { x1 -> b.string(x1) }); null }
235
+ else -> b.unsupported(method)
236
+ }
237
+
238
+ private fun callCriteria(method: String, b: TokamakBinding): (() -> Unit)? =
239
+ when (method) {
240
+ "Criteria#<init>()V" -> b.run { b.encode(android.location.Criteria()) }
241
+ "Criteria#<init>(Landroid/location/Criteria;)V" -> b.run { b.encode(android.location.Criteria(b.optional(b[0]) { x1 -> b.obj(x1, android.location.Criteria::class.java) })) }
242
+ "Criteria#setAccuracy(I)V" -> b.run { b.target(android.location.Criteria::class.java).setAccuracy(b.int(b[0])); null }
243
+ "Criteria#getAccuracy()I" -> b.run { b.encode(b.target(android.location.Criteria::class.java).getAccuracy()) }
244
+ "Criteria#setPowerRequirement(I)V" -> b.run { b.target(android.location.Criteria::class.java).setPowerRequirement(b.int(b[0])); null }
245
+ "Criteria#getPowerRequirement()I" -> b.run { b.encode(b.target(android.location.Criteria::class.java).getPowerRequirement()) }
246
+ "Criteria#setCostAllowed(Z)V" -> b.run { b.target(android.location.Criteria::class.java).setCostAllowed(b.boolean(b[0])); null }
247
+ "Criteria#isCostAllowed()Z" -> b.run { b.encode(b.target(android.location.Criteria::class.java).isCostAllowed()) }
248
+ "Criteria#setAltitudeRequired(Z)V" -> b.run { b.target(android.location.Criteria::class.java).setAltitudeRequired(b.boolean(b[0])); null }
249
+ "Criteria#isAltitudeRequired()Z" -> b.run { b.encode(b.target(android.location.Criteria::class.java).isAltitudeRequired()) }
250
+ "Criteria#setSpeedRequired(Z)V" -> b.run { b.target(android.location.Criteria::class.java).setSpeedRequired(b.boolean(b[0])); null }
251
+ "Criteria#isSpeedRequired()Z" -> b.run { b.encode(b.target(android.location.Criteria::class.java).isSpeedRequired()) }
252
+ "Criteria#setBearingRequired(Z)V" -> b.run { b.target(android.location.Criteria::class.java).setBearingRequired(b.boolean(b[0])); null }
253
+ "Criteria#isBearingRequired()Z" -> b.run { b.encode(b.target(android.location.Criteria::class.java).isBearingRequired()) }
254
+ "Criteria#describeContents()I" -> b.run { b.encode(b.target(android.location.Criteria::class.java).describeContents()) }
255
+ "Criteria#toString()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.Criteria::class.java).toString()) }
256
+ "Criteria#setHorizontalAccuracy(I)V" -> b.run { if (Build.VERSION.SDK_INT < 9) throw TokamakBinding.unavailable; b.target(android.location.Criteria::class.java).setHorizontalAccuracy(b.int(b[0])); null }
257
+ "Criteria#getHorizontalAccuracy()I" -> b.run { if (Build.VERSION.SDK_INT < 9) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Criteria::class.java).getHorizontalAccuracy()) }
258
+ "Criteria#setVerticalAccuracy(I)V" -> b.run { if (Build.VERSION.SDK_INT < 9) throw TokamakBinding.unavailable; b.target(android.location.Criteria::class.java).setVerticalAccuracy(b.int(b[0])); null }
259
+ "Criteria#getVerticalAccuracy()I" -> b.run { if (Build.VERSION.SDK_INT < 9) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Criteria::class.java).getVerticalAccuracy()) }
260
+ "Criteria#setSpeedAccuracy(I)V" -> b.run { if (Build.VERSION.SDK_INT < 9) throw TokamakBinding.unavailable; b.target(android.location.Criteria::class.java).setSpeedAccuracy(b.int(b[0])); null }
261
+ "Criteria#getSpeedAccuracy()I" -> b.run { if (Build.VERSION.SDK_INT < 9) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Criteria::class.java).getSpeedAccuracy()) }
262
+ "Criteria#setBearingAccuracy(I)V" -> b.run { if (Build.VERSION.SDK_INT < 9) throw TokamakBinding.unavailable; b.target(android.location.Criteria::class.java).setBearingAccuracy(b.int(b[0])); null }
263
+ "Criteria#getBearingAccuracy()I" -> b.run { if (Build.VERSION.SDK_INT < 9) throw TokamakBinding.unavailable; b.encode(b.target(android.location.Criteria::class.java).getBearingAccuracy()) }
264
+ else -> b.unsupported(method)
265
+ }
266
+
267
+ private fun callGeocoder(method: String, b: TokamakBinding): (() -> Unit)? =
268
+ when (method) {
269
+ "Geocoder#<init>(Landroid/content/Context;)V" -> b.run { b.encode(android.location.Geocoder(b.obj(b[0], android.content.Context::class.java))) }
270
+ "Geocoder#getFromLocation(DDI)Ljava/util/List;" -> b.run { b.encode(b.target(android.location.Geocoder::class.java).getFromLocation(b.double(b[0]), b.double(b[1]), b.int(b[2]))) }
271
+ "Geocoder#getFromLocationName(Ljava/lang/String;I)Ljava/util/List;" -> b.run { b.encode(b.target(android.location.Geocoder::class.java).getFromLocationName(b.string(b[0]), b.int(b[1]))) }
272
+ "Geocoder#getFromLocationName(Ljava/lang/String;IDDDD)Ljava/util/List;" -> b.run { b.encode(b.target(android.location.Geocoder::class.java).getFromLocationName(b.string(b[0]), b.int(b[1]), b.double(b[2]), b.double(b[3]), b.double(b[4]), b.double(b[5]))) }
273
+ "Geocoder#isPresent()Z" -> b.run { if (Build.VERSION.SDK_INT < 9) throw TokamakBinding.unavailable; b.encode(android.location.Geocoder.isPresent()) }
274
+ "Geocoder#getFromLocation(DDILandroid/location/Geocoder\$GeocodeListener;)V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.target(android.location.Geocoder::class.java).getFromLocation(b.double(b[0]), b.double(b[1]), b.int(b[2]), b.obj(b[3], android.location.Geocoder.GeocodeListener::class.java)); null }
275
+ "Geocoder#getFromLocationName(Ljava/lang/String;ILandroid/location/Geocoder\$GeocodeListener;)V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.target(android.location.Geocoder::class.java).getFromLocationName(b.string(b[0]), b.int(b[1]), b.obj(b[2], android.location.Geocoder.GeocodeListener::class.java)); null }
276
+ "Geocoder#getFromLocationName(Ljava/lang/String;IDDDDLandroid/location/Geocoder\$GeocodeListener;)V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.target(android.location.Geocoder::class.java).getFromLocationName(b.string(b[0]), b.int(b[1]), b.double(b[2]), b.double(b[3]), b.double(b[4]), b.double(b[5]), b.obj(b[6], android.location.Geocoder.GeocodeListener::class.java)); null }
277
+ else -> b.unsupported(method)
278
+ }
279
+
280
+ private fun callGeocoder_GeocodeListener(method: String, b: TokamakBinding): (() -> Unit)? =
281
+ when (method) {
282
+ "Geocoder.GeocodeListener#onGeocode(Ljava/util/List;)V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.target(android.location.Geocoder.GeocodeListener::class.java).onGeocode(b.list(b[0]) { x1 -> b.optional(x1) { x2 -> b.obj(x2, android.location.Address::class.java) } }); null }
283
+ "Geocoder.GeocodeListener#onError(Ljava/lang/String;)V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.target(android.location.Geocoder.GeocodeListener::class.java).onError(b.optional(b[0]) { x1 -> b.string(x1) }); null }
284
+ else -> b.unsupported(method)
285
+ }
286
+
287
+ private fun callGnssAntennaInfo(method: String, b: TokamakBinding): (() -> Unit)? =
288
+ when (method) {
289
+ "GnssAntennaInfo#getCarrierFrequencyMHz()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo::class.java).getCarrierFrequencyMHz()) }
290
+ "GnssAntennaInfo#getPhaseCenterOffset()Landroid/location/GnssAntennaInfo\$PhaseCenterOffset;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo::class.java).getPhaseCenterOffset()) }
291
+ "GnssAntennaInfo#getPhaseCenterVariationCorrections()Landroid/location/GnssAntennaInfo\$SphericalCorrections;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo::class.java).getPhaseCenterVariationCorrections()) }
292
+ "GnssAntennaInfo#getSignalGainCorrections()Landroid/location/GnssAntennaInfo\$SphericalCorrections;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo::class.java).getSignalGainCorrections()) }
293
+ "GnssAntennaInfo#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo::class.java).describeContents()) }
294
+ "GnssAntennaInfo#toString()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo::class.java).toString()) }
295
+ "GnssAntennaInfo#equals(Ljava/lang/Object;)Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo::class.java).equals(b.optional(b[0]) { x1 -> b.any(x1) })) }
296
+ "GnssAntennaInfo#hashCode()I" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo::class.java).hashCode()) }
297
+ else -> b.unsupported(method)
298
+ }
299
+
300
+ private fun callGnssAntennaInfo_Builder(method: String, b: TokamakBinding): (() -> Unit)? =
301
+ when (method) {
302
+ "GnssAntennaInfo.Builder#<init>()V" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(android.location.GnssAntennaInfo.Builder()) }
303
+ "GnssAntennaInfo.Builder#setCarrierFrequencyMHz(D)Landroid/location/GnssAntennaInfo\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.Builder::class.java).setCarrierFrequencyMHz(b.double(b[0]))) }
304
+ "GnssAntennaInfo.Builder#setPhaseCenterOffset(Landroid/location/GnssAntennaInfo\$PhaseCenterOffset;)Landroid/location/GnssAntennaInfo\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.Builder::class.java).setPhaseCenterOffset(b.obj(b[0], android.location.GnssAntennaInfo.PhaseCenterOffset::class.java))) }
305
+ "GnssAntennaInfo.Builder#setPhaseCenterVariationCorrections(Landroid/location/GnssAntennaInfo\$SphericalCorrections;)Landroid/location/GnssAntennaInfo\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.Builder::class.java).setPhaseCenterVariationCorrections(b.optional(b[0]) { x1 -> b.obj(x1, android.location.GnssAntennaInfo.SphericalCorrections::class.java) })) }
306
+ "GnssAntennaInfo.Builder#setSignalGainCorrections(Landroid/location/GnssAntennaInfo\$SphericalCorrections;)Landroid/location/GnssAntennaInfo\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.Builder::class.java).setSignalGainCorrections(b.optional(b[0]) { x1 -> b.obj(x1, android.location.GnssAntennaInfo.SphericalCorrections::class.java) })) }
307
+ "GnssAntennaInfo.Builder#build()Landroid/location/GnssAntennaInfo;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.Builder::class.java).build()) }
308
+ "GnssAntennaInfo.Builder#<init>(DLandroid/location/GnssAntennaInfo\$PhaseCenterOffset;)V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(android.location.GnssAntennaInfo.Builder(b.double(b[0]), b.obj(b[1], android.location.GnssAntennaInfo.PhaseCenterOffset::class.java))) }
309
+ "GnssAntennaInfo.Builder#<init>(Landroid/location/GnssAntennaInfo;)V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(android.location.GnssAntennaInfo.Builder(b.obj(b[0], android.location.GnssAntennaInfo::class.java))) }
310
+ else -> b.unsupported(method)
311
+ }
312
+
313
+ private fun callGnssAntennaInfo_Listener(method: String, b: TokamakBinding): (() -> Unit)? =
314
+ when (method) {
315
+ "GnssAntennaInfo.Listener#onGnssAntennaInfoReceived(Ljava/util/List;)V" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.target(android.location.GnssAntennaInfo.Listener::class.java).onGnssAntennaInfoReceived(b.list(b[0]) { x1 -> b.optional(x1) { x2 -> b.obj(x2, android.location.GnssAntennaInfo::class.java) } }); null }
316
+ else -> b.unsupported(method)
317
+ }
318
+
319
+ private fun callGnssAntennaInfo_PhaseCenterOffset(method: String, b: TokamakBinding): (() -> Unit)? =
320
+ when (method) {
321
+ "GnssAntennaInfo.PhaseCenterOffset#<init>(DDDDDD)V" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(android.location.GnssAntennaInfo.PhaseCenterOffset(b.double(b[0]), b.double(b[1]), b.double(b[2]), b.double(b[3]), b.double(b[4]), b.double(b[5]))) }
322
+ "GnssAntennaInfo.PhaseCenterOffset#getXOffsetMm()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.PhaseCenterOffset::class.java).getXOffsetMm()) }
323
+ "GnssAntennaInfo.PhaseCenterOffset#getXOffsetUncertaintyMm()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.PhaseCenterOffset::class.java).getXOffsetUncertaintyMm()) }
324
+ "GnssAntennaInfo.PhaseCenterOffset#getYOffsetMm()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.PhaseCenterOffset::class.java).getYOffsetMm()) }
325
+ "GnssAntennaInfo.PhaseCenterOffset#getYOffsetUncertaintyMm()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.PhaseCenterOffset::class.java).getYOffsetUncertaintyMm()) }
326
+ "GnssAntennaInfo.PhaseCenterOffset#getZOffsetMm()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.PhaseCenterOffset::class.java).getZOffsetMm()) }
327
+ "GnssAntennaInfo.PhaseCenterOffset#getZOffsetUncertaintyMm()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.PhaseCenterOffset::class.java).getZOffsetUncertaintyMm()) }
328
+ "GnssAntennaInfo.PhaseCenterOffset#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.PhaseCenterOffset::class.java).describeContents()) }
329
+ "GnssAntennaInfo.PhaseCenterOffset#toString()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.PhaseCenterOffset::class.java).toString()) }
330
+ "GnssAntennaInfo.PhaseCenterOffset#equals(Ljava/lang/Object;)Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.PhaseCenterOffset::class.java).equals(b.optional(b[0]) { x1 -> b.any(x1) })) }
331
+ "GnssAntennaInfo.PhaseCenterOffset#hashCode()I" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.PhaseCenterOffset::class.java).hashCode()) }
332
+ else -> b.unsupported(method)
333
+ }
334
+
335
+ private fun callGnssAntennaInfo_SphericalCorrections(method: String, b: TokamakBinding): (() -> Unit)? =
336
+ when (method) {
337
+ "GnssAntennaInfo.SphericalCorrections#<init>([[D[[D)V" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(android.location.GnssAntennaInfo.SphericalCorrections(b.list(b[0]) { x1 -> b.optional(x1) { x2 -> b.list(x2) { x3 -> b.double(x3) }.toDoubleArray() } }.toTypedArray(), b.list(b[1]) { x1 -> b.optional(x1) { x2 -> b.list(x2) { x3 -> b.double(x3) }.toDoubleArray() } }.toTypedArray())) }
338
+ "GnssAntennaInfo.SphericalCorrections#getCorrectionsArray()[[D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.SphericalCorrections::class.java).getCorrectionsArray()) }
339
+ "GnssAntennaInfo.SphericalCorrections#getCorrectionUncertaintiesArray()[[D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.SphericalCorrections::class.java).getCorrectionUncertaintiesArray()) }
340
+ "GnssAntennaInfo.SphericalCorrections#getDeltaTheta()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.SphericalCorrections::class.java).getDeltaTheta()) }
341
+ "GnssAntennaInfo.SphericalCorrections#getDeltaPhi()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.SphericalCorrections::class.java).getDeltaPhi()) }
342
+ "GnssAntennaInfo.SphericalCorrections#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.SphericalCorrections::class.java).describeContents()) }
343
+ "GnssAntennaInfo.SphericalCorrections#toString()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.SphericalCorrections::class.java).toString()) }
344
+ "GnssAntennaInfo.SphericalCorrections#equals(Ljava/lang/Object;)Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.SphericalCorrections::class.java).equals(b.optional(b[0]) { x1 -> b.any(x1) })) }
345
+ "GnssAntennaInfo.SphericalCorrections#hashCode()I" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAntennaInfo.SphericalCorrections::class.java).hashCode()) }
346
+ else -> b.unsupported(method)
347
+ }
348
+
349
+ private fun callGnssAutomaticGainControl(method: String, b: TokamakBinding): (() -> Unit)? =
350
+ when (method) {
351
+ "GnssAutomaticGainControl#getLevelDb()D" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAutomaticGainControl::class.java).getLevelDb()) }
352
+ "GnssAutomaticGainControl#getConstellationType()I" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAutomaticGainControl::class.java).getConstellationType()) }
353
+ "GnssAutomaticGainControl#getCarrierFrequencyHz()J" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAutomaticGainControl::class.java).getCarrierFrequencyHz()) }
354
+ "GnssAutomaticGainControl#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAutomaticGainControl::class.java).describeContents()) }
355
+ "GnssAutomaticGainControl#toString()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAutomaticGainControl::class.java).toString()) }
356
+ "GnssAutomaticGainControl#equals(Ljava/lang/Object;)Z" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAutomaticGainControl::class.java).equals(b.optional(b[0]) { x1 -> b.any(x1) })) }
357
+ "GnssAutomaticGainControl#hashCode()I" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAutomaticGainControl::class.java).hashCode()) }
358
+ else -> b.unsupported(method)
359
+ }
360
+
361
+ private fun callGnssAutomaticGainControl_Builder(method: String, b: TokamakBinding): (() -> Unit)? =
362
+ when (method) {
363
+ "GnssAutomaticGainControl.Builder#<init>()V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(android.location.GnssAutomaticGainControl.Builder()) }
364
+ "GnssAutomaticGainControl.Builder#<init>(Landroid/location/GnssAutomaticGainControl;)V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(android.location.GnssAutomaticGainControl.Builder(b.obj(b[0], android.location.GnssAutomaticGainControl::class.java))) }
365
+ "GnssAutomaticGainControl.Builder#setLevelDb(D)Landroid/location/GnssAutomaticGainControl\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAutomaticGainControl.Builder::class.java).setLevelDb(b.double(b[0]))) }
366
+ "GnssAutomaticGainControl.Builder#setConstellationType(I)Landroid/location/GnssAutomaticGainControl\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAutomaticGainControl.Builder::class.java).setConstellationType(b.int(b[0]))) }
367
+ "GnssAutomaticGainControl.Builder#setCarrierFrequencyHz(J)Landroid/location/GnssAutomaticGainControl\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAutomaticGainControl.Builder::class.java).setCarrierFrequencyHz(b.long(b[0]))) }
368
+ "GnssAutomaticGainControl.Builder#build()Landroid/location/GnssAutomaticGainControl;" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssAutomaticGainControl.Builder::class.java).build()) }
369
+ else -> b.unsupported(method)
370
+ }
371
+
372
+ private fun callGnssCapabilities(method: String, b: TokamakBinding): (() -> Unit)? =
373
+ when (method) {
374
+ "GnssCapabilities#hasGnssAntennaInfo()Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasGnssAntennaInfo()) }
375
+ "GnssCapabilities#equals(Ljava/lang/Object;)Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).equals(b.optional(b[0]) { x1 -> b.any(x1) })) }
376
+ "GnssCapabilities#hashCode()I" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hashCode()) }
377
+ "GnssCapabilities#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).describeContents()) }
378
+ "GnssCapabilities#toString()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).toString()) }
379
+ "GnssCapabilities#hasMeasurements()Z" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasMeasurements()) }
380
+ "GnssCapabilities#hasNavigationMessages()Z" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasNavigationMessages()) }
381
+ "GnssCapabilities#hasAntennaInfo()Z" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasAntennaInfo()) }
382
+ "GnssCapabilities#hasScheduling()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasScheduling()) }
383
+ "GnssCapabilities#hasMsb()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasMsb()) }
384
+ "GnssCapabilities#hasMsa()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasMsa()) }
385
+ "GnssCapabilities#hasSingleShotFix()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasSingleShotFix()) }
386
+ "GnssCapabilities#hasOnDemandTime()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasOnDemandTime()) }
387
+ "GnssCapabilities#hasGeofencing()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasGeofencing()) }
388
+ "GnssCapabilities#hasLowPowerMode()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasLowPowerMode()) }
389
+ "GnssCapabilities#hasSatelliteBlocklist()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasSatelliteBlocklist()) }
390
+ "GnssCapabilities#hasSatellitePvt()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasSatellitePvt()) }
391
+ "GnssCapabilities#hasMeasurementCorrections()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasMeasurementCorrections()) }
392
+ "GnssCapabilities#hasMeasurementCorrelationVectors()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasMeasurementCorrelationVectors()) }
393
+ "GnssCapabilities#hasMeasurementCorrectionsForDriving()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasMeasurementCorrectionsForDriving()) }
394
+ "GnssCapabilities#hasAccumulatedDeltaRange()I" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasAccumulatedDeltaRange()) }
395
+ "GnssCapabilities#hasMeasurementCorrectionsLosSats()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasMeasurementCorrectionsLosSats()) }
396
+ "GnssCapabilities#hasMeasurementCorrectionsExcessPathLength()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasMeasurementCorrectionsExcessPathLength()) }
397
+ "GnssCapabilities#hasMeasurementCorrectionsReflectingPlane()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasMeasurementCorrectionsReflectingPlane()) }
398
+ "GnssCapabilities#hasPowerTotal()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasPowerTotal()) }
399
+ "GnssCapabilities#hasPowerSinglebandTracking()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasPowerSinglebandTracking()) }
400
+ "GnssCapabilities#hasPowerMultibandTracking()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasPowerMultibandTracking()) }
401
+ "GnssCapabilities#hasPowerSinglebandAcquisition()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasPowerSinglebandAcquisition()) }
402
+ "GnssCapabilities#hasPowerMultibandAcquisition()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasPowerMultibandAcquisition()) }
403
+ "GnssCapabilities#hasPowerOtherModes()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).hasPowerOtherModes()) }
404
+ "GnssCapabilities#getGnssSignalTypes()Ljava/util/List;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities::class.java).getGnssSignalTypes()) }
405
+ else -> b.unsupported(method)
406
+ }
407
+
408
+ private fun callGnssCapabilities_Builder(method: String, b: TokamakBinding): (() -> Unit)? =
409
+ when (method) {
410
+ "GnssCapabilities.Builder#<init>()V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(android.location.GnssCapabilities.Builder()) }
411
+ "GnssCapabilities.Builder#<init>(Landroid/location/GnssCapabilities;)V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(android.location.GnssCapabilities.Builder(b.obj(b[0], android.location.GnssCapabilities::class.java))) }
412
+ "GnssCapabilities.Builder#setHasMeasurements(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasMeasurements(b.boolean(b[0]))) }
413
+ "GnssCapabilities.Builder#setHasNavigationMessages(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasNavigationMessages(b.boolean(b[0]))) }
414
+ "GnssCapabilities.Builder#setHasAntennaInfo(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasAntennaInfo(b.boolean(b[0]))) }
415
+ "GnssCapabilities.Builder#build()Landroid/location/GnssCapabilities;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).build()) }
416
+ "GnssCapabilities.Builder#setHasScheduling(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasScheduling(b.boolean(b[0]))) }
417
+ "GnssCapabilities.Builder#setHasMsb(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasMsb(b.boolean(b[0]))) }
418
+ "GnssCapabilities.Builder#setHasMsa(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasMsa(b.boolean(b[0]))) }
419
+ "GnssCapabilities.Builder#setHasSingleShotFix(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasSingleShotFix(b.boolean(b[0]))) }
420
+ "GnssCapabilities.Builder#setHasOnDemandTime(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasOnDemandTime(b.boolean(b[0]))) }
421
+ "GnssCapabilities.Builder#setHasGeofencing(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasGeofencing(b.boolean(b[0]))) }
422
+ "GnssCapabilities.Builder#setHasLowPowerMode(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasLowPowerMode(b.boolean(b[0]))) }
423
+ "GnssCapabilities.Builder#setHasSatelliteBlocklist(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasSatelliteBlocklist(b.boolean(b[0]))) }
424
+ "GnssCapabilities.Builder#setHasSatellitePvt(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasSatellitePvt(b.boolean(b[0]))) }
425
+ "GnssCapabilities.Builder#setHasMeasurementCorrections(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasMeasurementCorrections(b.boolean(b[0]))) }
426
+ "GnssCapabilities.Builder#setHasMeasurementCorrelationVectors(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasMeasurementCorrelationVectors(b.boolean(b[0]))) }
427
+ "GnssCapabilities.Builder#setHasMeasurementCorrectionsForDriving(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasMeasurementCorrectionsForDriving(b.boolean(b[0]))) }
428
+ "GnssCapabilities.Builder#setHasAccumulatedDeltaRange(I)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasAccumulatedDeltaRange(b.int(b[0]))) }
429
+ "GnssCapabilities.Builder#setHasMeasurementCorrectionsLosSats(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasMeasurementCorrectionsLosSats(b.boolean(b[0]))) }
430
+ "GnssCapabilities.Builder#setHasMeasurementCorrectionsExcessPathLength(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasMeasurementCorrectionsExcessPathLength(b.boolean(b[0]))) }
431
+ "GnssCapabilities.Builder#setHasMeasurementCorrectionsReflectingPlane(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasMeasurementCorrectionsReflectingPlane(b.boolean(b[0]))) }
432
+ "GnssCapabilities.Builder#setHasPowerTotal(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasPowerTotal(b.boolean(b[0]))) }
433
+ "GnssCapabilities.Builder#setHasPowerSinglebandTracking(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasPowerSinglebandTracking(b.boolean(b[0]))) }
434
+ "GnssCapabilities.Builder#setHasPowerMultibandTracking(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasPowerMultibandTracking(b.boolean(b[0]))) }
435
+ "GnssCapabilities.Builder#setHasPowerSinglebandAcquisition(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasPowerSinglebandAcquisition(b.boolean(b[0]))) }
436
+ "GnssCapabilities.Builder#setHasPowerMultibandAcquisition(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasPowerMultibandAcquisition(b.boolean(b[0]))) }
437
+ "GnssCapabilities.Builder#setHasPowerOtherModes(Z)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setHasPowerOtherModes(b.boolean(b[0]))) }
438
+ "GnssCapabilities.Builder#setGnssSignalTypes(Ljava/util/List;)Landroid/location/GnssCapabilities\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssCapabilities.Builder::class.java).setGnssSignalTypes(b.list(b[0]) { x1 -> b.optional(x1) { x2 -> b.obj(x2, android.location.GnssSignalType::class.java) } })) }
439
+ else -> b.unsupported(method)
440
+ }
441
+
442
+ private fun callGnssClock(method: String, b: TokamakBinding): (() -> Unit)? =
443
+ when (method) {
444
+ "GnssClock#hasLeapSecond()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).hasLeapSecond()) }
445
+ "GnssClock#getLeapSecond()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getLeapSecond()) }
446
+ "GnssClock#getTimeNanos()J" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getTimeNanos()) }
447
+ "GnssClock#hasTimeUncertaintyNanos()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).hasTimeUncertaintyNanos()) }
448
+ "GnssClock#getTimeUncertaintyNanos()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getTimeUncertaintyNanos()) }
449
+ "GnssClock#hasFullBiasNanos()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).hasFullBiasNanos()) }
450
+ "GnssClock#getFullBiasNanos()J" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getFullBiasNanos()) }
451
+ "GnssClock#hasBiasNanos()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).hasBiasNanos()) }
452
+ "GnssClock#getBiasNanos()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getBiasNanos()) }
453
+ "GnssClock#hasBiasUncertaintyNanos()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).hasBiasUncertaintyNanos()) }
454
+ "GnssClock#getBiasUncertaintyNanos()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getBiasUncertaintyNanos()) }
455
+ "GnssClock#hasDriftNanosPerSecond()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).hasDriftNanosPerSecond()) }
456
+ "GnssClock#getDriftNanosPerSecond()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getDriftNanosPerSecond()) }
457
+ "GnssClock#hasDriftUncertaintyNanosPerSecond()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).hasDriftUncertaintyNanosPerSecond()) }
458
+ "GnssClock#getDriftUncertaintyNanosPerSecond()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getDriftUncertaintyNanosPerSecond()) }
459
+ "GnssClock#getHardwareClockDiscontinuityCount()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getHardwareClockDiscontinuityCount()) }
460
+ "GnssClock#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).describeContents()) }
461
+ "GnssClock#toString()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).toString()) }
462
+ "GnssClock#hasElapsedRealtimeNanos()Z" -> b.run { if (Build.VERSION.SDK_INT < 29) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).hasElapsedRealtimeNanos()) }
463
+ "GnssClock#getElapsedRealtimeNanos()J" -> b.run { if (Build.VERSION.SDK_INT < 29) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getElapsedRealtimeNanos()) }
464
+ "GnssClock#hasElapsedRealtimeUncertaintyNanos()Z" -> b.run { if (Build.VERSION.SDK_INT < 29) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).hasElapsedRealtimeUncertaintyNanos()) }
465
+ "GnssClock#getElapsedRealtimeUncertaintyNanos()D" -> b.run { if (Build.VERSION.SDK_INT < 29) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getElapsedRealtimeUncertaintyNanos()) }
466
+ "GnssClock#hasReferenceConstellationTypeForIsb()Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).hasReferenceConstellationTypeForIsb()) }
467
+ "GnssClock#getReferenceConstellationTypeForIsb()I" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getReferenceConstellationTypeForIsb()) }
468
+ "GnssClock#hasReferenceCarrierFrequencyHzForIsb()Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).hasReferenceCarrierFrequencyHzForIsb()) }
469
+ "GnssClock#getReferenceCarrierFrequencyHzForIsb()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getReferenceCarrierFrequencyHzForIsb()) }
470
+ "GnssClock#hasReferenceCodeTypeForIsb()Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).hasReferenceCodeTypeForIsb()) }
471
+ "GnssClock#getReferenceCodeTypeForIsb()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssClock::class.java).getReferenceCodeTypeForIsb()) }
472
+ else -> b.unsupported(method)
473
+ }
474
+
475
+ private fun callGnssMeasurement(method: String, b: TokamakBinding): (() -> Unit)? =
476
+ when (method) {
477
+ "GnssMeasurement#getSvid()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getSvid()) }
478
+ "GnssMeasurement#getConstellationType()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getConstellationType()) }
479
+ "GnssMeasurement#getTimeOffsetNanos()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getTimeOffsetNanos()) }
480
+ "GnssMeasurement#getState()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getState()) }
481
+ "GnssMeasurement#getReceivedSvTimeNanos()J" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getReceivedSvTimeNanos()) }
482
+ "GnssMeasurement#getReceivedSvTimeUncertaintyNanos()J" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getReceivedSvTimeUncertaintyNanos()) }
483
+ "GnssMeasurement#getCn0DbHz()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getCn0DbHz()) }
484
+ "GnssMeasurement#getPseudorangeRateMetersPerSecond()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getPseudorangeRateMetersPerSecond()) }
485
+ "GnssMeasurement#getPseudorangeRateUncertaintyMetersPerSecond()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getPseudorangeRateUncertaintyMetersPerSecond()) }
486
+ "GnssMeasurement#getAccumulatedDeltaRangeState()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getAccumulatedDeltaRangeState()) }
487
+ "GnssMeasurement#getAccumulatedDeltaRangeMeters()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getAccumulatedDeltaRangeMeters()) }
488
+ "GnssMeasurement#getAccumulatedDeltaRangeUncertaintyMeters()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getAccumulatedDeltaRangeUncertaintyMeters()) }
489
+ "GnssMeasurement#hasCarrierFrequencyHz()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).hasCarrierFrequencyHz()) }
490
+ "GnssMeasurement#getCarrierFrequencyHz()F" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getCarrierFrequencyHz()) }
491
+ "GnssMeasurement#hasCarrierCycles()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).hasCarrierCycles()) }
492
+ "GnssMeasurement#getCarrierCycles()J" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getCarrierCycles()) }
493
+ "GnssMeasurement#hasCarrierPhase()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).hasCarrierPhase()) }
494
+ "GnssMeasurement#getCarrierPhase()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getCarrierPhase()) }
495
+ "GnssMeasurement#hasCarrierPhaseUncertainty()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).hasCarrierPhaseUncertainty()) }
496
+ "GnssMeasurement#getCarrierPhaseUncertainty()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getCarrierPhaseUncertainty()) }
497
+ "GnssMeasurement#getMultipathIndicator()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getMultipathIndicator()) }
498
+ "GnssMeasurement#hasSnrInDb()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).hasSnrInDb()) }
499
+ "GnssMeasurement#getSnrInDb()D" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getSnrInDb()) }
500
+ "GnssMeasurement#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).describeContents()) }
501
+ "GnssMeasurement#toString()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).toString()) }
502
+ "GnssMeasurement#hasAutomaticGainControlLevelDb()Z" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).hasAutomaticGainControlLevelDb()) }
503
+ "GnssMeasurement#getAutomaticGainControlLevelDb()D" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getAutomaticGainControlLevelDb()) }
504
+ "GnssMeasurement#hasCodeType()Z" -> b.run { if (Build.VERSION.SDK_INT < 29) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).hasCodeType()) }
505
+ "GnssMeasurement#getCodeType()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 29) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getCodeType()) }
506
+ "GnssMeasurement#hasBasebandCn0DbHz()Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).hasBasebandCn0DbHz()) }
507
+ "GnssMeasurement#getBasebandCn0DbHz()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getBasebandCn0DbHz()) }
508
+ "GnssMeasurement#hasFullInterSignalBiasNanos()Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).hasFullInterSignalBiasNanos()) }
509
+ "GnssMeasurement#getFullInterSignalBiasNanos()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getFullInterSignalBiasNanos()) }
510
+ "GnssMeasurement#hasFullInterSignalBiasUncertaintyNanos()Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).hasFullInterSignalBiasUncertaintyNanos()) }
511
+ "GnssMeasurement#getFullInterSignalBiasUncertaintyNanos()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getFullInterSignalBiasUncertaintyNanos()) }
512
+ "GnssMeasurement#hasSatelliteInterSignalBiasNanos()Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).hasSatelliteInterSignalBiasNanos()) }
513
+ "GnssMeasurement#getSatelliteInterSignalBiasNanos()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getSatelliteInterSignalBiasNanos()) }
514
+ "GnssMeasurement#hasSatelliteInterSignalBiasUncertaintyNanos()Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).hasSatelliteInterSignalBiasUncertaintyNanos()) }
515
+ "GnssMeasurement#getSatelliteInterSignalBiasUncertaintyNanos()D" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurement::class.java).getSatelliteInterSignalBiasUncertaintyNanos()) }
516
+ else -> b.unsupported(method)
517
+ }
518
+
519
+ private fun callGnssMeasurementRequest(method: String, b: TokamakBinding): (() -> Unit)? =
520
+ when (method) {
521
+ "GnssMeasurementRequest#isFullTracking()Z" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementRequest::class.java).isFullTracking()) }
522
+ "GnssMeasurementRequest#toString()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementRequest::class.java).toString()) }
523
+ "GnssMeasurementRequest#equals(Ljava/lang/Object;)Z" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementRequest::class.java).equals(b.optional(b[0]) { x1 -> b.any(x1) })) }
524
+ "GnssMeasurementRequest#hashCode()I" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementRequest::class.java).hashCode()) }
525
+ "GnssMeasurementRequest#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementRequest::class.java).describeContents()) }
526
+ "GnssMeasurementRequest#getIntervalMillis()I" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementRequest::class.java).getIntervalMillis()) }
527
+ else -> b.unsupported(method)
528
+ }
529
+
530
+ private fun callGnssMeasurementRequest_Builder(method: String, b: TokamakBinding): (() -> Unit)? =
531
+ when (method) {
532
+ "GnssMeasurementRequest.Builder#<init>()V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(android.location.GnssMeasurementRequest.Builder()) }
533
+ "GnssMeasurementRequest.Builder#<init>(Landroid/location/GnssMeasurementRequest;)V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(android.location.GnssMeasurementRequest.Builder(b.obj(b[0], android.location.GnssMeasurementRequest::class.java))) }
534
+ "GnssMeasurementRequest.Builder#setFullTracking(Z)Landroid/location/GnssMeasurementRequest\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementRequest.Builder::class.java).setFullTracking(b.boolean(b[0]))) }
535
+ "GnssMeasurementRequest.Builder#build()Landroid/location/GnssMeasurementRequest;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementRequest.Builder::class.java).build()) }
536
+ "GnssMeasurementRequest.Builder#setIntervalMillis(I)Landroid/location/GnssMeasurementRequest\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementRequest.Builder::class.java).setIntervalMillis(b.int(b[0]))) }
537
+ else -> b.unsupported(method)
538
+ }
539
+
540
+ private fun callGnssMeasurementsEvent(method: String, b: TokamakBinding): (() -> Unit)? =
541
+ when (method) {
542
+ "GnssMeasurementsEvent#getClock()Landroid/location/GnssClock;" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent::class.java).getClock()) }
543
+ "GnssMeasurementsEvent#getMeasurements()Ljava/util/Collection;" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent::class.java).getMeasurements()) }
544
+ "GnssMeasurementsEvent#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent::class.java).describeContents()) }
545
+ "GnssMeasurementsEvent#toString()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent::class.java).toString()) }
546
+ "GnssMeasurementsEvent#getGnssAutomaticGainControls()Ljava/util/Collection;" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent::class.java).getGnssAutomaticGainControls()) }
547
+ "GnssMeasurementsEvent#isFullTracking()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent::class.java).isFullTracking()) }
548
+ "GnssMeasurementsEvent#hasIsFullTracking()Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent::class.java).hasIsFullTracking()) }
549
+ else -> b.unsupported(method)
550
+ }
551
+
552
+ private fun callGnssMeasurementsEvent_Builder(method: String, b: TokamakBinding): (() -> Unit)? =
553
+ when (method) {
554
+ "GnssMeasurementsEvent.Builder#<init>()V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(android.location.GnssMeasurementsEvent.Builder()) }
555
+ "GnssMeasurementsEvent.Builder#<init>(Landroid/location/GnssMeasurementsEvent;)V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(android.location.GnssMeasurementsEvent.Builder(b.obj(b[0], android.location.GnssMeasurementsEvent::class.java))) }
556
+ "GnssMeasurementsEvent.Builder#setClock(Landroid/location/GnssClock;)Landroid/location/GnssMeasurementsEvent\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent.Builder::class.java).setClock(b.obj(b[0], android.location.GnssClock::class.java))) }
557
+ "GnssMeasurementsEvent.Builder#setMeasurements(Ljava/util/Collection;)Landroid/location/GnssMeasurementsEvent\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent.Builder::class.java).setMeasurements(b.list(b[0]) { x1 -> b.optional(x1) { x2 -> b.obj(x2, android.location.GnssMeasurement::class.java) } })) }
558
+ "GnssMeasurementsEvent.Builder#setGnssAutomaticGainControls(Ljava/util/Collection;)Landroid/location/GnssMeasurementsEvent\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent.Builder::class.java).setGnssAutomaticGainControls(b.list(b[0]) { x1 -> b.optional(x1) { x2 -> b.obj(x2, android.location.GnssAutomaticGainControl::class.java) } })) }
559
+ "GnssMeasurementsEvent.Builder#build()Landroid/location/GnssMeasurementsEvent;" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent.Builder::class.java).build()) }
560
+ "GnssMeasurementsEvent.Builder#setIsFullTracking(Z)Landroid/location/GnssMeasurementsEvent\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent.Builder::class.java).setIsFullTracking(b.boolean(b[0]))) }
561
+ "GnssMeasurementsEvent.Builder#clearIsFullTracking()Landroid/location/GnssMeasurementsEvent\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssMeasurementsEvent.Builder::class.java).clearIsFullTracking()) }
562
+ else -> b.unsupported(method)
563
+ }
564
+
565
+ private fun callGnssMeasurementsEvent_Callback(method: String, b: TokamakBinding): (() -> Unit)? =
566
+ when (method) {
567
+ "GnssMeasurementsEvent.Callback#onGnssMeasurementsReceived(Landroid/location/GnssMeasurementsEvent;)V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.GnssMeasurementsEvent.Callback::class.java).onGnssMeasurementsReceived(b.optional(b[0]) { x1 -> b.obj(x1, android.location.GnssMeasurementsEvent::class.java) }); null }
568
+ "GnssMeasurementsEvent.Callback#onStatusChanged(I)V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.GnssMeasurementsEvent.Callback::class.java).onStatusChanged(b.int(b[0])); null }
569
+ else -> b.unsupported(method)
570
+ }
571
+
572
+ private fun callGnssNavigationMessage(method: String, b: TokamakBinding): (() -> Unit)? =
573
+ when (method) {
574
+ "GnssNavigationMessage#getType()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssNavigationMessage::class.java).getType()) }
575
+ "GnssNavigationMessage#getSvid()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssNavigationMessage::class.java).getSvid()) }
576
+ "GnssNavigationMessage#getMessageId()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssNavigationMessage::class.java).getMessageId()) }
577
+ "GnssNavigationMessage#getSubmessageId()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssNavigationMessage::class.java).getSubmessageId()) }
578
+ "GnssNavigationMessage#getData()[B" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssNavigationMessage::class.java).getData()) }
579
+ "GnssNavigationMessage#getStatus()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssNavigationMessage::class.java).getStatus()) }
580
+ "GnssNavigationMessage#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssNavigationMessage::class.java).describeContents()) }
581
+ "GnssNavigationMessage#toString()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssNavigationMessage::class.java).toString()) }
582
+ else -> b.unsupported(method)
583
+ }
584
+
585
+ private fun callGnssNavigationMessage_Callback(method: String, b: TokamakBinding): (() -> Unit)? =
586
+ when (method) {
587
+ "GnssNavigationMessage.Callback#onGnssNavigationMessageReceived(Landroid/location/GnssNavigationMessage;)V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.GnssNavigationMessage.Callback::class.java).onGnssNavigationMessageReceived(b.optional(b[0]) { x1 -> b.obj(x1, android.location.GnssNavigationMessage::class.java) }); null }
588
+ "GnssNavigationMessage.Callback#onStatusChanged(I)V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.GnssNavigationMessage.Callback::class.java).onStatusChanged(b.int(b[0])); null }
589
+ else -> b.unsupported(method)
590
+ }
591
+
592
+ private fun callGnssSignalType(method: String, b: TokamakBinding): (() -> Unit)? =
593
+ when (method) {
594
+ "GnssSignalType#create(IDLjava/lang/String;)Landroid/location/GnssSignalType;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(android.location.GnssSignalType.create(b.int(b[0]), b.double(b[1]), b.string(b[2]))) }
595
+ "GnssSignalType#getConstellationType()I" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssSignalType::class.java).getConstellationType()) }
596
+ "GnssSignalType#getCarrierFrequencyHz()D" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssSignalType::class.java).getCarrierFrequencyHz()) }
597
+ "GnssSignalType#getCodeType()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssSignalType::class.java).getCodeType()) }
598
+ "GnssSignalType#toString()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssSignalType::class.java).toString()) }
599
+ "GnssSignalType#equals(Ljava/lang/Object;)Z" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssSignalType::class.java).equals(b.optional(b[0]) { x1 -> b.any(x1) })) }
600
+ "GnssSignalType#hashCode()I" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssSignalType::class.java).hashCode()) }
601
+ "GnssSignalType#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssSignalType::class.java).describeContents()) }
602
+ else -> b.unsupported(method)
603
+ }
604
+
605
+ private fun callGnssStatus(method: String, b: TokamakBinding): (() -> Unit)? =
606
+ when (method) {
607
+ "GnssStatus#getSatelliteCount()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).getSatelliteCount()) }
608
+ "GnssStatus#getConstellationType(I)I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).getConstellationType(b.int(b[0]))) }
609
+ "GnssStatus#getSvid(I)I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).getSvid(b.int(b[0]))) }
610
+ "GnssStatus#getCn0DbHz(I)F" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).getCn0DbHz(b.int(b[0]))) }
611
+ "GnssStatus#getElevationDegrees(I)F" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).getElevationDegrees(b.int(b[0]))) }
612
+ "GnssStatus#getAzimuthDegrees(I)F" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).getAzimuthDegrees(b.int(b[0]))) }
613
+ "GnssStatus#hasEphemerisData(I)Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).hasEphemerisData(b.int(b[0]))) }
614
+ "GnssStatus#hasAlmanacData(I)Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).hasAlmanacData(b.int(b[0]))) }
615
+ "GnssStatus#usedInFix(I)Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).usedInFix(b.int(b[0]))) }
616
+ "GnssStatus#equals(Ljava/lang/Object;)Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).equals(b.optional(b[0]) { x1 -> b.any(x1) })) }
617
+ "GnssStatus#hashCode()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).hashCode()) }
618
+ "GnssStatus#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).describeContents()) }
619
+ "GnssStatus#hasCarrierFrequencyHz(I)Z" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).hasCarrierFrequencyHz(b.int(b[0]))) }
620
+ "GnssStatus#getCarrierFrequencyHz(I)F" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).getCarrierFrequencyHz(b.int(b[0]))) }
621
+ "GnssStatus#hasBasebandCn0DbHz(I)Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).hasBasebandCn0DbHz(b.int(b[0]))) }
622
+ "GnssStatus#getBasebandCn0DbHz(I)F" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus::class.java).getBasebandCn0DbHz(b.int(b[0]))) }
623
+ else -> b.unsupported(method)
624
+ }
625
+
626
+ private fun callGnssStatus_Builder(method: String, b: TokamakBinding): (() -> Unit)? =
627
+ when (method) {
628
+ "GnssStatus.Builder#<init>()V" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(android.location.GnssStatus.Builder()) }
629
+ "GnssStatus.Builder#addSatellite(IIFFFZZZZFZF)Landroid/location/GnssStatus\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus.Builder::class.java).addSatellite(b.int(b[0]), b.int(b[1]), b.float(b[2]), b.float(b[3]), b.float(b[4]), b.boolean(b[5]), b.boolean(b[6]), b.boolean(b[7]), b.boolean(b[8]), b.float(b[9]), b.boolean(b[10]), b.float(b[11]))) }
630
+ "GnssStatus.Builder#clearSatellites()Landroid/location/GnssStatus\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus.Builder::class.java).clearSatellites()) }
631
+ "GnssStatus.Builder#build()Landroid/location/GnssStatus;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GnssStatus.Builder::class.java).build()) }
632
+ else -> b.unsupported(method)
633
+ }
634
+
635
+ private fun callGnssStatus_Callback(method: String, b: TokamakBinding): (() -> Unit)? =
636
+ when (method) {
637
+ "GnssStatus.Callback#onStarted()V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.GnssStatus.Callback::class.java).onStarted(); null }
638
+ "GnssStatus.Callback#onStopped()V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.GnssStatus.Callback::class.java).onStopped(); null }
639
+ "GnssStatus.Callback#onFirstFix(I)V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.GnssStatus.Callback::class.java).onFirstFix(b.int(b[0])); null }
640
+ "GnssStatus.Callback#onSatelliteStatusChanged(Landroid/location/GnssStatus;)V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.GnssStatus.Callback::class.java).onSatelliteStatusChanged(b.obj(b[0], android.location.GnssStatus::class.java)); null }
641
+ else -> b.unsupported(method)
642
+ }
643
+
644
+ private fun callGpsSatellite(method: String, b: TokamakBinding): (() -> Unit)? =
645
+ when (method) {
646
+ "GpsSatellite#getPrn()I" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GpsSatellite::class.java).getPrn()) }
647
+ "GpsSatellite#getSnr()F" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GpsSatellite::class.java).getSnr()) }
648
+ "GpsSatellite#getElevation()F" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GpsSatellite::class.java).getElevation()) }
649
+ "GpsSatellite#getAzimuth()F" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GpsSatellite::class.java).getAzimuth()) }
650
+ "GpsSatellite#hasEphemeris()Z" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GpsSatellite::class.java).hasEphemeris()) }
651
+ "GpsSatellite#hasAlmanac()Z" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GpsSatellite::class.java).hasAlmanac()) }
652
+ "GpsSatellite#usedInFix()Z" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GpsSatellite::class.java).usedInFix()) }
653
+ else -> b.unsupported(method)
654
+ }
655
+
656
+ private fun callGpsStatus(method: String, b: TokamakBinding): (() -> Unit)? =
657
+ when (method) {
658
+ "GpsStatus#getTimeToFirstFix()I" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GpsStatus::class.java).getTimeToFirstFix()) }
659
+ "GpsStatus#getMaxSatellites()I" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.encode(b.target(android.location.GpsStatus::class.java).getMaxSatellites()) }
660
+ "GpsStatus#create(Landroid/location/GnssStatus;I)Landroid/location/GpsStatus;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(android.location.GpsStatus.create(b.obj(b[0], android.location.GnssStatus::class.java), b.int(b[1]))) }
661
+ else -> b.unsupported(method)
662
+ }
663
+
664
+ private fun callGpsStatus_Listener(method: String, b: TokamakBinding): (() -> Unit)? =
665
+ when (method) {
666
+ "GpsStatus.Listener#onGpsStatusChanged(I)V" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.target(android.location.GpsStatus.Listener::class.java).onGpsStatusChanged(b.int(b[0])); null }
667
+ else -> b.unsupported(method)
668
+ }
669
+
670
+ private fun callGpsStatus_NmeaListener(method: String, b: TokamakBinding): (() -> Unit)? =
671
+ when (method) {
672
+ "GpsStatus.NmeaListener#onNmeaReceived(JLjava/lang/String;)V" -> b.run { if (Build.VERSION.SDK_INT < 5) throw TokamakBinding.unavailable; b.target(android.location.GpsStatus.NmeaListener::class.java).onNmeaReceived(b.long(b[0]), b.optional(b[1]) { x1 -> b.string(x1) }); null }
673
+ else -> b.unsupported(method)
674
+ }
675
+
676
+ private fun callLocationListener(method: String, b: TokamakBinding): (() -> Unit)? =
677
+ when (method) {
678
+ "LocationListener#onLocationChanged(Landroid/location/Location;)V" -> b.run { b.target(android.location.LocationListener::class.java).onLocationChanged(b.obj(b[0], android.location.Location::class.java)); null }
679
+ "LocationListener#onProviderEnabled(Ljava/lang/String;)V" -> b.run { b.target(android.location.LocationListener::class.java).onProviderEnabled(b.string(b[0])); null }
680
+ "LocationListener#onProviderDisabled(Ljava/lang/String;)V" -> b.run { b.target(android.location.LocationListener::class.java).onProviderDisabled(b.string(b[0])); null }
681
+ "LocationListener#onLocationChanged(Ljava/util/List;)V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.target(android.location.LocationListener::class.java).onLocationChanged(b.list(b[0]) { x1 -> b.optional(x1) { x2 -> b.obj(x2, android.location.Location::class.java) } }); null }
682
+ "LocationListener#onFlushComplete(I)V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.target(android.location.LocationListener::class.java).onFlushComplete(b.int(b[0])); null }
683
+ else -> b.unsupported(method)
684
+ }
685
+
686
+ private fun callLocationManager(method: String, b: TokamakBinding): (() -> Unit)? =
687
+ when (method) {
688
+ "LocationManager#isProviderEnabled(Ljava/lang/String;)Z" -> b.run { b.encode(b.target(android.location.LocationManager::class.java).isProviderEnabled(b.string(b[0]))) }
689
+ "LocationManager#getLastKnownLocation(Ljava/lang/String;)Landroid/location/Location;" -> b.run { b.encode(b.target(android.location.LocationManager::class.java).getLastKnownLocation(b.string(b[0]))) }
690
+ "LocationManager#requestLocationUpdates(Ljava/lang/String;JFLandroid/location/LocationListener;)V" -> b.run { b.target(android.location.LocationManager::class.java).requestLocationUpdates(b.string(b[0]), b.long(b[1]), b.float(b[2]), b.obj(b[3], android.location.LocationListener::class.java)); null }
691
+ "LocationManager#removeUpdates(Landroid/location/LocationListener;)V" -> b.run { b.target(android.location.LocationManager::class.java).removeUpdates(b.obj(b[0], android.location.LocationListener::class.java)); null }
692
+ "LocationManager#getAllProviders()Ljava/util/List;" -> b.run { b.encode(b.target(android.location.LocationManager::class.java).getAllProviders()) }
693
+ "LocationManager#getProviders(Z)Ljava/util/List;" -> b.run { b.encode(b.target(android.location.LocationManager::class.java).getProviders(b.boolean(b[0]))) }
694
+ "LocationManager#getProviders(Landroid/location/Criteria;Z)Ljava/util/List;" -> b.run { b.encode(b.target(android.location.LocationManager::class.java).getProviders(b.obj(b[0], android.location.Criteria::class.java), b.boolean(b[1]))) }
695
+ "LocationManager#getBestProvider(Landroid/location/Criteria;Z)Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.LocationManager::class.java).getBestProvider(b.obj(b[0], android.location.Criteria::class.java), b.boolean(b[1]))) }
696
+ "LocationManager#getProvider(Ljava/lang/String;)Landroid/location/LocationProvider;" -> b.run { b.encode(b.target(android.location.LocationManager::class.java).getProvider(b.string(b[0]))) }
697
+ "LocationManager#addTestProvider(Ljava/lang/String;ZZZZZZZII)V" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).addTestProvider(b.string(b[0]), b.boolean(b[1]), b.boolean(b[2]), b.boolean(b[3]), b.boolean(b[4]), b.boolean(b[5]), b.boolean(b[6]), b.boolean(b[7]), b.int(b[8]), b.int(b[9])); null }
698
+ "LocationManager#removeTestProvider(Ljava/lang/String;)V" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).removeTestProvider(b.string(b[0])); null }
699
+ "LocationManager#setTestProviderLocation(Ljava/lang/String;Landroid/location/Location;)V" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).setTestProviderLocation(b.string(b[0]), b.obj(b[1], android.location.Location::class.java)); null }
700
+ "LocationManager#clearTestProviderLocation(Ljava/lang/String;)V" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).clearTestProviderLocation(b.string(b[0])); null }
701
+ "LocationManager#setTestProviderEnabled(Ljava/lang/String;Z)V" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).setTestProviderEnabled(b.string(b[0]), b.boolean(b[1])); null }
702
+ "LocationManager#clearTestProviderEnabled(Ljava/lang/String;)V" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).clearTestProviderEnabled(b.string(b[0])); null }
703
+ "LocationManager#clearTestProviderStatus(Ljava/lang/String;)V" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).clearTestProviderStatus(b.string(b[0])); null }
704
+ "LocationManager#getGpsStatus(Landroid/location/GpsStatus;)Landroid/location/GpsStatus;" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).getGpsStatus(b.optional(b[0]) { x1 -> b.obj(x1, android.location.GpsStatus::class.java) })) }
705
+ "LocationManager#addGpsStatusListener(Landroid/location/GpsStatus\$Listener;)Z" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).addGpsStatusListener(b.optional(b[0]) { x1 -> b.obj(x1, android.location.GpsStatus.Listener::class.java) })) }
706
+ "LocationManager#removeGpsStatusListener(Landroid/location/GpsStatus\$Listener;)V" -> b.run { if (Build.VERSION.SDK_INT < 3) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).removeGpsStatusListener(b.optional(b[0]) { x1 -> b.obj(x1, android.location.GpsStatus.Listener::class.java) }); null }
707
+ "LocationManager#addNmeaListener(Landroid/location/GpsStatus\$NmeaListener;)Z" -> b.run { if (Build.VERSION.SDK_INT < 5) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).addNmeaListener(b.obj(b[0], android.location.GpsStatus.NmeaListener::class.java))) }
708
+ "LocationManager#removeNmeaListener(Landroid/location/GpsStatus\$NmeaListener;)V" -> b.run { if (Build.VERSION.SDK_INT < 5) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).removeNmeaListener(b.obj(b[0], android.location.GpsStatus.NmeaListener::class.java)); null }
709
+ "LocationManager#registerGnssStatusCallback(Landroid/location/GnssStatus\$Callback;)Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).registerGnssStatusCallback(b.obj(b[0], android.location.GnssStatus.Callback::class.java))) }
710
+ "LocationManager#unregisterGnssStatusCallback(Landroid/location/GnssStatus\$Callback;)V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).unregisterGnssStatusCallback(b.obj(b[0], android.location.GnssStatus.Callback::class.java)); null }
711
+ "LocationManager#addNmeaListener(Landroid/location/OnNmeaMessageListener;)Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).addNmeaListener(b.obj(b[0], android.location.OnNmeaMessageListener::class.java))) }
712
+ "LocationManager#removeNmeaListener(Landroid/location/OnNmeaMessageListener;)V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).removeNmeaListener(b.obj(b[0], android.location.OnNmeaMessageListener::class.java)); null }
713
+ "LocationManager#registerGnssMeasurementsCallback(Landroid/location/GnssMeasurementsEvent\$Callback;)Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).registerGnssMeasurementsCallback(b.obj(b[0], android.location.GnssMeasurementsEvent.Callback::class.java))) }
714
+ "LocationManager#unregisterGnssMeasurementsCallback(Landroid/location/GnssMeasurementsEvent\$Callback;)V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).unregisterGnssMeasurementsCallback(b.obj(b[0], android.location.GnssMeasurementsEvent.Callback::class.java)); null }
715
+ "LocationManager#registerGnssNavigationMessageCallback(Landroid/location/GnssNavigationMessage\$Callback;)Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).registerGnssNavigationMessageCallback(b.obj(b[0], android.location.GnssNavigationMessage.Callback::class.java))) }
716
+ "LocationManager#unregisterGnssNavigationMessageCallback(Landroid/location/GnssNavigationMessage\$Callback;)V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).unregisterGnssNavigationMessageCallback(b.obj(b[0], android.location.GnssNavigationMessage.Callback::class.java)); null }
717
+ "LocationManager#isLocationEnabled()Z" -> b.run { if (Build.VERSION.SDK_INT < 28) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).isLocationEnabled()) }
718
+ "LocationManager#getGnssYearOfHardware()I" -> b.run { if (Build.VERSION.SDK_INT < 28) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).getGnssYearOfHardware()) }
719
+ "LocationManager#getGnssHardwareModelName()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 28) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).getGnssHardwareModelName()) }
720
+ "LocationManager#getCurrentLocation(Ljava/lang/String;Landroid/os/CancellationSignal;Ljava/util/concurrent/Executor;Ljava/util/function/Consumer;)V" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).getCurrentLocation(b.string(b[0]), b.optional(b[1]) { x1 -> b.obj(x1, android.os.CancellationSignal::class.java) }, b.obj(b[2], java.util.concurrent.Executor::class.java), (b.obj(b[3], java.util.function.Consumer::class.java) as java.util.function.Consumer<android.location.Location?>)); null }
721
+ "LocationManager#requestLocationUpdates(Ljava/lang/String;JFLjava/util/concurrent/Executor;Landroid/location/LocationListener;)V" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).requestLocationUpdates(b.string(b[0]), b.long(b[1]), b.float(b[2]), b.obj(b[3], java.util.concurrent.Executor::class.java), b.obj(b[4], android.location.LocationListener::class.java)); null }
722
+ "LocationManager#requestLocationUpdates(JFLandroid/location/Criteria;Ljava/util/concurrent/Executor;Landroid/location/LocationListener;)V" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).requestLocationUpdates(b.long(b[0]), b.float(b[1]), b.obj(b[2], android.location.Criteria::class.java), b.obj(b[3], java.util.concurrent.Executor::class.java), b.obj(b[4], android.location.LocationListener::class.java)); null }
723
+ "LocationManager#getGnssCapabilities()Landroid/location/GnssCapabilities;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).getGnssCapabilities()) }
724
+ "LocationManager#registerGnssStatusCallback(Ljava/util/concurrent/Executor;Landroid/location/GnssStatus\$Callback;)Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).registerGnssStatusCallback(b.obj(b[0], java.util.concurrent.Executor::class.java), b.obj(b[1], android.location.GnssStatus.Callback::class.java))) }
725
+ "LocationManager#addNmeaListener(Ljava/util/concurrent/Executor;Landroid/location/OnNmeaMessageListener;)Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).addNmeaListener(b.obj(b[0], java.util.concurrent.Executor::class.java), b.obj(b[1], android.location.OnNmeaMessageListener::class.java))) }
726
+ "LocationManager#registerGnssMeasurementsCallback(Ljava/util/concurrent/Executor;Landroid/location/GnssMeasurementsEvent\$Callback;)Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).registerGnssMeasurementsCallback(b.obj(b[0], java.util.concurrent.Executor::class.java), b.obj(b[1], android.location.GnssMeasurementsEvent.Callback::class.java))) }
727
+ "LocationManager#registerAntennaInfoListener(Ljava/util/concurrent/Executor;Landroid/location/GnssAntennaInfo\$Listener;)Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).registerAntennaInfoListener(b.obj(b[0], java.util.concurrent.Executor::class.java), b.obj(b[1], android.location.GnssAntennaInfo.Listener::class.java))) }
728
+ "LocationManager#unregisterAntennaInfoListener(Landroid/location/GnssAntennaInfo\$Listener;)V" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).unregisterAntennaInfoListener(b.obj(b[0], android.location.GnssAntennaInfo.Listener::class.java)); null }
729
+ "LocationManager#registerGnssNavigationMessageCallback(Ljava/util/concurrent/Executor;Landroid/location/GnssNavigationMessage\$Callback;)Z" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).registerGnssNavigationMessageCallback(b.obj(b[0], java.util.concurrent.Executor::class.java), b.obj(b[1], android.location.GnssNavigationMessage.Callback::class.java))) }
730
+ "LocationManager#getCurrentLocation(Ljava/lang/String;Landroid/location/LocationRequest;Landroid/os/CancellationSignal;Ljava/util/concurrent/Executor;Ljava/util/function/Consumer;)V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).getCurrentLocation(b.string(b[0]), b.obj(b[1], android.location.LocationRequest::class.java), b.optional(b[2]) { x1 -> b.obj(x1, android.os.CancellationSignal::class.java) }, b.obj(b[3], java.util.concurrent.Executor::class.java), (b.obj(b[4], java.util.function.Consumer::class.java) as java.util.function.Consumer<android.location.Location?>)); null }
731
+ "LocationManager#requestLocationUpdates(Ljava/lang/String;Landroid/location/LocationRequest;Ljava/util/concurrent/Executor;Landroid/location/LocationListener;)V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).requestLocationUpdates(b.string(b[0]), b.obj(b[1], android.location.LocationRequest::class.java), b.obj(b[2], java.util.concurrent.Executor::class.java), b.obj(b[3], android.location.LocationListener::class.java)); null }
732
+ "LocationManager#requestFlush(Ljava/lang/String;Landroid/location/LocationListener;I)V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.target(android.location.LocationManager::class.java).requestFlush(b.string(b[0]), b.obj(b[1], android.location.LocationListener::class.java), b.int(b[2])); null }
733
+ "LocationManager#hasProvider(Ljava/lang/String;)Z" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).hasProvider(b.string(b[0]))) }
734
+ "LocationManager#getGnssAntennaInfos()Ljava/util/List;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).getGnssAntennaInfos()) }
735
+ "LocationManager#registerGnssMeasurementsCallback(Landroid/location/GnssMeasurementRequest;Ljava/util/concurrent/Executor;Landroid/location/GnssMeasurementsEvent\$Callback;)Z" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationManager::class.java).registerGnssMeasurementsCallback(b.obj(b[0], android.location.GnssMeasurementRequest::class.java), b.obj(b[1], java.util.concurrent.Executor::class.java), b.obj(b[2], android.location.GnssMeasurementsEvent.Callback::class.java))) }
736
+ else -> b.unsupported(method)
737
+ }
738
+
739
+ private fun callLocationProvider(method: String, b: TokamakBinding): (() -> Unit)? =
740
+ when (method) {
741
+ "LocationProvider#getName()Ljava/lang/String;" -> b.run { b.encode(b.target(android.location.LocationProvider::class.java).getName()) }
742
+ "LocationProvider#meetsCriteria(Landroid/location/Criteria;)Z" -> b.run { b.encode(b.target(android.location.LocationProvider::class.java).meetsCriteria(b.optional(b[0]) { x1 -> b.obj(x1, android.location.Criteria::class.java) })) }
743
+ "LocationProvider#requiresNetwork()Z" -> b.run { b.encode(b.target(android.location.LocationProvider::class.java).requiresNetwork()) }
744
+ "LocationProvider#requiresSatellite()Z" -> b.run { b.encode(b.target(android.location.LocationProvider::class.java).requiresSatellite()) }
745
+ "LocationProvider#requiresCell()Z" -> b.run { b.encode(b.target(android.location.LocationProvider::class.java).requiresCell()) }
746
+ "LocationProvider#hasMonetaryCost()Z" -> b.run { b.encode(b.target(android.location.LocationProvider::class.java).hasMonetaryCost()) }
747
+ "LocationProvider#supportsAltitude()Z" -> b.run { b.encode(b.target(android.location.LocationProvider::class.java).supportsAltitude()) }
748
+ "LocationProvider#supportsSpeed()Z" -> b.run { b.encode(b.target(android.location.LocationProvider::class.java).supportsSpeed()) }
749
+ "LocationProvider#supportsBearing()Z" -> b.run { b.encode(b.target(android.location.LocationProvider::class.java).supportsBearing()) }
750
+ "LocationProvider#getPowerRequirement()I" -> b.run { b.encode(b.target(android.location.LocationProvider::class.java).getPowerRequirement()) }
751
+ "LocationProvider#getAccuracy()I" -> b.run { b.encode(b.target(android.location.LocationProvider::class.java).getAccuracy()) }
752
+ else -> b.unsupported(method)
753
+ }
754
+
755
+ private fun callLocationRequest(method: String, b: TokamakBinding): (() -> Unit)? =
756
+ when (method) {
757
+ "LocationRequest#getQuality()I" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest::class.java).getQuality()) }
758
+ "LocationRequest#getIntervalMillis()J" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest::class.java).getIntervalMillis()) }
759
+ "LocationRequest#getDurationMillis()J" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest::class.java).getDurationMillis()) }
760
+ "LocationRequest#getMaxUpdates()I" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest::class.java).getMaxUpdates()) }
761
+ "LocationRequest#getMinUpdateIntervalMillis()J" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest::class.java).getMinUpdateIntervalMillis()) }
762
+ "LocationRequest#getMinUpdateDistanceMeters()F" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest::class.java).getMinUpdateDistanceMeters()) }
763
+ "LocationRequest#getMaxUpdateDelayMillis()J" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest::class.java).getMaxUpdateDelayMillis()) }
764
+ "LocationRequest#describeContents()I" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest::class.java).describeContents()) }
765
+ "LocationRequest#equals(Ljava/lang/Object;)Z" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest::class.java).equals(b.optional(b[0]) { x1 -> b.any(x1) })) }
766
+ "LocationRequest#hashCode()I" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest::class.java).hashCode()) }
767
+ "LocationRequest#toString()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest::class.java).toString()) }
768
+ else -> b.unsupported(method)
769
+ }
770
+
771
+ private fun callLocationRequest_Builder(method: String, b: TokamakBinding): (() -> Unit)? =
772
+ when (method) {
773
+ "LocationRequest.Builder#<init>(J)V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(android.location.LocationRequest.Builder(b.long(b[0]))) }
774
+ "LocationRequest.Builder#<init>(Landroid/location/LocationRequest;)V" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(android.location.LocationRequest.Builder(b.obj(b[0], android.location.LocationRequest::class.java))) }
775
+ "LocationRequest.Builder#setIntervalMillis(J)Landroid/location/LocationRequest\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest.Builder::class.java).setIntervalMillis(b.long(b[0]))) }
776
+ "LocationRequest.Builder#setQuality(I)Landroid/location/LocationRequest\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest.Builder::class.java).setQuality(b.int(b[0]))) }
777
+ "LocationRequest.Builder#setDurationMillis(J)Landroid/location/LocationRequest\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest.Builder::class.java).setDurationMillis(b.long(b[0]))) }
778
+ "LocationRequest.Builder#setMaxUpdates(I)Landroid/location/LocationRequest\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest.Builder::class.java).setMaxUpdates(b.int(b[0]))) }
779
+ "LocationRequest.Builder#setMinUpdateIntervalMillis(J)Landroid/location/LocationRequest\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest.Builder::class.java).setMinUpdateIntervalMillis(b.long(b[0]))) }
780
+ "LocationRequest.Builder#clearMinUpdateIntervalMillis()Landroid/location/LocationRequest\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest.Builder::class.java).clearMinUpdateIntervalMillis()) }
781
+ "LocationRequest.Builder#setMinUpdateDistanceMeters(F)Landroid/location/LocationRequest\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest.Builder::class.java).setMinUpdateDistanceMeters(b.float(b[0]))) }
782
+ "LocationRequest.Builder#setMaxUpdateDelayMillis(J)Landroid/location/LocationRequest\$Builder;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest.Builder::class.java).setMaxUpdateDelayMillis(b.long(b[0]))) }
783
+ "LocationRequest.Builder#build()Landroid/location/LocationRequest;" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.location.LocationRequest.Builder::class.java).build()) }
784
+ else -> b.unsupported(method)
785
+ }
786
+
787
+ private fun callOnNmeaMessageListener(method: String, b: TokamakBinding): (() -> Unit)? =
788
+ when (method) {
789
+ "OnNmeaMessageListener#onNmeaMessage(Ljava/lang/String;J)V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.target(android.location.OnNmeaMessageListener::class.java).onNmeaMessage(b.optional(b[0]) { x1 -> b.string(x1) }, b.long(b[1])); null }
790
+ else -> b.unsupported(method)
791
+ }
792
+
793
+ private fun callSettingInjectorService(method: String, b: TokamakBinding): (() -> Unit)? =
794
+ when (method) {
795
+ "SettingInjectorService#refreshSettings(Landroid/content/Context;)V" -> b.run { if (Build.VERSION.SDK_INT < 29) throw TokamakBinding.unavailable; android.location.SettingInjectorService.refreshSettings(b.obj(b[0], android.content.Context::class.java)); null }
796
+ else -> b.unsupported(method)
797
+ }
798
+
799
+ private fun callContext(method: String, b: TokamakBinding): (() -> Unit)? =
800
+ when (method) {
801
+ "Context#getApplicationContext()Landroid/content/Context;" -> b.run { b.encode(b.target(android.content.Context::class.java).getApplicationContext()) }
802
+ "Context#getText(I)Ljava/lang/CharSequence;" -> b.run { b.encode(b.target(android.content.Context::class.java).getText(b.int(b[0]))) }
803
+ "Context#getString(I)Ljava/lang/String;" -> b.run { b.encode(b.target(android.content.Context::class.java).getString(b.int(b[0]))) }
804
+ "Context#getString(I[Ljava/lang/Object;)Ljava/lang/String;" -> b.run { b.encode(b.target(android.content.Context::class.java).getString(b.int(b[0]), *b.list(b[1]) { x1 -> b.optional(x1) { x2 -> b.any(x2) } }.toTypedArray())) }
805
+ "Context#setTheme(I)V" -> b.run { b.target(android.content.Context::class.java).setTheme(b.int(b[0])); null }
806
+ "Context#getPackageName()Ljava/lang/String;" -> b.run { b.encode(b.target(android.content.Context::class.java).getPackageName()) }
807
+ "Context#deleteFile(Ljava/lang/String;)Z" -> b.run { b.encode(b.target(android.content.Context::class.java).deleteFile(b.optional(b[0]) { x1 -> b.string(x1) })) }
808
+ "Context#fileList()[Ljava/lang/String;" -> b.run { b.encode(b.target(android.content.Context::class.java).fileList()) }
809
+ "Context#deleteDatabase(Ljava/lang/String;)Z" -> b.run { b.encode(b.target(android.content.Context::class.java).deleteDatabase(b.optional(b[0]) { x1 -> b.string(x1) })) }
810
+ "Context#databaseList()[Ljava/lang/String;" -> b.run { b.encode(b.target(android.content.Context::class.java).databaseList()) }
811
+ "Context#getWallpaperDesiredMinimumWidth()I" -> b.run { b.encode(b.target(android.content.Context::class.java).getWallpaperDesiredMinimumWidth()) }
812
+ "Context#getWallpaperDesiredMinimumHeight()I" -> b.run { b.encode(b.target(android.content.Context::class.java).getWallpaperDesiredMinimumHeight()) }
813
+ "Context#clearWallpaper()V" -> b.run { b.target(android.content.Context::class.java).clearWallpaper(); null }
814
+ "Context#getSystemService(Ljava/lang/String;)Ljava/lang/Object;" -> b.run { b.encode(b.target(android.content.Context::class.java).getSystemService(b.string(b[0]))) }
815
+ "Context#checkPermission(Ljava/lang/String;II)I" -> b.run { b.encode(b.target(android.content.Context::class.java).checkPermission(b.string(b[0]), b.int(b[1]), b.int(b[2]))) }
816
+ "Context#checkCallingPermission(Ljava/lang/String;)I" -> b.run { b.encode(b.target(android.content.Context::class.java).checkCallingPermission(b.string(b[0]))) }
817
+ "Context#checkCallingOrSelfPermission(Ljava/lang/String;)I" -> b.run { b.encode(b.target(android.content.Context::class.java).checkCallingOrSelfPermission(b.string(b[0]))) }
818
+ "Context#enforcePermission(Ljava/lang/String;IILjava/lang/String;)V" -> b.run { b.target(android.content.Context::class.java).enforcePermission(b.string(b[0]), b.int(b[1]), b.int(b[2]), b.optional(b[3]) { x1 -> b.string(x1) }); null }
819
+ "Context#enforceCallingPermission(Ljava/lang/String;Ljava/lang/String;)V" -> b.run { b.target(android.content.Context::class.java).enforceCallingPermission(b.string(b[0]), b.optional(b[1]) { x1 -> b.string(x1) }); null }
820
+ "Context#enforceCallingOrSelfPermission(Ljava/lang/String;Ljava/lang/String;)V" -> b.run { b.target(android.content.Context::class.java).enforceCallingOrSelfPermission(b.string(b[0]), b.optional(b[1]) { x1 -> b.string(x1) }); null }
821
+ "Context#createPackageContext(Ljava/lang/String;I)Landroid/content/Context;" -> b.run { b.encode(b.target(android.content.Context::class.java).createPackageContext(b.optional(b[0]) { x1 -> b.string(x1) }, b.int(b[1]))) }
822
+ "Context#isRestricted()Z" -> b.run { if (Build.VERSION.SDK_INT < 4) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).isRestricted()) }
823
+ "Context#getPackageResourcePath()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 8) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).getPackageResourcePath()) }
824
+ "Context#getPackageCodePath()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 8) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).getPackageCodePath()) }
825
+ "Context#getColor(I)I" -> b.run { if (Build.VERSION.SDK_INT < 23) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).getColor(b.int(b[0]))) }
826
+ "Context#checkSelfPermission(Ljava/lang/String;)I" -> b.run { if (Build.VERSION.SDK_INT < 23) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).checkSelfPermission(b.string(b[0]))) }
827
+ "Context#moveSharedPreferencesFrom(Landroid/content/Context;Ljava/lang/String;)Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).moveSharedPreferencesFrom(b.optional(b[0]) { x1 -> b.obj(x1, android.content.Context::class.java) }, b.optional(b[1]) { x1 -> b.string(x1) })) }
828
+ "Context#deleteSharedPreferences(Ljava/lang/String;)Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).deleteSharedPreferences(b.optional(b[0]) { x1 -> b.string(x1) })) }
829
+ "Context#moveDatabaseFrom(Landroid/content/Context;Ljava/lang/String;)Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).moveDatabaseFrom(b.optional(b[0]) { x1 -> b.obj(x1, android.content.Context::class.java) }, b.optional(b[1]) { x1 -> b.string(x1) })) }
830
+ "Context#createDeviceProtectedStorageContext()Landroid/content/Context;" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).createDeviceProtectedStorageContext()) }
831
+ "Context#isDeviceProtectedStorage()Z" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).isDeviceProtectedStorage()) }
832
+ "Context#createContextForSplit(Ljava/lang/String;)Landroid/content/Context;" -> b.run { if (Build.VERSION.SDK_INT < 26) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).createContextForSplit(b.optional(b[0]) { x1 -> b.string(x1) })) }
833
+ "Context#getMainExecutor()Ljava/util/concurrent/Executor;" -> b.run { if (Build.VERSION.SDK_INT < 28) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).getMainExecutor()) }
834
+ "Context#getOpPackageName()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 29) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).getOpPackageName()) }
835
+ "Context#getAttributionTag()Ljava/lang/String;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).getAttributionTag()) }
836
+ "Context#createAttributionContext(Ljava/lang/String;)Landroid/content/Context;" -> b.run { if (Build.VERSION.SDK_INT < 30) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).createAttributionContext(b.optional(b[0]) { x1 -> b.string(x1) })) }
837
+ "Context#isUiContext()Z" -> b.run { if (Build.VERSION.SDK_INT < 31) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).isUiContext()) }
838
+ "Context#revokeSelfPermissionOnKill(Ljava/lang/String;)V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.target(android.content.Context::class.java).revokeSelfPermissionOnKill(b.string(b[0])); null }
839
+ "Context#revokeSelfPermissionsOnKill(Ljava/util/Collection;)V" -> b.run { if (Build.VERSION.SDK_INT < 33) throw TokamakBinding.unavailable; b.target(android.content.Context::class.java).revokeSelfPermissionsOnKill(b.list(b[0]) { x1 -> b.optional(x1) { x2 -> b.string(x2) } }); null }
840
+ "Context#createDeviceContext(I)Landroid/content/Context;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).createDeviceContext(b.int(b[0]))) }
841
+ "Context#getDeviceId()I" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(b.target(android.content.Context::class.java).getDeviceId()) }
842
+ else -> b.unsupported(method)
843
+ }
844
+
845
+ private fun callContext_BindServiceFlags(method: String, b: TokamakBinding): (() -> Unit)? =
846
+ when (method) {
847
+ "Context.BindServiceFlags#of(J)Landroid/content/Context\$BindServiceFlags;" -> b.run { if (Build.VERSION.SDK_INT < 34) throw TokamakBinding.unavailable; b.encode(android.content.Context.BindServiceFlags.of(b.long(b[0]))) }
848
+ else -> b.unsupported(method)
849
+ }
850
+
851
+ private fun callCancellationSignal(method: String, b: TokamakBinding): (() -> Unit)? =
852
+ when (method) {
853
+ "CancellationSignal#<init>()V" -> b.run { if (Build.VERSION.SDK_INT < 16) throw TokamakBinding.unavailable; b.encode(android.os.CancellationSignal()) }
854
+ "CancellationSignal#isCanceled()Z" -> b.run { if (Build.VERSION.SDK_INT < 16) throw TokamakBinding.unavailable; b.encode(b.target(android.os.CancellationSignal::class.java).isCanceled()) }
855
+ "CancellationSignal#throwIfCanceled()V" -> b.run { if (Build.VERSION.SDK_INT < 16) throw TokamakBinding.unavailable; b.target(android.os.CancellationSignal::class.java).throwIfCanceled(); null }
856
+ "CancellationSignal#cancel()V" -> b.run { if (Build.VERSION.SDK_INT < 16) throw TokamakBinding.unavailable; b.target(android.os.CancellationSignal::class.java).cancel(); null }
857
+ "CancellationSignal#setOnCancelListener(Landroid/os/CancellationSignal\$OnCancelListener;)V" -> b.run { if (Build.VERSION.SDK_INT < 16) throw TokamakBinding.unavailable; b.target(android.os.CancellationSignal::class.java).setOnCancelListener(b.optional(b[0]) { x1 -> b.obj(x1, android.os.CancellationSignal.OnCancelListener::class.java) }); null }
858
+ else -> b.unsupported(method)
859
+ }
860
+
861
+ private fun callCancellationSignal_OnCancelListener(method: String, b: TokamakBinding): (() -> Unit)? =
862
+ when (method) {
863
+ "CancellationSignal.OnCancelListener#onCancel()V" -> b.run { if (Build.VERSION.SDK_INT < 16) throw TokamakBinding.unavailable; b.target(android.os.CancellationSignal.OnCancelListener::class.java).onCancel(); null }
864
+ else -> b.unsupported(method)
865
+ }
866
+
867
+ private fun callSystemClock(method: String, b: TokamakBinding): (() -> Unit)? =
868
+ when (method) {
869
+ "SystemClock#sleep(J)V" -> b.run { android.os.SystemClock.sleep(b.long(b[0])); null }
870
+ "SystemClock#setCurrentTimeMillis(J)Z" -> b.run { b.encode(android.os.SystemClock.setCurrentTimeMillis(b.long(b[0]))) }
871
+ "SystemClock#uptimeMillis()J" -> b.run { b.encode(android.os.SystemClock.uptimeMillis()) }
872
+ "SystemClock#elapsedRealtime()J" -> b.run { b.encode(android.os.SystemClock.elapsedRealtime()) }
873
+ "SystemClock#currentThreadTimeMillis()J" -> b.run { b.encode(android.os.SystemClock.currentThreadTimeMillis()) }
874
+ "SystemClock#elapsedRealtimeNanos()J" -> b.run { if (Build.VERSION.SDK_INT < 17) throw TokamakBinding.unavailable; b.encode(android.os.SystemClock.elapsedRealtimeNanos()) }
875
+ "SystemClock#uptimeNanos()J" -> b.run { if (Build.VERSION.SDK_INT < 35) throw TokamakBinding.unavailable; b.encode(android.os.SystemClock.uptimeNanos()) }
876
+ else -> b.unsupported(method)
877
+ }
878
+
879
+ private fun callConsumer(method: String, b: TokamakBinding): (() -> Unit)? =
880
+ when (method) {
881
+ "Consumer#accept(Ljava/lang/Object;)V" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; (b.target(java.util.function.Consumer::class.java) as java.util.function.Consumer<Any?>).accept(b.optional(b[0]) { x1 -> b.any(x1) }); null }
882
+ "Consumer#andThen(Ljava/util/function/Consumer;)Ljava/util/function/Consumer;" -> b.run { if (Build.VERSION.SDK_INT < 24) throw TokamakBinding.unavailable; b.encode((b.target(java.util.function.Consumer::class.java) as java.util.function.Consumer<Any?>).andThen(b.optional(b[0]) { x1 -> (b.obj(x1, java.util.function.Consumer::class.java) as java.util.function.Consumer<Any?>) })) }
883
+ else -> b.unsupported(method)
884
+ }
885
+
886
+ @androidx.annotation.RequiresApi(33)
887
+ private class Geocoder_GeocodeListenerImplementation(private val binding: TokamakBinding) : android.location.Geocoder.GeocodeListener {
888
+ override fun onGeocode(addresses: MutableList<android.location.Address?>) {
889
+ binding.call("onGeocode") { b -> listOf(b.encode(addresses)) }
890
+ }
891
+
892
+ override fun onError(errorMessage: String?) {
893
+ if (!binding.call("onError") { b -> listOf(b.encode(errorMessage)) }) super.onError(errorMessage)
894
+ }
895
+ }
896
+
897
+ @androidx.annotation.RequiresApi(30)
898
+ private class GnssAntennaInfo_ListenerImplementation(private val binding: TokamakBinding) : android.location.GnssAntennaInfo.Listener {
899
+ override fun onGnssAntennaInfoReceived(gnssAntennaInfos: MutableList<android.location.GnssAntennaInfo?>) {
900
+ binding.call("onGnssAntennaInfoReceived") { b -> listOf(b.encode(gnssAntennaInfos)) }
901
+ }
902
+ }
903
+
904
+ @androidx.annotation.RequiresApi(24)
905
+ private class GnssMeasurementsEvent_CallbackImplementation(private val binding: TokamakBinding) : android.location.GnssMeasurementsEvent.Callback() {
906
+ override fun onGnssMeasurementsReceived(eventArgs: android.location.GnssMeasurementsEvent?) {
907
+ if (!binding.call("onGnssMeasurementsReceived") { b -> listOf(b.encode(eventArgs)) }) super.onGnssMeasurementsReceived(eventArgs)
908
+ }
909
+
910
+ override fun onStatusChanged(status: Int) {
911
+ if (!binding.call("onStatusChanged") { b -> listOf(b.encode(status)) }) super.onStatusChanged(status)
912
+ }
913
+ }
914
+
915
+ @androidx.annotation.RequiresApi(24)
916
+ private class GnssNavigationMessage_CallbackImplementation(private val binding: TokamakBinding) : android.location.GnssNavigationMessage.Callback() {
917
+ override fun onGnssNavigationMessageReceived(event: android.location.GnssNavigationMessage?) {
918
+ if (!binding.call("onGnssNavigationMessageReceived") { b -> listOf(b.encode(event)) }) super.onGnssNavigationMessageReceived(event)
919
+ }
920
+
921
+ override fun onStatusChanged(status: Int) {
922
+ if (!binding.call("onStatusChanged") { b -> listOf(b.encode(status)) }) super.onStatusChanged(status)
923
+ }
924
+ }
925
+
926
+ @androidx.annotation.RequiresApi(24)
927
+ private class GnssStatus_CallbackImplementation(private val binding: TokamakBinding) : android.location.GnssStatus.Callback() {
928
+ override fun onStarted() {
929
+ if (!binding.call("onStarted") { b -> listOf() }) super.onStarted()
930
+ }
931
+
932
+ override fun onStopped() {
933
+ if (!binding.call("onStopped") { b -> listOf() }) super.onStopped()
934
+ }
935
+
936
+ override fun onFirstFix(ttffMillis: Int) {
937
+ if (!binding.call("onFirstFix") { b -> listOf(b.encode(ttffMillis)) }) super.onFirstFix(ttffMillis)
938
+ }
939
+
940
+ override fun onSatelliteStatusChanged(status: android.location.GnssStatus) {
941
+ if (!binding.call("onSatelliteStatusChanged") { b -> listOf(b.encode(status)) }) super.onSatelliteStatusChanged(status)
942
+ }
943
+ }
944
+
945
+ @androidx.annotation.RequiresApi(3)
946
+ private class GpsStatus_ListenerImplementation(private val binding: TokamakBinding) : android.location.GpsStatus.Listener {
947
+ override fun onGpsStatusChanged(event: Int) {
948
+ binding.call("onGpsStatusChanged") { b -> listOf(b.encode(event)) }
949
+ }
950
+ }
951
+
952
+ @androidx.annotation.RequiresApi(5)
953
+ private class GpsStatus_NmeaListenerImplementation(private val binding: TokamakBinding) : android.location.GpsStatus.NmeaListener {
954
+ override fun onNmeaReceived(timestamp: Long, nmea: String?) {
955
+ binding.call("onNmeaReceived") { b -> listOf(b.encode(timestamp), b.encode(nmea)) }
956
+ }
957
+ }
958
+
959
+ private class LocationListenerImplementation(private val binding: TokamakBinding) : android.location.LocationListener {
960
+ override fun onLocationChanged(location: android.location.Location) {
961
+ binding.call("onLocationChanged") { b -> listOf(b.encode(location)) }
962
+ }
963
+
964
+ override fun onFlushComplete(requestCode: Int) {
965
+ if (!binding.call("onFlushComplete") { b -> listOf(b.encode(requestCode)) }) super.onFlushComplete(requestCode)
966
+ }
967
+
968
+ override fun onProviderEnabled(provider: String) {
969
+ if (!binding.call("onProviderEnabled") { b -> listOf(b.encode(provider)) }) super.onProviderEnabled(provider)
970
+ }
971
+
972
+ override fun onProviderDisabled(provider: String) {
973
+ if (!binding.call("onProviderDisabled") { b -> listOf(b.encode(provider)) }) super.onProviderDisabled(provider)
974
+ }
975
+ }
976
+
977
+ @androidx.annotation.RequiresApi(24)
978
+ private class OnNmeaMessageListenerImplementation(private val binding: TokamakBinding) : android.location.OnNmeaMessageListener {
979
+ override fun onNmeaMessage(message: String?, timestamp: Long) {
980
+ binding.call("onNmeaMessage") { b -> listOf(b.encode(message), b.encode(timestamp)) }
981
+ }
982
+ }
983
+
984
+ @androidx.annotation.RequiresApi(16)
985
+ private class CancellationSignal_OnCancelListenerImplementation(private val binding: TokamakBinding) : android.os.CancellationSignal.OnCancelListener {
986
+ override fun onCancel() {
987
+ binding.call("onCancel") { b -> listOf() }
988
+ }
989
+ }
990
+
991
+ @androidx.annotation.RequiresApi(24)
992
+ private class ConsumerImplementation(private val binding: TokamakBinding) : java.util.function.Consumer<Any?> {
993
+ override fun accept(t: Any?) {
994
+ binding.call("accept") { b -> listOf(b.encode(t)) }
995
+ }
996
+ }
997
+ }