Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Kotlin 1.5 preview
Search
Panini
February 17, 2021
Programming
480
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Kotlin 1.5 preview
Panini
February 17, 2021
More Decks by Panini
See All by Panini
Java谷園から逃げ出した話
panini
0
410
Kotlin 1.4-rc
panini
0
250
Fixing Broken Robots - Android Mutation Testing
panini
0
220
Kotlin Multiplatform
panini
2
700
build.gradle.kts
panini
2
2.5k
Kotlin Multi-platform(?)
panini
1
780
Convert Java file to Kotlin file ⌥⇧⌘K
panini
0
1.2k
Introducing Android P
panini
2
880
Display Cutout
panini
1
680
Other Decks in Programming
See All in Programming
自作OSでスライド発表する
uyuki234
1
3.8k
Snowflake Summitでの新機能 CoCo / CoWork / snowflake-summit-2026-overall-what-new-coco
tatsuhiro
1
230
1年で人数1.5倍、PR数5.5倍増。 品質とアウトカムはどうなったか、 何が効いたか
ike002jp
0
130
ルールを書いて終わらせないハーネスエンジニアリング
yug1224
2
1.5k
任せる範囲はこう広がった / How the Scope of AI Delegation Has Expanded
nrslib
1
260
Prismを使った型安全な暗号化_関数型まつり2026
_fhhmm
0
130
琵琶湖の水は止められてもNet--HTTPのリトライは止められない / You might be able to stop the water flow of Lake Biwa but you can't stop Net::HTTP retries
luccafort
PRO
0
380
【やさしく解説 設計編 #0】DDDのコード、読めるのに分からない人へ
panda728
PRO
2
270
フィードバックで育てるAI開発
kotaminato
1
120
Haskell/Servantを通してWebミドルウェアを捉え直す
pizzacat83
1
580
Creating Composable Callables in Contemporary C++
rollbear
0
210
ビデオ通話が繋がる0.2秒で何が起きているのか
supurazako
2
150
Featured
See All Featured
Leo the Paperboy
mayatellez
8
1.9k
Collaborative Software Design: How to facilitate domain modelling decisions
baasie
1
260
Building AI with AI
inesmontani
PRO
1
1.1k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
10
1.3k
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
1
800
HDC tutorial
michielstock
2
740
Ten Tips & Tricks for a 🌱 transition
stuffmc
0
150
Breaking role norms: Why Content Design is so much more than writing copy - Taylor Woolridge
uxyall
0
340
Tips & Tricks on How to Get Your First Job In Tech
honzajavorek
1
590
Build your cross-platform service in a week with App Engine
jlugia
234
18k
GraphQLとの向き合い方2022年版
quramy
50
15k
Transcript
Kotlin 1.5 preview Kotlin愛好会 vol.27
About Me • Matthew Vern / Panini • Twitter: @panini_ja
Github: panpanini • Mercari, Inc • Android Engineer (US) • Kotlin可愛い
Summary • Sealed Class improvements • Sealed Interface • Reference:
https://zsmb.co/sealed-goodies-coming-in-kotlin-1-5/
Sealed Class improvements
Kotlin ~1.4 Sealed Class • https://kotlinlang.org/docs/sealed-classes.html • Enum with super
power • Can be defined either nested, or in the same file • https://qiita.com/kikuchy/items/ad89a12029082be8d218
Kotlin ~1.4 Sealed Class
Kotlin ~1.4 Sealed Class
Kotlin ~1.4 Sealed Class
Kotlin 1.5+ Sealed Class • https://kotlinlang.org/docs/sealed-classes.html • Can be defined
anywhere in the same package, and same module
Sealed Interface
Kotlin 1.5+ Sealed Interface • https://kotlinlang.org/docs/sealed-classes.html#sealed-interfaces • Implementations must be
declared in same package and same module • Can restrict implementers to inside a single module ◦ Useful for hiding implementation details • YouTrack: https://youtrack.jetbrains.com/issue/KT-22286
Summary • Sealed Class is like super enum • Sealed
Interface is like package private Interface • Kotlin 1.5 looks good!
Have a nice Kotlin!