LIVE Instructor-Led Courses
Dismiss

Kotlin Best Practices training course

Gain highly effective skills for developing in Kotlin for Android, and Java Backends

JBI training course London UK

"Lots of useful examples in the presentation slides that was followed up with excellent exercises. My knowledge of Kotlin has been vastly improved by focusing on the best practices in this course and the class design section of the course has made my job far simpler."

NS, Senior Software Engineer, Kotlin Best Practices, May 2021

TAILOR-MADE
Enquire & get a quote
PUBLIC COURSES
Next on 4 Jul - see prices
JBI training course London UK

  • Learn Efficient collection processing
  • Use and learn Best practices
  • Advanced generics, design Kotlin and Java
  • Designing Kotlin for usage from Java
  • Designing Java for usage from Kotlin
  • Learn Concurrence
  • DSL definition - DSL definition in Kotlin
  • Use Functional programming in Kotlin
  • Safety:

    • Limit mutability
    • Eliminate platform types as soon as possible
    • Do not expose inferred types
    • Prefer composition over inheritance
    • Make it clear that top-level functions are not member functions
       
  • Readability:

    • Design for readability
    • Use operator overloading methods as their names indicate
    • Consider naming arguments
    • Avoid returning or operating on Unit?
    • Specify variable type when it is not clear
    • Consider referencing receiver explicitly
       
  • Reusability

    • Do not repeat knowledge
    • Do not repeat common algorithms
    • Reuse between different platforms by extracting common modules

     

  • Abstraction design

    • Each function should be written in terms of a single level of abstraction
    • Define abstractions
    • Respect abstraction contract
    • Restrict visibility
    • Use abstraction to protect code against changes
    • Consider wrapping external API
       
  • Objects creation

    • Consider factory functions instead of constructors
    • Consider primary constructor with named optional arguments
    • Consider defining DSL for complex object creation
  • Class design

    • Use data modifier to represent a bundle of data
    • Use function types instead of interfaces to pass operations and actions
    • Do not use properties to express behavior
    • Respect contract of equals
    • Respect contract of hashCode
    • Respect contract of compareTo
    • Respect contract of arithmetic operators
  •  

    Make it cheap

    • Avoid unnecessary object creation
    • Consider inline modifier for higher-order functions
    • Eliminate obsolete object references
    • Use tail recursion to achieve efficient recurrence
    • Efficient collection processing
    • Prefer Sequence for bigger collections with more than one processing step
    • Consider Arrays with primitives for performance critical processing
    • Consider using mutable collections
 

 

JBI training course London UK

Seasoned Kotlin Developers looking to get more out of their Kotlin code to help develop commercial applications on Google's Android platform or Backend Applications with Kotlin

4.8 out of 5 average

"Lots of useful examples in the presentation slides that was followed up with excellent exercises. My knowledge of Kotlin has been vastly improved by focusing on the best practices in this course and the class design section of the course has made my job far simpler."

NS, Senior Software Engineer, Kotlin Best Practices, May 2021

JBI training course London UK
 
Top 20 "Pain Points" for Data Analysts
 

Problem 11 : You have a very complex Excel spreadsheet and you want to reproduce EXACTLY the same spreadsheet in Power BI
Solution: Power BI is not Excel, it works differently and it has different strengths. In order to tackle this issue the best way is going back to the source and try to...

All 20 points are in our latest Newsletter - Delivered directly to your inbox



CONTACT
+44 (0)20 8446 7555

enquiries@jbinternational.co.uk

SHARE

Corporate Policies     Terms & Conditions
JB International Training Ltd  -  Company number 08458005

Registered address Wohl Enterprise Hub 2B Redbourne Avenue London N3 2BS

POPULAR

Rust training course                                                                          React training course

Threat modelling training course   Python for data analysts training course

Power BI training course                                   Machine Learning training course

Spring Boot Microservices training course              Terraform training course

Kubernetes training course                                                            C++ training course

Power Automate training course                               Clean Code training course