Mikrobuzzz
Стаж: 17 лет 6 месяцев
Сообщений: 334
Mikrobuzzz ·
17-Фев-19 15:27
(6 лет 5 месяцев назад, ред. 10-Июн-21 01:22)
Elements Of Kotlin 1.0 Год издания : 2021
Автор : Mark L. Murphy
Жанр или тематика : Программирование
Издательство : CommonsWare
ISBN : Отсутствует
Язык : Английский
Формат : PDF, EPUB, MOBI
Качество : Издательский макет или текст (eBook)
Интерактивное оглавление : Да
Количество страниц : 418
Описание :
The programming language for the first generation of Android app development was Java.
The programming language that will dominate the second generation of Android app development will be Kotlin.
Kotlin is a powerful language, designed to be concise yet expressive, both for application code and for libraries. However, some of that comes at a cost, as Kotlin has a lot more keywords and specialty features than does Java. A lot of that complexity is only needed by intermediate to advanced Kotlin developers, though.
This introductory book to Kotlin focuses on helping existing programmers get up to speed on reading and writing Kotlin code. Particular emphasis is placed on the sorts of syntax and language capabilities that most Kotlin developers will need, with light coverage of the advanced capabilities that allow library developers to create easy-to-use APIs.
Right now, this book is in a very early "beta" state, but it covers most of basics of Kotlin programming. It should reach Version 1.0 in the first half of 2019, with more complete coverage.
Оглавление
Preface
Prerequisites
About the Updates
What’s New in Version 1.0?
Warescription
Book Bug Bounty
Source Code and Its License
Creative Commons and the Four-to-Free (42F) Guarantee
Acknowledgments
Introducing Kotlin
Why?
…And Why Not?
What You Need to Know
Look At All the Kotlins!
Getting Kotlin, Normally
Introducing the Klassbook
How This Book is Structured
A Few “Hello, World!” Examples
Just the Statement
Wrapped in a Function
Wrapped in a Class
So, What Does This Do?
Using the Klassbook
Running These Snippets in an IDE
Basic Types and Expressions
Basic Types and “Objectness”
Numbers
Boolean
Strings
Characters
A Quick Note About Equality
Variables… Whether They Vary or Not
Declaring Variables
Declaring Read-Only Variables
Prefer val Over var
String Interpolation
More Operators
No Automatic Number Conversions
Hey, What About ?
Functions
Functions with Parameters
Functions with Return Types
Local Variables
Fancier Functions
Collections and Lambdas
Major Collection Types and Creation Functions
Basic Usage
Immutability and Collections
Introducing Lambda Expressions
Common Collection Operations
Varargs
Other JVM Collections
get() and [] Syntax
If, When, and While
If
When
While
If/When As Expressions
Bustin’ Out
Basic Classes
Basic Classes
Creating Instances of Classes
Packages
Common Contents
this
Constructors
Inheritance
Comments and Documentation
Basic Comment Syntax
Introducing KDoc
Properties
Initialization
Constants
Getting Down in the Weeds
Visibility and Scope
Visibility
Scope
Abstract Classes and Interfaces
The Objective: Contracts
Abstract Classes
Interfaces
Which Do You Use?
Data Class
How You Declare It
What You Gain
What You Lose
Data Classes with Other Properties
The object Keyword
Singletons
Companion Objects
Nested Objects
Object Expressions
Nested Objects and Classes
Nested Objects
Nested Classes
Nested Interfaces and Abstract Classes
Enums and Sealed Classes
Enums
Sealed Classes
Generics
OK, What Are These For Again?
Instantiation with Generics
Applying Generics to Classes and Interfaces
Upper Bounds
Generics, WTF?
Exceptions
Catching Exceptions
Raising Exceptions
Defining Exceptions
Checked vs. Unchecked Exceptions
Annotations
Where Annotations Come From
Applying Annotations
Defining Annotations
Nullability
Introducing Nullable Types
Expressions with Nullable Types
Nullable Types and Generics
Nullable Types and Casts
Objective: Minimize Nulls
Scope Functions
let()
apply()
run()
with()
also()
use()
Summary
Functional Programming
Your App Might Not Be Functional
Where Immutability Comes Into Play
Examples of Functional Kotlin
Function Types
Arrays, Collections,… And Sequences
Extension Functions
The Case of the Utility Function
Monkeying Around
Declaring Extension Functions
Calling Extension Functions
The Limitations
Java Interoperability
Recap of Interoperability
Kotlin Calling Java
Java Calling Kotlin
Decompiling Kotlin to Java
Changes in Newer Kotlin Versions
Version 1.3
Version 1.4
Custom Accessors
Defining Custom Accessors
Anti-Patterns
Alternative: Delegates
Extension Properties
Recapping Extension Functions
Recapping Property Custom Accessors
Extension Properties = A Mashup
Escaping Keywords
The Scenario: Mockito
The Problem: Keywords
The Solution: Backticks
Escaped Method Names
The Scenario: JUnit Tests
The Problem: You Are Tired of CamelCase
The Solution: Backticks
Property Delegates
A Refresher on lazy
What’s Really Going On
Other Stock Property Delegates
Class Delegation
Playing Favorites
Manual Delegation
The Class Delegate Alternative
Constants
Declaring a Constant
Why Bother, When We Have val?
Constant Type Limitations
Abstract Properties
But, But, But… Why?
Abstract val
Abstract var
Covariance in Generics
You Can’t Put That in That!
out Is a Direction
Declaration-Site and Use-Site Variance
Contravariance in Generics
Declaration-Site and Use-Site Variance
Anonymous Functions
The Problem: Return Types
The Solution: Anonymous Function Syntax
Constraints and Effects
Local Functions
I Heard You Like Functions…
…So I Put a Function in Your Function
Funception
Local Types
Scenario: Perils of Pair Programming
Inline Functions
Macro History
Inline Functions: Like Macros
Inline Properties
Inline Classes
What?
Why?
Alpha!
Reified Type Parameters
Type Erasure (Other Than Via the Backspace Key)
Reified = Retained Type for Inline Functions
noinline and crossinline
noinline: Keep the Lambda as an Object
crossinline: Allowing return
Receivers in Function Types
What with() Looks Like
What apply() Looks Like
Use Case: DSL
Renamed Imports
The Scenario: Observable
The Problem: Import Name Collisions
The Solution: import ... as
Operator Overloading
What the #$@&%!?
The Concept of Operator Overloading
Example: Dividing a String
So. Many. Operators
Infix Functions
Postfix and Infix
The infix Keyword
Limitations
Destructuring Declarations
The Components of a Class
OK, Why Would We Use This?
So, Why Does This Exist?
Labeled Returns
Where return Goes By Default
Returning Just from a Lambda
Applying a Label
Is Any of This a Good Idea?
Nothing
Nothing: It’s On the Bottom
Uses of Nothing
Types of Keywords
Hard Keywords
Soft Keywords
Modifier Keywords
In General, Avoid Keywords
Список книг
[*]
Mark L. Murphy - Elements Of Android Jetpack - 2021 (880), PDF, EPUB, MOBI (Издательский макет или текст)
[*]
Mark L. Murphy - Elements Of Kotlin Coroutines - 2021 (244), PDF, EPUB, MOBI (Издательский макет или текст)
[*]
Mark L. Murphy - Elements Of Android Q - 2019 (96), PDF, EPUB, MOBI (Издательский макет или текст)
[*]
Mark L. Murphy - Exploring Android - 2021 (612), PDF, EPUB, MOBI (Издательский макет или текст)
[*]
Mark L. Murphy - Elements Of Android Room - 2021 (244), PDF, EPUB, MOBI (Издательский макет или текст)
[*]
Mark L. Murphy - Elements Of Android R - 2020 (141), PDF, EPUB, MOBI (Издательский макет или текст) [*]
Mark L. Murphy - The Busy Coder's Guide to Android Development - 2019 (4417, 978-0-9816780-0-9), PDF, EPUB, MOBI (Издательский макет или текст)
[*]
Mark L. Murphy - Android's Architecture Components - 2019 (412), PDF, EPUB, MOBI (Издательский макет или текст)
[*]
Mark L. Murphy - GraphQL and Android - 2019 (262), PDF, EPUB, MOBI (Издательский макет или текст)
[2021-04-23] Обновление до версии 1.0 (changelog )
Download
Rutracker.org не распространяет и не хранит электронные версии произведений, а лишь предоставляет доступ к создаваемому
пользователями каталогу ссылок на
торрент-файлы ,
которые содержат только списки хеш-сумм