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
"It shared" in Kotlin
Search
Keishin Yokomaku
April 15, 2016
Technology
0
40
"It shared" in Kotlin
Keishin Yokomaku
April 15, 2016
Tweet
Share
More Decks by Keishin Yokomaku
See All by Keishin Yokomaku
Base64 in Android
keithyokoma
0
18
One screen, many BottomSheets
keithyokoma
0
390
LazyColumnのitemがViewPortの中で占める領域の割合を知りたい
keithyokoma
0
660
Build apps for Cars
keithyokoma
0
530
Save the state
keithyokoma
0
570
Either in Kotlin
keithyokoma
0
590
持続的なアプリ開発のためのDXを支える技術
keithyokoma
2
5.2k
Make the objects serializable with kotlinx.serialization
keithyokoma
0
5.1k
Kotlin で書く Gradle Custom Tasks
keithyokoma
0
550
Other Decks in Technology
See All in Technology
Webアクセシビリティ入門
recruitengineers
PRO
1
370
会社にデータエンジニアがいることでできるようになること
10xinc
9
1.6k
自社製CMSからmicroCMSへのリプレースがプロダクトグロースを加速させた話
nextbeatdev
0
150
生成AI利用プログラミング:誰でもプログラムが書けると 世の中どうなる?/opencampus202508
okana2ki
0
190
実践アプリケーション設計 ③ドメイン駆動設計
recruitengineers
PRO
3
320
あなたの知らない OneDrive
murachiakira
0
240
【5分でわかる】セーフィー エンジニア向け会社紹介
safie_recruit
0
30k
Figma + Storybook + PlaywrightのMCPを使ったフロントエンド開発
yug1224
9
2.9k
Claude Code x Androidアプリ 開発
kgmyshin
1
600
ソフトウェア エンジニアとしての 姿勢と心構え
recruitengineers
PRO
4
1.4k
認知戦の理解と、市民としての対抗策
hogehuga
0
370
サービスロボット最前線:ugoが挑むPhysical AI活用
kmatsuiugo
0
200
Featured
See All Featured
Git: the NoSQL Database
bkeepers
PRO
431
65k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
Bootstrapping a Software Product
garrettdimon
PRO
307
110k
Site-Speed That Sticks
csswizardry
10
790
How To Stay Up To Date on Web Technology
chriscoyier
790
250k
Mobile First: as difficult as doing things right
swwweet
223
9.9k
Measuring & Analyzing Core Web Vitals
bluesmoon
9
570
Making Projects Easy
brettharned
117
6.3k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
185
54k
Fireside Chat
paigeccino
39
3.6k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
How STYLIGHT went responsive
nonsquared
100
5.7k
Transcript
IT SHARED IN KOTLIN KEISHIN YOKOMAKU
ςΩετ KOTLIN ▸ JetBrains ͕։ൃͨ͠ JVM Ͱಈ͘ݴޠ ▸ Ϟμϯͳจ๏ΛऔΓೖΕͨ Better
Java ͳݴޠ ▸ 1.0.0 ͕͍ͭ࠷ۙϦϦʔε͞Εͨ
ςΩετ MODERN SYNTAX IN KOTLIN ▸ Ϧετͷૢ࡞ ▸ filter, map,
let ͳͲศརͳϝιου͕͋Δ ▸ Java8 ͷ Stream API Έ͍ͨͳͷ͕ඪ४ࡌ fun main(args: Array<String>) { listOf(1, 2, 3) .filter {n -> n < 3} .let {n -> print(n)} } => [1, 2]
ςΩετ MODERN SYNTAX IN KOTLIN ▸ σʔλΫϥε ▸ ϓϩύςΟΛอ࣋͢ΔΫϥε(=Entity)༻ͷಛผͳએݴ ▸
Getter/Setter equals/hashCodeɺtoString ΛΑ͠ͳʹ ͬͯ͘ΕΔͷͰࣗͰॻ͔ͳ͍͍ͯ͘ data class Person(val name: String, val age: Int) val eq = Person(“Hirata”, 29) .equals(Person(“Jita”, 30)) print(eq) => false
ςΩετ KEYWORD ▸ it ▸ 1 ͭͷҾΛ࣋ͭϒϩοΫͷҾΛ it ͰࢀরͰ͖Δ fun
main(args: Array<String>) { listOf(1, 2, 3) .filter {n -> n < 3} .let {n -> print(n)} }
ςΩετ KEYWORD ▸ it ▸ 1 ͭͷҾΛ࣋ͭϒϩοΫͷҾΛ it ͰࢀরͰ͖Δ fun
main(args: Array<String>) { listOf(1, 2, 3) .filter {it < 3} .let {print(it)} }
ςΩετ data class Article (val name: String, val shared: Boolean);
ςΩετ data class Article (val name: String, val shared: Boolean);
fun main(args: Array<String>) { listOf(Article(“Think Social?”, true), Article(“Facebook”, true), Article(“mixi”, false)) .filter {it.shared} .let {print(it)} }
ςΩετ data class Article (val name: String, val shared: Boolean);
fun main(args: Array<String>) { listOf(Article(“Think Social?”, true), Article(“Facebook”, true), Article(“mixi”, false)) .filter {it.shared} .let {print(it)} } => [Article(name=“Think Social?”, shared=true), Article(name=“Facebook”, shared=true)]
IT SHARED