Not yet Kotlin
πŸ‘︎ 1k
πŸ’¬︎
πŸ“…︎ Jan 10 2022
🚨︎ report
I dedicated 3 years to building this Android Contacts API library written in Kotlin with Java interop. I want to share it with the Reddit community for the first time.

Hi! My name is Vandolf. I am very excited to share with you, and with the entire Android community, what I have been putting my heart and soul into consistently for the past 3 years. My love and gratitude for Android development has kept me motivated to work on this project non-stop. This is my way of giving back to the Android community because this career path has enabled me to break the cycle of poverty in my family lineage. I am not doing this for fame or money. I simply want to give back ❀️

So...

Let's solve the Contacts Provider, together! 🀝

The Contacts Provider is huge, complex, and full of rules and behaviors that we have no control over and may differ with every flavor and version of Android. With this in mind, I have built and documented a large set of APIs packaged into a single cohesive library.

GitHub project: https://github.com/vestrel00/contacts-android

Showcasing usage of the Contacts, Reborn library. Not all features are shown.

>I initially made a different video for this post out of excitement but I figured this one is more appropriate πŸ˜„.

Features!

  • βœ… Harness the full potential of the Contacts Provider without having to deal with ContentProvider operations and cursors.
  • βœ… All of the tools you need to create your own full-fleged Contacts app.
  • βœ… Fully interoptible with Java. It is Kotlin-first and Java-second (with love and care).
  • βœ… Barriers to entry is ZERO. Whether you have yet to write your first line of code, or you are just getting started with Android development, or you've been at it for over a decade, this library will guide you on how to use it.
  • βœ… Extensions (optional) for multi-threading and permissions with Kotlin Coroutines.
  • βœ… Create, Read, Update, and Delete (CRUD) operations for all columns in all tables within the Contacts Provider database; Contacts, RawContacts, Data, Groups, Profile, and AggregationExceptions.
  • βœ… Provides a powerful, type-safe query DSL that utilizes the magic of Kotlin.
  • βœ… Built with optimization in mind; include only desired fields in read and write operations and supports pagination (sort/orderBy, offset, limit) and cancellations.
  • βœ… Fully documented entities that model all common data kinds; *
... keep reading on reddit ➑

πŸ‘︎ 312
πŸ’¬︎
πŸ‘€︎ u/vestrel00
πŸ“…︎ Jan 08 2022
🚨︎ report
Is there an "Odin Project" fo Kotlin/Android dev?

Obviously I'm not 100% sure because I'm a beginner. But I'm excited to create apps via Kotlin for mobile.

Other than Google's courses for Kotlin that I have found, are there any online sources to learn the language, especially to the level of proficiency of getting an entry level/Jr Android dev type of job?

πŸ‘︎ 117
πŸ’¬︎
πŸ‘€︎ u/Vagabond_Tea
πŸ“…︎ Jan 19 2022
🚨︎ report
Is IntelliJ the only working IDE for Kotlin?

I tried NetBeans, and discovered that its Kotlin plugin has been abandoned for years. Then I tried Eclipse, and it did not work at all. I used the latest Eclipse and installed the Kotlin plugin using the in-built software installation feature, but creating a new Kotlin project threw an exception, and manually creating a .kt file also threw an exception. So, unless you are those kind of geniuses who can write code using Notepad, you are pretty much vendor-locked in IntelliJ?

πŸ‘︎ 52
πŸ’¬︎
πŸ‘€︎ u/evolution2015
πŸ“…︎ Jan 20 2022
🚨︎ report
Companies that use server-side Kotlin

Hey all, just curious for some research at work:

Do you guys know enterprise-grade companies that are using Kotlin server-side (meaning other than Android dev )? If so, to what extent? Would you be willing to share the name (here or in PM)? How is Kotlin being used? I would love to do some research and digging on companies currently adopting Kotlin over a more time-tested tech like Java or .NET! See if I can get my company on board!

