Course
Overview
Do you already know Kotlin and use it every day? It's time to go further and explore what lies beneath the surface of the language.
Generics and variance, contexts and receivers, contracts, inline functions and reified types, delegation, conventions: these advanced concepts make the difference between code that merely works and code that is idiomatic, safe, and expressive.
This course dives into the advanced mechanisms of the language and its compiler. You will learn to take advantage of the official compiler plugins, to design and evolve high-quality public APIs, and to practice metaprogramming: reflection, introspection through serialization, and code generation with KotlinPoet and KSP.
By the end of these three days, you will master Kotlin's most powerful tools and know how to put them to work in robust, maintainable, and scalable libraries and applications.
Program
Objectives
Master advanced generics: variance, multiple constraints, and type erasure.
Extend the language with contexts, receivers, delegation, and value semantics.
Leverage the compiler: contracts, inline functions, reified types, and official plugins.
Make the most of the standard library: conventions, delegates, destructuring, sequences, and unsigned types.
Design, document, validate, and evolve high-quality public APIs.
Practice metaprogramming: reflection, serialization, and code generation with KotlinPoet and KSP.
Prerequisites
Solid command of the Kotlin language and some hands-on development experience with Kotlin, or having completed the “The Kotlin Language: Concepts & Tools” course.
Program
D1
Advanced concepts
Morning
Type erasure
understand the consequences
Generic variance
covariance, contravariance, and multiple constraints
Contexts & receivers
extend the language
Interface delegation
compose modules
Afternoon
Value semantics
the future of immutability
Companion blocks
extend existing types
Contracts
give guarantees to the compiler
Inline functions
non-local returns
D2
Compiler & standard library
Morning
Reified types
access the type at runtime
Official compiler plugins
know them and apply them
Kotlin conventions
understand the convention pattern
Property delegates
delegate the creation of delegates
Afternoon
Destructuring
by name or by position
Sequences
lazy operations on collections
Unsigned types
UInt, ULong & co
Dokka
document your code
D3
API quality & metaprogramming
Morning
Explicit API
control what you expose
Visibility & Opt-in
manage access and encapsulation
API validation
control exposure and changes
API migration
continuously evolve an API
Afternoon
JVM reflection
simple introspection with the Java API
Kotlin reflection
enriched information with the Kotlin layer
Serialization plugin
runtime introspection
KotlinPoet
generate Kotlin code at compile time
KSP
create annotation processors and code generators
Details
- Format
In-company
- Duration
3 days (21 hrs)
- Audience
Kotlin developers
- Level
Expert
These trainings might interest you
Our workshops are designed for professionals. Each program is tailored to your team's level and context, whether in-house or as an open session.
Kotlin Multiplatform: Mobile
Share your business logic between Android and iOS without sacrificing the native experience: master the Kotlin Multiplatform toolchain and Swift interoperability to design, distribute, and integrate a robust shared SDK that accelerates your teams.
The Kotlin Language: Concepts & Tools
Discover how Kotlin lets you write less code with fewer errors: its key concepts and tools will quickly make you productive at building safe, readable, and maintainable applications.
Compose: Interfaces in All Their Forms
Embrace declarative thinking to build reactive, maintainable, and performant interfaces. Master state and data flow to share a single UI codebase across Android, iOS, Desktop, and Web.
Kotlin Coroutines: Expert Usage
Go beyond everyday coroutine usage: understand their inner mechanisms, from language primitives to flows, to write reliable, performant, and testable asynchronous code, and choose the right tool for each problem.
Koog: Integrating AI into Your Multiplatform Apps
Go beyond the simple LLM call: use Koog to design AI agents integrated into your Kotlin applications, capable of acting and orchestrating themselves, reliable, cost-efficient, and observable in production.
Gradle: Master & Optimize Your Builds
Finally understand what happens in your Gradle builds to make them reliable, fast, and maintainable: factor out your configuration, automate your specific needs, and save precious time on every build.