Category "kotlin"

How to solve flutter Execution failed for task ':twitter_login:compileReleaseKotlin' error?

I am trying to build an apk from my flutter application. I am using the algolia native api and modified my FlutterActivity according to this official documentat

Coroutines test with spek

i'm try to write test for my viewModel function with coroutines. When request is success -> the data is sent to LiveData. If the request fails -> it is re

How to solve flutter Execution failed for task ':twitter_login:compileReleaseKotlin' error?

I am trying to build an apk from my flutter application. I am using the algolia native api and modified my FlutterActivity according to this official documentat

Updating a Single Column In Room Database

That's the function I'm using for updat private fun updateSettingsDatabase(settingsDao: SettingsDao) { lifecycleScope.launch { settingsDao.u

org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.lambda$executeIfValid$

I am getting runtime exception while building the project. I have added Jetpack compose dependencies extra to the build.gradle file. I could see the following e

How to prevent onDismiss Callback to be call, in custom AlertDialog with Jetpack Compose

I was developing an app which I use Jetpack compose to define the UI. I was implementing some localdatabase such as Room, and I try to implement the remove oper

Ktor 2 - How to add thread local data for a request?

Before Ktor 2 it was possible to use withContext(threadLocal.asContextElement(..)) { proceed() } inside an ApplicationFeature to add thread local data to a

Unresolved reference: ExposedDropdownMenuBox in Compose for Desktop

I need to implement a drop down menu for Windows App which is based on Compose for Desktop For that I am trying to use ExposedDropdownMenuBox But I am getting e

Why does a Flow which return records from Room keep to emit data when I add onStart { }? Is it bugs of Room or Compose?

I query records and return them as Flow<List<RecordEntity>> with Room. I run code A, and get result A as I expected. I hope to display a Loading UI

Azure Service Bus Amqp token issue

I'm using Azure Service Bus, and Managed ID to authenticate to it. I'm using Kotlin and Quarkus, in an AKS environment. Now my issue is that when I deploy my co

Could not resolve com.squareup.moshi:moshi-kotlin:1.13.0

Getting this error and unable to build Gradle file. Android Studio Version : Bumblebee Latest Patch Gradle Plugin Version : 7.1.2 Gradle Version : 7.2 I already

Delay before next line on code on android SurfaceView kotlin

Hello how can I delay the next line of code after drawing because the sleep() doesn't seem to draw the bitmap with canvas take a look at this code I read somewh

How can I spoof prop values that don't belong to android.os.Build?

With the following segment of code I'm able to spoof certain build.prop parameters such as brand, manufactuer, device, product and model: data class DeviceEntri

Using Resource wrapper with multiple entities and mapper classes in clean architecture android

Let's say we have an app that is going to apply clean architecture principles. we have repositories, data sources(local & remote), multiple value objects fo

Android and Detekt: Aligning .idea CodeStyle with detekt

I have an Android project that i've set up with Detekt. I'm currently using: io.gitlab.arturbosch.detekt:detekt-gradle-plugin:1.19.0 (Root build.gradle) io.gitl

Share a queue between the mainThread and a coroutine

I am new to the coroutine concept. I'm not very confident in the code I've written. Basically I have a queue of user events that I send to my server. Adding an

I have been trying to add a chat sdk to my project

I added the cometchat sdk to my project but each time i try to run my app i get the following errors org.gradle.api.internal.artifacts.ivyservice.DefaultLenient

How to write regex to identify different date patterns of a String in android?

I receive different date patterns in APIs. Is there any way to identify the date pattern of the string received in an API so that I can format them without thro

Kotlin Coroutines Unit Testing

Im trying to test this suspend function: suspend fun <T> getResult(call: suspend () -> Response<T>): Resource<T> { val response = call()

I can draw a straight line between two points but I want to draw a route. how to do this? com.google.maps.android.compose

I'm using the free Maps SDK for Android with https://googlemaps.github.io/android-maps-compose/index.html I wanted to draw lines between two points.but Polyline