πŸ‘︎ 64
πŸ’¬︎
πŸ‘€︎ u/tr14l
πŸ“…︎ Dec 25 2021
🚨︎ report
JetBrains launches cross-platform UI framework for Kotlin infoworld.com/article/364…
πŸ‘︎ 425
πŸ’¬︎
πŸ‘€︎ u/IsDaouda_Games
πŸ“…︎ Dec 04 2021
🚨︎ report
Kotlin Collection Functions that Generate a New List
πŸ‘︎ 75
πŸ’¬︎
πŸ‘€︎ u/ElyeProj
πŸ“…︎ Jan 17 2022
🚨︎ report
Is it worth rewriting large Java project into Kotlin?

I am working on a web app with backend in Java. The project information are:

  • ~2000 java files
  • almost 200k lines of code (excluding empty lines)
  • multimodule maven project and few microservices
  • currently using Java 11, Spring Boot, Hibernate

It was decided that current code should migrate to Kotlin over time, I am trying to get an opinion on this, but from what I learned so far I think it's not worth the effort to go through migration of this scale. The project has a lot of code and design issues itself, developers (4 total) don't have a lot of experience with Kotlin, some none at all.

My questions are:

  • Do you think the migration effort would be worth it?
  • What would be the biggest advantage of having whole code base in Kotlin?
  • What would be the biggest disadvantage of the migration?
πŸ‘︎ 27
πŸ’¬︎
πŸ‘€︎ u/ThreeDots3
πŸ“…︎ Jan 24 2022
🚨︎ report
Kotlin Collection Functions: Zip, ZipWithNext, UnZip
πŸ‘︎ 64
πŸ’¬︎
πŸ‘€︎ u/ElyeProj
πŸ“…︎ Jan 19 2022
🚨︎ report
Estou Γ  procura de pessoas que querem trabalhar com Ruby (Rails) ou Kotlin (Android/Spring) remotamente de Portugal na minha equipa internacional (Australiana / Portuguesa)

A empresa Γ© Air tasker. Pode saber quase tudo aqui https://www.airtasker.automic.com.au/news/annualreportfy21

ExperiΓͺncia com tecnologias gerais do Web/cloud 5-10 anos. (Por exemplo JSON APIs, HTTP/HTTPS, routing + request lifecycles, CDNs, serviΓ§os do notificaçáes como APNs/FCM/GCM/Twilio/Pusher, SQL ou NoSQL DBs, responsive UIs, etc)

ExperiΓͺncia com Ruby/Kotlin pode ser menos ou sΓ³ interesse.

A coisa mais importante, do qualquer experiΓͺncia com as tecnologias referidas, ser uma pessoa que trabalha bem com complexidade e ambiguidade.

Salario: ~3-5k€/mΓ©s bruto.

Projeto: Mercado do serviΓ§os locais como Zaask mas internacional (AU/US/UK/SG/NZ). A minha equipa estΓ‘ focado no experiΓͺncia do utilizadors que precisa serviΓ§os

πŸ‘︎ 28
πŸ’¬︎
πŸ‘€︎ u/Tasty_Repair8695
πŸ“…︎ Jan 15 2022
🚨︎ report
Kotlin Server-side Survey

Hi server-siders! πŸ§‘πŸ½β€πŸ’»
We are looking at some new ways to make the Kotlin experience more convenient for server-side developers, but we need your input!
Answer just a few questions for a chance to win a prize 🎁
πŸ‘‡ πŸ‘‡ πŸ‘‡
https://surveys.jetbrains.com/s3/rd-kotlin-developers-survey

https://preview.redd.it/npfqmkwwegb81.png?width=800&format=png&auto=webp&s=42457f1c0276a1f6d0fc5992a8d1dec1ed691ef2

πŸ‘︎ 42
πŸ’¬︎
πŸ‘€︎ u/alinagrebenkina
πŸ“…︎ Jan 13 2022
🚨︎ report
Is there a function to calculate a Kotlin's object size in memory?

