27 Matching Annotations
  1. Apr 2023
    1. construir apps com código parcialmente em Java eparcialmente em Kotlin, sem restrições.

      Kotlin é uma linguagem de programação usada para desenvolvimento Android que possui um alto grau de compatibilidade com Java. Isso permite que os desenvolvedores criem aplicativos Android com código parcialmente em Java e parcialmente em Kotlin, sem restrições. Além disso, Kotlin oferece recursos adicionais em relação ao Java, tornando o código mais limpo, seguro e fácil de ler e escrever.

      A compatibilidade com Java permite aos desenvolvedores usar Kotlin em novos projetos ou migrar gradualmente seus aplicativos existentes para a linguagem, *sem ter que reescrever todo o código de uma vez. *

  2. Dec 2022
  3. Aug 2022
    1. Function<*, String> means Function<in Nothing, String>.Function<Int, *> means Function<Int, out Any?>.Function<*, *> means Function<in Nothing, out Any?>.


    1. 任何类型,当它被“?”修饰,变成可空类型以后,它就变成原本类型的父类了。所以,从某种程度上讲,我们可以认为“Any?”是所有 Kotlin 类型的根类型
    2. 还有助于我们实现函数类型


    1. val parameterAnnotations = method.parameterAnnotations for (i in parameterAnnotations.indices) { for (parameterAnnotation in parameterAnnotations[i]) { // ② if (parameterAnnotation is Field) { val key = parameterAnnotation.value val value = args[i].toString() if (!url.contains("?")) { // ③ url += "?$key=$value" } else { // ④ url += "&$key=$value" } } }


  4. Jul 2022
  5. Dec 2021
  6. Apr 2021
    1. Preferences DataStore and Proto DataStore DataStore provides two different implementations: Preferences DataStore and Proto DataStore. Preferences DataStore stores and accesses data using keys. This implementation does not require a predefined schema, and it does not provide type safety. Proto DataStore stores data as instances of a custom data type. This implementation requires you to define a schema using protocol buffers, but it provides type safety.

      Currently, I am using SharedPreference which is still alright to use. However, there is a better option called DataStore. This allows data to be stored asynchronously.

    1. Google developed Dart to deliver optimized client apps and ease the development process. It came into the world nine years back. Since then, it has successfully manifested the reputation of being an ahead-of-its-time technology. This has enabled many visionaries to provide the world with apps that deliver an experience like never before. We'll talk about apps developed with Dart in the later part of the blog.

      The technology world is an ever-growing and expanding one, which today has many segments of its own. From that, app development is a highly evolving one. Dart Vs. Kotlin is the prime example of this.

  7. Mar 2021
    1. In this post, we will know the differences between Flutter and Kotlin by considering multiple parameters. Before comparison, we must have an understanding of these technologies.
  8. Feb 2021
    1. Recently, cross-platform apps have gained more popularity and preference for their native-like experience and low-cost development. As a result, Flutter Vs. Kotlin has become a famous debate.

      Flutter & Kotlin are cross-platform SDKs that allow you to create native-like mobile applications with only one codebase. In simple words, by single coding, you can have an app for iOS and Android.

  9. May 2020
    1. Programming languages These will probably expose my ignorance pretty nicely.

      When to use different programming languages (advice from an Amazon employee):

      • Java - enterprise applications
      • C# - Microsoft's spin on Java (useful in the Microsoft's ecosystem)
      • Ruby - when speed is more important then legibility or debugging
      • Python - same as Ruby but also for ML/AI (don't forget to use type hinting to make life a little saner)
      • Go/Rust - fresh web service where latency and performance were more important than community/library support
      • Haskell/Erlang - for very elegant/mathematical functional approach without a lot of business logic
      • Clojure - in situation when you love Lisp (?)
      • Kotlin/Scala - languages compiling to JVM bytecode (preferable over Clojure). Kotlin works with Java and has great IntelliJ support
      • C - classes of applications (operating systems, language design, low-level programming and hardware)
      • C++ - robotics, video games and high frequency trading where the performance gains from no garbage collection make it preferable to Java
      • PHP/Hack - testing server changes without rebuilding. PHP is banned at Amazon due to security reasons, but its successor, Hack, runs a lot of Facebook and Slack's backends
  10. Apr 2020
    1. They are both trying to extract common parts above platform, but Kotlin Multiplatform is interested in logic extraction when Flutter is interested in view definitions extraction. They concentrate on the opposite, and they might highly benefit from working together
  11. Nov 2019
  12. Oct 2019
  13. Sep 2017
    1. If you mark a declaration private, it will only be visible inside the file containing the declaration;
  14. Aug 2017
    1. if you work in multi-threaded environment or otherwise share mutable state between coroutines running in different threads, then you have to use thread-safe (concurrent) data structures.
  15. Jul 2017
  16. Jun 2017