Home Page Icon
Home Page
Table of Contents for
Items functions
Close
Items functions
by Marko Devcic
Kotlin Quick Start Guide
Title Page
Copyright and Credits
Kotlin Quick Start Guide
Dedication
Packt Upsell
Why subscribe?
PacktPub.com
Contributors
About the author
About the reviewer
Packt is searching for authors like you
Preface
Who this book is for
What this book covers
To get the most out of this book
Download the example code files
Download the color images
Conventions used
Get in touch
Reviews
Introducing Kotlin
Compiling and running Kotlin
Kotlin's uses
Java interoperability
Build tools
Gradle
Maven
Setting up the development environment
Summary
Kotlin Basics
Functions
Local variables
Local functions
Type inference
Basic types
Numbers
Boolean
Characters
Strings
Base type
Arrays
Nullable types
Casting
Safe casting
Control flow
if-else
When
Loops
For loops
While loops
Do-While loops
Exceptions
Equality comparison
Packages
Visibility modifiers
Summary
Classes and Object-Oriented Programming
Classes
Properties
Class constructors
Primary constructors
Secondary constructors
Final by default
Constructing class instances
Nested classes
Enum classes
Data classes
Inheritance
Overriding members
Abstract classes
Interfaces
Interfaces versus abstract classes
Object keyword
Singletons with object keyword
Companion objects
Static with companion objects
Anonymous objects
Class delegation
Sealed classes
Smart casts
Summary
Functions and Lambdas
Advanced functions
Named arguments
Default parameters
Variable function arguments
Lambdas
Returning a value from a lambda
Passing lambdas as the only or last argument
Closures
Returning from lambdas
Function types
Defining function types
Calling function types
Naming parameters of function types
Calling function types from Java
Lambdas and SAM types
Member references
Inlining lambdas
noinline
crossinline
Summary
Advanced Kotlin
Generics
Declaring generic types
Generic functions
Generic constraints
Type erasure and raw types
Reified generics
Concurrency constructs
Starting a thread
Synchronized methods
Synchronized blocks
Volatile
Delegated properties
Standard library delegate properties
lazy
observable
vetoable
notNull
Extension functions
Importing extension functions
Java interoperability
Extension properties
Receiver functions
Infix functions
Building a simple DSL
Operator overloading
Overloading with extension functions
Operator overloading and Java
Bitwise operations
Summary
Kotlin Standard Library
Collections
Lists
Sets
Maps
Indexing
Platform types and immutable collections
Working with collections
Filtering functions
Drop
Filter
FilterNot
Take
General functions
Any
All
Count
ForEach
Max
Min
Sum
Transforming functions
Map
FlatMap
GroupBy
AssociateBy
Items functions
Contains
First
FirstOrNull
Last
LastOrNull
Single
SingleOrNull
Sorting functions
Reversed
Sorted
SortedDescending
Kotlin standard library functions
Contracts
Check
CheckNotNull
Require
RequireNotNull
Error
Standard functions
Apply
Let
With
Use
Summary
Coding a Dictionary App with Kotlin
Project setup
App features
Requirements
Creating the Kotlin-Gradle project
Developing the dictionary app
Preparing the data
Building the UI
Loading scene
Main Scene
Summary
Other Books You May Enjoy
Leave a review - let other readers know what you think
Search in book...
Toggle Font Controls
Playlists
Add To
Create new playlist
Name your new playlist
Playlist description (optional)
Cancel
Create playlist
Sign In
Email address
Password
Forgot Password?
Create account
Login
or
Continue with Facebook
Continue with Google
Sign Up
Full Name
Email address
Confirm Email Address
Password
Login
Create account
or
Continue with Facebook
Continue with Google
Prev
Previous Chapter
AssociateBy
Next
Next Chapter
Contains
Items functions
These functions can be used for obtaining items from a collection.
Add Highlight
No Comment
..................Content has been hidden....................
You can't read the all page of ebook, please click
here
login for view all page.
Day Mode
Cloud Mode
Night Mode
Reset