Logo video2dn
  • Сохранить видео с ютуба
  • Категории
    • Музыка
    • Кино и Анимация
    • Автомобили
    • Животные
    • Спорт
    • Путешествия
    • Игры
    • Люди и Блоги
    • Юмор
    • Развлечения
    • Новости и Политика
    • Howto и Стиль
    • Diy своими руками
    • Образование
    • Наука и Технологии
    • Некоммерческие Организации
  • О сайте

Скачать или смотреть Kotlin Data Classes - Lenses and AI Assistant

  • Pairing with Duncan
  • 2023-12-01
  • 883
Kotlin Data Classes  - Lenses and AI Assistant
  • ok logo

Скачать Kotlin Data Classes - Lenses and AI Assistant бесплатно в качестве 4к (2к / 1080p)

У нас вы можете скачать бесплатно Kotlin Data Classes - Lenses and AI Assistant или посмотреть видео с ютуба в максимальном доступном качестве.

Для скачивания выберите вариант из формы ниже:

  • Информация по загрузке:

Cкачать музыку Kotlin Data Classes - Lenses and AI Assistant бесплатно в формате MP3:

Если иконки загрузки не отобразились, ПОЖАЛУЙСТА, НАЖМИТЕ ЗДЕСЬ или обновите страницу
Если у вас возникли трудности с загрузкой, пожалуйста, свяжитесь с нами по контактам, указанным в нижней части страницы.
Спасибо за использование сервиса video2dn.com

Описание к видео Kotlin Data Classes - Lenses and AI Assistant

There seems to be a lot of interest in data-oriented programming, which is good, because I have a lot to say!

As well as the maps and lists that are the staples of this style, Kotlin has data classes. These allow us to impose strong types on our data, at the expense of having strong types on our data.

To look at the pros and cons, this week we’ll reimplement our data analysis code with data classes. We’ll find that immutable data classes are excellent for extracting data, but really not so good for modifying it. This leads into lenses, which represent a particular part of structured data and allow us to inject and extract just that part.

Oh, and on the way, we’ll find that AI Assistant is frighteningly good at implementing data classes from JSON examples.

In this episode

00:01:02 Recap - parsing Google Places JSON
00:01:58 Gradually typed data
00:02:49 Strong typing with data classes
00:03:20 Create a test
00:03:50 We need a Place type, look at the docs for the api
00:04:34 http4k Toolbox...
00:04:52 ...doesn't cope with repeated data well
00:06:14 AI Assistant can't cope with lots of data either
00:07:22 Very impressive results for smaller input
00:08:46 Augment generated types with extensions
00:10:28 Generated classes only reflect the data that was there
00:12:20 Our sample data doesn't show when things are optional
00:12:56 This requires manual fixup
00:14:14 Data classes vs Maps when reading
00:14:49 Data classes vs Maps when extracting data
00:16:30 Updating data in immutable data classes
00:17:36 Extension functions for injecting in Data classes
00:19:40 IntelliJ rename bug
00:20:16 We don't have symbolic access to a particular copy invocation
00:20:41 Introducing Lenses
00:22:52 Is it too late to test?
00:23:27 Combine the getter and injector into a single object
00:24:53 IntelliJ Inline bug
00:25:37 We have a bidirectional lens, let's generalise
00:26:15 IntelliJ error
00:29:20 Using the lens to implement update
00:31:09 Our data class lenses have to be hand-coded

You can see a playlist of Data Oriented Programming    • Data Oriented Programming  

If you like this, you’ll probably like my book Java to Kotlin, A Refactoring Guidebook (http://java-to-kotlin.dev). It's about far more than just the syntax differences between the languages - it shows how to upgrade your thinking to a more functional style.

Комментарии

Информация по комментариям в разработке

Похожие видео

  • О нас
  • Контакты
  • Отказ от ответственности - Disclaimer
  • Условия использования сайта - TOS
  • Политика конфиденциальности

video2dn Copyright © 2023 - 2025

Контакты для правообладателей [email protected]