Questions tagged [kotlin]

Kotlin is an open-source, statically typed programming language backed by JetBrains. Kotlin combines OO and functional features and is focused on interoperability, safety, clarity, and tooling support. It currently targets the JVM and JavaScript, and it's an officially supported language on Android.

0
votes
0answers
9 views

Compare values of common properties of objects in kotlin

I'm trying to write a method that will compare the 'common properties' (sharing the same name/type) of two objects in Kotlin. Its intended to be used for in tests, comparing 'expected' with 'actual' ...
0
votes
0answers
5 views

Can't place Callback or updateItem code to customized TableColumn in JavaFX/Kotlin

I want to change checked checkbox to unchecked when I click newButton. Therefore, on handelNew function, I assigned false value to Item.select. When I run handleNew function, it set every Item.select ...
0
votes
1answer
25 views

Rails app always returns “Unprocessable Entity” to Android

I'm trying to connect an Android App to a RoR App so it can create a new user, but no matter what I do I always get "Unprocessable Entity". Right now I'm using Kotlin instead of Java. ...
0
votes
0answers
26 views

Custom Expandable/Collapsible CardView

Background I've been trying to implement my own collapsible/expandable CardView using the solution provided by the answer to this SO question as my basis. I've been trying to this in Kotlin instead ...
0
votes
0answers
11 views

How to map this Rest Url parameters using Retrofit

A Rest API I'm intent to use has this endpoint definition and the gived example below it: // aaapi.cgi?q={query}-!{syear},{eyear}-!{snfrate},{enfrate}-!{simdbrate},{eimdbrate}-!{genreid}-!{vtype}...
-1
votes
0answers
16 views

How to convert String to list in Kotlin

I have this kind of String: [ [ [3,"some string",6],8,"another string"],7,7]. And I want to convert to an multidimensional list. My expectation is to have a multidimensional list where I can access ...
0
votes
3answers
25 views

Kotlin - filtering a list of objects by comparing to a list of properties

I have a class Person: class Person(var fullName: String, var nickname: String, var age: Int) In my code, at some point I have a List of Person objects, and a list of nicknames. var people: List<...
1
vote
1answer
27 views

How to handle polymorphism in kotlin

I am working with an abstract class and two concrete ones, which implementing the abstract one. The diagram is as the next: My classes looks as: abstract class NavItem() { var attributes: String ...
3
votes
1answer
34 views

(imutable collection is mutable) returns true in Kotlin

Why this is happening in Kotlin: val list: List<Int> = listOf(1, 2, 3)// Immutable list if(list is MutableCollection<*>){// why this "if" condition is true? println("is mutable")// ...
2
votes
1answer
21 views

Unable to Start Acticity Component Info

In my project, I am trying to save data into a sqllite database and trying to read those data once its saved. I am able to write all the data in the database but while trying to retrieve the data then ...
0
votes
0answers
7 views

Sign in with Facebook, Firebase is changing UID when signing in the second time, Kotlin Android Studio

I want to sign in Automaticly when I load the activity if it was logged in before and not logged out, but when I create a new user, after commenting out the on start check if user is signed in part,it ...
0
votes
1answer
18 views

Retrofit call gives default values and not the values needed

The problem that I have is when I do a retrofit call to my backend it knows that there are 4 objects but all the objects are having the default values instead of the correct values. When I do a call ...
0
votes
0answers
16 views

What causes “Unsatisfied dependency expressed through method 'setTargetDatastore' parameter 0”?

I'm a complete novice regarding Spring applications, and I'm trying to integrate a project using Kotlin + Spring + GORM (Which requires usage of Groovy). When I try to run it I get: Exception ...
0
votes
0answers
16 views

Move map camera to center of new visible zone

I have NestedScrollView which appears when I'm clicking on marker map. But, for now, map is centering marker, so sometimes he appers under nestedScrollView. How to make marker in center of new area (...
-2
votes
2answers
17 views

CardStackView null

class HomeFragment : Fragment(), CardStackListener { val cardStackView = card_stack_view val manager = CardStackLayoutManager(getActivity(), this) private val adapter by lazy { CardStackAdapter(...

15 30 50 per page