Log In
Or create an account ->
Imperial Library
Home
About
News
Upload
Forum
Help
Login/SignUp
Index
Title Page
Copyright
Mastering Android Development with Kotlin
Credits
About the Author
Acknowledgments
About the Reviewer
www.PacktPub.com
Why subscribe?
Customer Feedback
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the example code
Downloading the color images of this book
Errata
Piracy
Questions
Starting with Android
Why Kotlin?
Kotlin for Android - it's official
Downloading and configuring Android Studio
Setting up Android emulators
Creating a new AVD instance
Duplicating an existing AVD and modifying it by need
Android Debug Bridge
Other important tools
Initializing a Git repository
Creating an Android project
Setting up Gradle
Explaining directory structure
Defining build types and flavors
Additional libraries
Getting familiar with Android Manifest
Main Application class
Your first screen
Summary
Building and Running
Running your first Android application
Meet the Logcat
First case
Using the Gradle build tool
Debug your application
Summary
Screens
Analyzing the mockup plan
Defining application activities
Android layouts
Using EditText views
The margins attribute
The padding attribute
Checking out the gravity attribute
Looking at other attributes
Understanding Android Context
Understanding fragments
Fragment manager
Fragments stack
Creating View Pager
Making animations with transitions
Dialog fragments
Notifications
Other important UI components
Summary
Connecting Screen Flow
Creating an application bar
Using the navigation drawer
Connecting activities
Looking deeper into Android Intents
Passing information between activities and fragments
Summary
Look and Feel
Themes in the Android Framework
Styles in Android
Working with assets
Using custom fonts
Applying coloring
Make your buttons look pretty
Setting animations
Animation sets in Android
Summary
Permissions
Permissions from Android Manifest
Requesting permissions
Doing it the Kotlin way
Summary
Working with Databases
Introduction to SQLite
Benefits
Describing our database
CRUD operations
Insert CRUD operation
Update CRUD operation
Delete CRUD operation
Select CRUD operation
Tying things together
Summary
Android Preferences
What are Android preferences?
How can you use them?
Editing (storing) preferences
Removing preferences
Defining your own preferences manager
Summary
Concurrency in Android
Introduction to Android concurrency
Main thread
Handlers and threads
AsyncTask
Understanding Android Looper
Preparing the Looper
Delayed execution
Summary
Android Services
Service categorization
Foreground Android services
Background Android services
Bound Android services
Android service basics
Declaring your service
Starting the service
Stopping the service
Binding to Android service
Stopping the service
Service lifecycle
Defining the main application service
Defining the intent service
Summary
Messaging
Understanding Android broadcasts
System broadcasts
Listening for broadcasts
Registering from the context
Receivers execution
Sending broadcasts
Creating your own broadcast messages
Using on boot and on shutdown broadcasts
Listening for network events
Summary
Backend and API
Identifying entities used
Working with data classes
Connect data models to a database
Introduction to Retrofit
Defining Retrofit service
Building a Retrofit service instance
Introduction to Gson with Kotson library
What else is available?
Retrofit alternative
Gson alternative
Executing our first API call
Content providers
Android adapters
Content loaders
Data binding
Using lists
Using grids
Implementing drag and drop
Summary
Tuning Up for High Performance
Optimizing layouts
Optimizing battery life
Keeping your application responsive
Summary
Testing
Adding dependencies
Updating folder structure
Writing your first test
Using test suites
How to test UI
Running tests
Running unit tests
Running instrumentation tests
Summary
Migration to Kotlin
Preparing the migration
Danger signs
Updating dependencies
Converting classes
Refactoring and cleanup
Summary
Deploying Your Application
Preparing for deployment
Code obfuscation
Signing your application
Publishing to Google Play
Summary
← Prev
Back
Next →
← Prev
Back
Next →