For context, I'm currently studying Android stuff and reading about savedInstanceState and Bundle, Android's documentation says I should limit the size of data I send to a Bundle to less than 50kb.

Now I know I probably won't exceed that and if I did by a small margin it's probably no biggie, but I still got curious about knowing my parcelized objects' sizes in memory. Curious how this is done in Kotlin.

πŸ‘︎ 26
πŸ’¬︎
πŸ‘€︎ u/ED9898A
πŸ“…︎ Jan 17 2022
🚨︎ report
lucilla: Fast, efficient, in-memory Full Text Search for Kotlin github.com/haroldadmin/lu…
πŸ‘︎ 33
πŸ’¬︎
πŸ‘€︎ u/theharolddev
πŸ“…︎ Jan 23 2022
🚨︎ report
Is kotlin viable for desktop development?

I want to learn how to make desktop apps. I tried wpf with c# but i hated it. Ive heard of compose and javafx but i dont know any java. Any advice?

πŸ‘︎ 29
πŸ’¬︎
πŸ“…︎ Jan 07 2022
🚨︎ report
Kimmer: Port immer for kotlin/jvm

Hi guys

I've created a framework: https://github.com/babyfish-ct/kimmer

It brings immer(http://github.com/immerjs/immer) to kotlin/jvm.

>Immer is the winner of the "Breakthrough of the year" React open source award and "Most impactful contribution" JavaScript open source award in 2019.
>
>It's simple and powerful, so I bring its design pattern for kotlin/jvm.

Create the next immutable state tree by simply modifying the current tree

https://preview.redd.it/53bvksdje3c81.png?width=1120&format=png&auto=webp&s=c0a969de47b257e288d560681fc49dc1b1921aff

the input "book" is old immutable object, the output "book2" is new immutable object, Both of them are immutable.

However, "this" of the lambda is mutable and it's draft object.

  1. Its API is generated by the pre-compiler of framework, you define the API of immutable data model, framework defines the API of mutable data automatically.
  2. It's proxy of immutable data. For root proxy, deeper proxies only need to created when user visit its deeper object. Each proxy only retains immutable object and does not copy any data until user changes the proxy. Finally, all the changed proxies are used to create new immutable.

That why it can Create the next immutable state tree by simply modifying the current tree.

Like the "fork" of linux, unchanged parts are always shared and reused.

πŸ‘︎ 18
πŸ’¬︎
πŸ‘€︎ u/babyfish-ct
πŸ“…︎ Jan 16 2022
🚨︎ report
Anyone used Spring Boot + Kotlin? I am thinking whether to refactor Spring Boot + Java into Spring Boot + Kotlin for my backend in production (about 100kloc). Do you suggest it?
πŸ‘︎ 22
πŸ’¬︎
πŸ‘€︎ u/fzyzcjy
πŸ“…︎ Dec 29 2021
🚨︎ report
Illustrate Kotlin Collection Functions (Partition; Windowed; Chunked)
πŸ‘︎ 97
πŸ’¬︎
πŸ‘€︎ u/ElyeProj
πŸ“…︎ Jan 11 2022
🚨︎ report
The 5 Java Concise Syntax I Miss in Kotlin elye-project.medium.com/t…
πŸ‘︎ 30
πŸ’¬︎
πŸ‘€︎ u/ElyeProj
πŸ“…︎ Dec 21 2021
🚨︎ report
I wrote a library that translates Kotlin data classes to JavaScript

https://github.com/Schinzel/js-transpiler
The library translates Kotlin data classes to ES6 JavaScript classes and Kotlin enums to JavaScript objects. It solves the problem of having the same classes server and client side.

For example, you have a data class in Kotlin that represents a person, with first and last name, age and so forth and you want to send this data to a client which is a browser. In JavaScript you could just work with JSON objects. But if you prefer having autocomplete, readily knowing which data is held and other benefits of a more strongly typed environment, then one solution is to write corresponding JavaScript classes. These JavaScript classes are very similar to their Kotlin counterparts, tedious to write, error prone programming because of its repetitive nature and bug prone as you often forget to update the JavaScript classes when the Kotlin classes changes.

At my company we really like the JavaScript "data" classes but really hated writing and maintaining them. So I wrote a library that automates this work. We have been using it for a couple of years and it is stable. It is one of the basic building blocks in the product of my company and is used many times a day to translate over a hundred classes. I find it very practical and also use it in hobby projects.

It has saved me (and my company) a lot of time, prevented a lot of errors and removed tedious programming. I post it here in case someone else might find it useful.

πŸ‘︎ 14
πŸ’¬︎
πŸ‘€︎ u/RedOctopuses
πŸ“…︎ Jan 17 2022
🚨︎ report
Kotlin Multiplatform Mobile performance on M1 Macbooks

Hey, I'm iOS developer and I have recently joined a project with KMM, the main gripe with it is that it takes at least 10 minutes in Xcode to rebuild project when switching git branches on 2020 i5 based Macbook. I know that new M1 Macbooks are like 2 to 3 times faster than Intel based ones for native apps build in swift, but I cannot find any benchmark confirming that is also a case for KMM (it should be possible to run it without Rosetta now, right?). Have any of you compared these compile times?

πŸ‘︎ 12
πŸ’¬︎
πŸ‘€︎ u/plakplak2
πŸ“…︎ Jan 16 2022
🚨︎ report
Java versus Kotlin - personal experiences youtu.be/iJq7sCiS8do
πŸ‘︎ 26
πŸ’¬︎
πŸ‘€︎ u/Pattadampa
πŸ“…︎ Dec 24 2021
🚨︎ report
A go-to GUI library for Kotlin

What is a go-to GUI toolkit for use with Kotlin? TornadoFX is almost abandoned, JavaFX seems to have a distribution problems on Linux (finding a correct openjdk can be challenging for an end user)...

If I want to build a cross-platform (Windows/Linux) GUI application, which library should I use?

πŸ‘︎ 25
πŸ’¬︎
πŸ‘€︎ u/StragaSevera
πŸ“…︎ Jan 05 2022
🚨︎ report
Kotlin for backend?

I've been using Express with Typescript and Gin Go for my server side applications, but I'm somewhat dissatisfied with both.

Typescript is awesome, and I've written a data class library to make the development smooth as butter, but it's not as lightweight as I hoped it would be and I keep having to fight the other devs on the team to stop using it like JavaScript (someVar as any every time the type doesn't match)

Go is okay-ish but I miss generics and null safety. From what I've heard, Kotlin is everything I'd want in a language -- the issue lies with the backend libraries. I've worked with Spring (in Java) and, quite honestly, disliked it -- as it was too abstract for me -- with all the decorators and such.

Ideally I would find something like Express for Kotlin, and Ktor seems to be promising, but I feel like the community seems to be quite small at the time, and a lot of the framework is still experimental.

Could somebody advise?

πŸ‘︎ 14
πŸ’¬︎
πŸ‘€︎ u/aesthetics-red
πŸ“…︎ Jan 08 2022
🚨︎ report
How would you describe kotlin?

I just started learning kotlin and i really like it so far but i have a question. How would you briefly describe kotlin to someone who knows js, python and a bit of c#?

πŸ‘︎ 11
πŸ’¬︎
πŸ“…︎ Jan 07 2022
🚨︎ report
Creating a type-safe WHERE clause DSL using Kotlin

In the process of working on my open source project that deals with SQL databases, I have inadvertently created a DSL for constructing a WHERE clause. It would not have been possible without Kotlin magic!

I think I have the public facing API the way I want it. However, I feel like there are some internal improvements that I can make. I want to get feedback on how I've done it and perhaps learn a different way of doing it. So, here it goes! I'll try my best to keep this post a pure as possible so we can focus on the topic at hand. With that in mind, I'll write this like an interview question =)

Problem

Given the following SQL database table of fruits,

id name color count
1 apple red 187
2 banana yellow 12
3 orange orange 6
4 pineapple yellow 3

where "id" (number), "name" (text), "color" (text), and "count" (number) are the columns, build a type-safe DSL for constructing WHERE clauses that can generate strings such as...

"((name LIKE '%a%') OR (color IN ('yellow', 'red'))) AND ((count > 10) OR (count < 5))"

The string must be evaluated lazily, only when the toString function is called.

Solution

Using what I built, the above WHERE string can be generated using the following code,

val where: Where<FruitField> = where {
    ((Name contains "a") or (Color `in` setOf("yellow","red"))) and (Count { greaterThan(10) or lessThan(5) })
}

Here is the simplified code that makes that work,

// Fields/column definitions --------------
sealed interface Field {
    val columnName: String
}

class FruitField(override val columnName: String) : Field

object FruitFields {
    val Id = FruitField("id")
    val Name = FruitField("name")
    val Color = FruitField("color")
    val Count = FruitField("count")
}

// Where binary tree structure -----------------
// The type [T] is not exactly "used" in this class itself. Rather, it is used for adding type
// restrictions when constructing instances at compile time.
class Where<out T : Field> private constructor(
    private val lhs: LeftHandSide,
    private val operator: Operator,
    private val rhs: RightHandSide,
) {

    // This provides us the base case when using recursion to traverse the binary tree.
    // This is a leaf node.
    internal constructor(lhs: FieldHolder, operator: Operator.M
... keep reading on reddit ➑

πŸ‘︎ 18
πŸ’¬︎
πŸ‘€︎ u/vestrel00
πŸ“…︎ Jan 02 2022
🚨︎ report
Do you use kotlin/js?

I would like to see how widespread kotlin/js is. Is it worth introducing into a mainstream project or not?

I am also interested in why people choose/like to use kotlin/js over react or angular+typescript (so comments are welcome).

Also do you use it together with React or something else?

Thanks

View Poll

πŸ‘︎ 20
πŸ’¬︎
πŸ‘€︎ u/a_kiraly
πŸ“…︎ Jan 04 2022
🚨︎ report
Paodin has the Channel Orca clone for MUCH cheaper than KOTLIN. Only 15 available each color reddit.com/gallery/rxnjc9
πŸ‘︎ 21
πŸ’¬︎
πŸ‘€︎ u/IZEAS
πŸ“…︎ Jan 06 2022
🚨︎ report
Kotlin/native: library for file io?

By default, Kotlin/native does not come with file based IO similar to java.io or java.nio, but allows C functions from the platform.posix.* package. Is there some open source library available for provide similar API like java.nio which internally uses, but hides the use of platform.posix from teh library user? Is Jetbrains planning to do something like that?

πŸ‘︎ 19
πŸ’¬︎
πŸ‘€︎ u/vmcrash
πŸ“…︎ Jan 14 2022
🚨︎ report
Kotlin volunteer projects

Hey, I am looking for projects that I can contribute to which if possible have positive impact on our society.

I guess I should be looking for open source projects?

Any hint or direction where/how I should be looking?

Thank you.

πŸ‘︎ 32
πŸ’¬︎
πŸ‘€︎ u/hunnihundert
πŸ“…︎ Jan 13 2022
🚨︎ report
Value Classes in Kotlin: Good-Bye, Type Aliases! πŸ‘‹ quickbirdstudios.com/blog…
πŸ‘︎ 99
πŸ’¬︎
πŸ‘€︎ u/lolollap
πŸ“…︎ Dec 13 2021
🚨︎ report
Alternatives to log4exploits? No Kotlin pls...
πŸ‘︎ 358
πŸ’¬︎
πŸ‘€︎ u/marco89nish
πŸ“…︎ Dec 10 2021
🚨︎ report
CS 124 ... JAVA OR KOTLIN?

Hey I'm new to CS and was wondering if someone can help out!

I don't wanna learn something so I get an easier grade, rather I wanna learn something that I can use in the future and stand out.

I know Java has been around for years but Kotlin is not Google's preferred android language

So, should I choose Kotlin or Java?

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/Mufasak
πŸ“…︎ Jan 18 2022
🚨︎ report
Katlib - a companion to standard Kotlin library

https://github.com/LukasForst/katlib

Allow me to introduce you to Katlib - collection of extension functions me and my colleges wrote for last five years of server side Kotlin development. It contains around 75 extensions or functions that we were missing in the Kotlin standard library during the time.

Fully opensourced, with test coverage between 60-70% and a no dependency.

πŸ‘︎ 19
πŸ’¬︎
πŸ‘€︎ u/Yatralalala
πŸ“…︎ Jan 08 2022
🚨︎ report
GitHub Actions Kotlin DSL

Ever wished for something better than YAML when authoring your workflows? Especially once your workflows get more complex, the power of a proper programming language may come in handy. That's why I'm giving this idea a try:

https://github.com/krzema12/github-actions-kotlin-dsl

The idea is simple: using Kotlin API, describe your workflows and have the library generate the YAML for you. To keep the two files (Kotlin source and output YAML) in sync, there's runtime consistency check in place.

Early adopters feedback greatly appreciated! Still far from ideal in terms of e. g. output YAML formatting, typing or action wrappers coverage, but IMO already can bring some benefits.

πŸ‘︎ 41
πŸ’¬︎
πŸ‘€︎ u/krzema12
πŸ“…︎ Jan 20 2022
🚨︎ report
JetBrains Toolbox Case Study: Moving 1M users to Kotlin & Compose Multiplatform blog.jetbrains.com/kotlin…
πŸ‘︎ 33
πŸ’¬︎
πŸ‘€︎ u/IsDaouda_Games
πŸ“…︎ Dec 23 2021
🚨︎ report
Kotlin Collection Functions (Scan, Reduce, Fold)
πŸ‘︎ 23
πŸ’¬︎
πŸ‘€︎ u/ElyeProj
πŸ“…︎ Jan 20 2022
🚨︎ report
I'm slightly surprised that Kotlin allows === equality checking for null

For reference: https://kotlinlang.org/docs/equality.html#structural-equality

There's no difference between == and === when comparing against null, anyway. So, it seems like === should be deprecated the same way that comparing "primitives" (Int, String, etc) and value/inline classes is.

I wonder if this is just vestigial or if there's some actual reason that the Kotlin designers don't want to deprecate the === equality syntax.

πŸ‘︎ 6
πŸ’¬︎
πŸ‘€︎ u/ragnese
πŸ“…︎ Dec 31 2021
🚨︎ report
It may just be the naming convention, but the whole Kotlin Native/Kotlin Multiplatform/Compose Multiplatform thing seems super confusing to me

I wanted to try it out to see what can I achieve with it but things seems super confusing to me, for now I'm just trying to make sense of all of this.

So first, there is Kotlin Native, which if I understand correctly allow to compile Kotlin code for native, not running inside the JVM, which seems insanely good, I've done a lot of C and C++ in the past but if I can just write Kotlin code and run it natively be sure I won't ever write C or C++ ever again.

Using IntelliJ, you can also create a Kotlin Multiplatform Library, which allow you to write a library in Kotlin, targeting the JVM (no Android?), js and native using Kotlin Native. Not sure how this work but why not, sound good to me.

But those are for libraries, to make an app you may want to have an UI for it, good news Compose Multiplatform reached 1.0 stable a few days ago. Wait this does not have anything to do with Kotlin Multiplatform?

Using IntelliJ, you can create a Compose Multiplatform Application running on JVM (Windows, Linux, MacOS) and Android, but no iOS, since it run on a java virtual machine. Sad, if it was running on iOS too I would just create all my apps using this framework, but for now the use cases are very limited.

You can also create a Compose Web Application, but no Multiplatform + Web application? Why not? I don't know.

Feel free to share your thoughts or correct me if I said something wrong. As I said I'm just trying to make sense of all of this in my head.

πŸ‘︎ 67
πŸ’¬︎
πŸ‘€︎ u/CrisalDroid
πŸ“…︎ Dec 14 2021
🚨︎ report
Python backend for Kotlin

We're working on a possibility of compiling Kotlin into Python, just like it's now possible for JVM, JS and native. Its now community-driven. Any help to push it forward greatly appreciated.

Recent progress update: https://discuss.kotlinlang.org/t/idea-python-backend/19852/13

Project's README: https://github.com/krzema12/kotlin-python/blob/python-backend/python/README.md

πŸ‘︎ 25
πŸ’¬︎
πŸ‘€︎ u/krzema12
πŸ“…︎ Dec 19 2021
🚨︎ report
I am considering cloning the Monero Core code into Kotlin native, any suggestions?

My main goals is to make the code shorter and easier to maintain, understand and read for a broader spectrum of people, which I think is the one of the goals of Monero in the first place.

I feel that C++ is not the most friendly language, and its benefits don't largely outweight its difficulties as of today in 2021.

Also, I believe I heard the other day that there is no other implementation of the Monero Core besides the official one.

What do you think?

EDIT:

Statistics regarding the official Core's codebase:

    4523 text files.
    4304 unique files.
    582 files ignored.

github.com/AlDanial/cloc v 1.74  T=185.29 s (21.4 files/s, 4941.9 lines/s)
---------------------------------------------------------------------------------------
Language                             files          blank        comment           code
---------------------------------------------------------------------------------------
C++                                    479          29891          29371         181484
Qt Linguist                             19             79              0         118934
C/C++ Header                           688          19737          40774         118560
JSON                                  1907             16              0         100353
C                                      264           7268          10145          73926
Markdown                               109          11884              0          37721
Assembly                                54          17574          45434          17725
Python                                  94           3762           4857          15298
CMake                                   99           1100           2654           5829
Bourne Shell                            61            429            828           4975
make                                    74            714            357           3097
MSBuild script                          13              0              0           2189
Protocol Buffers                        19            289           1259           1867
YAML                                    19            137            116           1277
m4                                       4             68             49            534
XML                                      8             11              7            390
Kotlin                                  12             97           
... keep reading on reddit ➑

πŸ‘︎ 29
πŸ’¬︎
πŸ‘€︎ u/Creme-Exciting
πŸ“…︎ Nov 25 2021
🚨︎ report
I wish a very peaceful weekend for all the Java, Scala, Kotlin, Clojure engineers!
πŸ‘︎ 177
πŸ’¬︎
πŸ‘€︎ u/antigravity_96
πŸ“…︎ Dec 17 2021
🚨︎ report
Kotlin equivalent for static methods as callbacks

I have a question regarding how to deal with callbacks in Kotlin. A bit of context - I am using LWJGL and typically (say in a Java context), you would setup callbacks for keyboard / mouse events by providing a static method to one of the glfw functions.

glfwSetKeyCallback(windowPtr, KeyListener::keyCallback);

This does not appear to be possible in Kotlin. So what is an equivalent? I would like to encapsulate the code in a separate class - because the callbacks can be reasonably complex.

Thanks!

πŸ‘︎ 5
πŸ’¬︎
πŸ‘€︎ u/FoniksMunkee
πŸ“…︎ Jan 12 2022
🚨︎ report
A naive question about Kotlin Android

Just started learning Kotlin a moment ago, and I really need some help!

In the main(first) window, I want it to show a number, and this number should increase one per second automatically, and when I jump to another window, this number should still keep increasing. I stuck this question about two days, though just wanted to practice textview at first

thanks anyway

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/InsideBreeze0
πŸ“…︎ Jan 21 2022
🚨︎ report
Blind guy here. been learning Java/Kotlin/Python for a while, but I have no idea how to actually use this skills with things like android studio or an IDE to make a basic application.

Hi everyone, I am a 28 year old IT student who is graduating soon. I've been personally learning how to code in python, java, and kotlin for a few years or so, but none of these skills really work outside of the IDE. I am LEGALLY blind but not totally blind, so reading is hard but not impossible for reference.

So, for example, I LOVE dnd but cant see my dice when i roll them and the apps out there kind of suck for my purposes. I wanted to develop a VERY basic android studio Android app that uses "rand" to generate given numbers and assign them to different images based on their results, probably with an elif loop or something. Cool, my code works, it accepts input from the user using a listener for input. Now how do I turn *this* into a basic application? I watched a million tutorials on android studio, but they all seem to be outdated or just poorly written/recorded.

Please help guide me here guys. Thank you

πŸ‘︎ 287
πŸ’¬︎
πŸ‘€︎ u/TheBoredMimic
πŸ“…︎ Nov 27 2021
🚨︎ report
Any notable Twitter accounts about Kotlin?

Looking for accounts who post only about Kotlin, like language features, snippets, tips, gotchas, libraries etc.

πŸ‘︎ 19
πŸ’¬︎
πŸ‘€︎ u/djipdjip
πŸ“…︎ Jan 15 2022
🚨︎ report
Handling the unexpected in Kotlin with Monads cortex.io/post/how-we-exp…
πŸ‘︎ 26
πŸ’¬︎
πŸ‘€︎ u/gsdatta
πŸ“…︎ Jan 21 2022
🚨︎ report
Java v Kotlin: Dawn of Nullity v.redd.it/za22bqbcyj681
πŸ‘︎ 49
πŸ’¬︎
πŸ“…︎ Dec 19 2021
🚨︎ report
Is it worth rewriting large Java project into Kotlin?

I am working on a web app with backend in Java. The project information are:

  • ~2000 java files
  • almost 200k lines of code (excluding empty lines)
  • multimodule maven project and few microservices
  • currently using Java 11, Spring Boot, Hibernate

It was decided that current code should migrate to Kotlin over time, I am trying to get an opinion on this, but from what I learned so far I think it's not worth the effort to go through migration of this scale. The project has a lot of code and design issues itself, developers (4 total) don't have a lot of experience with Kotlin, some none at all.

My questions are:

  • Do you think the migration effort would be worth it?
  • What would be the biggest advantage of having whole code base in Kotlin?
  • What would be the biggest disadvantage of the migration?
πŸ‘︎ 11
πŸ’¬︎
πŸ‘€︎ u/ThreeDots3
πŸ“…︎ Jan 24 2022
🚨︎ report
Is it worth rewriting large Java project into Kotlin?

I am working on a web app with backend in Java. The project information are:

  • ~2000 java files
  • almost 200k lines of code (excluding empty lines)
  • multimodule maven project and few microservices
  • currently using Java 11, Spring Boot, Hibernate

It was decided that current code should migrate to Kotlin over time, I am trying to get an opinion on this, but from what I learned so far I think it's not worth the effort to go through migration of this scale. The project has a lot of code and design issues itself, developers (4 total) don't have a lot of experience with Kotlin, some none at all.

My questions are:

  • Do you think the migration effort would be worth it?
  • What would be the biggest advantage of having whole code base in Kotlin?
  • What would be the biggest disadvantage of the migration?
πŸ‘︎ 6
πŸ’¬︎
πŸ‘€︎ u/ThreeDots3
πŸ“…︎ Jan 24 2022
🚨︎ report

Please note that this site uses cookies to personalise content and adverts, to provide social media features, and to analyse web traffic. Click here for more information.