Index

Symbols

?. 91

<application> 541

<fragment> 297

<fragment> element 297

<receiver> 510

<service> 541, 556, 563

<uses-permission> 490

Code Reformatting 69

@layout/toolbar_fragment 306

:: operator 93

.well-known folder 735

A

AbsoluteLayout 166

ACCESS_COARSE_LOCATION permission 682

ACCESS_FINE_LOCATION permission 682

ACTION_CREATE_DOCUMENT 649

ACTION_CREATE_INTENT 649

ACTION_DOWN 272

ACTION_MOVE 272

ACTION_OPEN_DOCUMENT 643

ACTION_OPEN_DOCUMENT intent 642

ACTION_POINTER_DOWN 272

ACTION_POINTER_UP 272

ACTION_UP 272

ACTION_VIEW 505

Active / Running state 140

Activity 77, 143

adding to a project 225

adding views in Java code 249

class 143

creation 14

Entire Lifetime 147

Foreground Lifetime 147

lifecycle methods 145

lifecycles 137

returning data from 488

state change example 151

state changes 143

states 140

Visible Lifetime 147

ActivityCompat class 687

Activity Lifecycle 139

Activity Manager 76

Activity Stack 139

Actual screen pixels 236

adb

command-line tool 55

list devices 55

restart server 56

ADB

enabling on Android devices 55

Linux configuration 58

macOS configuration 56

overview 55

testing connection 58

Windows configuration 57

addCategory() method 509

addView() method 242

ADD_VOICEMAIL permission 682

Advanced Profiling 749

android

commandline tool 36

exported 541

gestureColor 291

layout_behavior property 471

onClick 299

process 542, 563

uncertainGestureColor 291

Android

Activity 77

architecture 73

events 263

intents 78

onClick Resource 263

runtime 74

SDK Packages 6

android.app 74

Android Architecture Components 315

android.content 74

android.content.Intent 487

android.database 74

Android Debug Bridge. See  ADB

Android Design Support Library 427

Android Development

System Requirements 3

Android Devices

designing for different 165

android.graphics 74

android.hardware 74

android.intent.action 515

android.intent.action.BOOT_COMPLETED 542

android.intent.action.MAIN 505

android.intent.category.LAUNCHER 505

Android Libraries 74

AndroidManifest.xml file 226

android.media 75

Android Monitor tool window 33, 155

Android Native Development Kit 75

android.net 75

android.opengl 75

android.os 75

android.permission.RECORD_AUDIO 691

android.print 75

Android Profiler 749

Android Project

create new 13

android.provider 75

Android SDK Location

identifying 8

Android SDK Manager 6, 7, 9

Android SDK Packages

version requirements 7

Android SDK Tools

command-line access 8

Linux 9

macOS 10

Windows 7 8

Windows 8 9

Android Software Stack 73

Android Storage Access Framework 642

Android Studio

changing theme 53

downloading 3

Editor Window 48

installation 4

Linux installation 5

macOS installation 4

Main Window 47

Menu Bar 48

Navigation Bar 48

Project tool window 49

setup wizard 5

Status Bar 48

Toolbar 48

updating 11

Welcome Screen 47

Windows installation 4

android.text 75

Android tool window 51

android.util 75

android.view 75

android.view.View 168

android.view.ViewGroup 165, 168

Android Virtual Device. See  AVD

overview 29

Android Virtual Device Manager 29

android.webkit 75

android.widget 75

APK analyzer 778

APK file 772

split 782

APK File

analyzing 778

APK Signing 810

APK Wizard dialog 770

App Architecture

modern 315

AppBar

anatomy of 469

appbar_scrolling_view_behavior 471

App Bundles 767

creating 772

overview 767

revisions 777

uploading 774

AppCompatActivity class 144

Application

stopping 33

Application Context 79

Application Framework 75

Application Manifest 79

Application Resources 79

App Link

Adding Intent Filter 742

Assistant 737

Digital Assets Link file 735

Intent Filter Handling 742

Intent Filters 733

Intent Handling 734

Testing 745

tutorial 737

URL Mapping 739

website association 745

App Link Assistant 737

App Links 733

overview 733

Apply Changes 257

Apply Changes and Restart Activity 257

Apply Code Changes 257

fallback settings 259

options 257

Run App 257

tutorial 259

Architecture Components 315

ART 74

as 93

as? 93

assetlinks.json 735

async 527

AsyncTask

doInBackground() method 520

example 517

onPostExecute() method 520

onPreExecute() method 520

onProgressUpdate() method 520

publishProgress() method 521

subclassing 519

thread pool executor 522

Attribute Keyframes 394

Audio

supported formats 689

Audio Playback 689

Audio Recording 689

Autoconnect Mode 198

AVD

command-line creation 30, 36

configuration files 38

creation 30

overview 29

renaming 38

running an application 31

starting 31

Startup size and orientation 31

B

Background Process 138

Barriers 192

adding 210

constrained views 192

Base APK file 782

Baseline Alignment 191

beginTransaction() method 298

Binding Expressions 339

one-way 339

two-way 340

bindService() method 540, 553, 558

Biometric Authentication 759

callbacks 763

overview 759

tutorial 759

Biometric Prompt 764

BitmapFactory 644

Bitwise AND 99

Bitwise Inversion 98

Bitwise Left Shift 100

Bitwise OR 99

Bitwise Right Shift 100

Bitwise XOR 99

black activity 14

Blank template 169

Blueprint view 197

BODY_SENSORS permission 682

Boolean 86

Bottom Up 753

Bound Service 539, 540, 553

adding to a project 554

Implementing the Binder 554

Interaction options 553

BoundService class 555

Broadcast Intent 509

example 512

overview 78, 509

sending 512

Sticky 511

Broadcast Receiver 509

adding to manifest file 514

creation 513

overview 78, 510

BroadcastReceiver class 510

BroadcastReceiver superclass 513

BufferedReader object 656

Build Variants 810

Build Variants tool window 51

Bundle class 160

Bundled Notifications 576

C

Calendar permissions 682

Call Chart 754

CALL_PHONE permission 682

CAMERA permission 682

Camera permissions 682

cancelAndJoin() 528

cancelChildren() 527

CancellationSignal 764

Canvas class 728

CardView

example 453

layout file 451

responding to selection of 459

CardView class 451

CATEGORY_OPENABLE 642

C/C++ Libraries 75

Chain bias 220

chain head 190

chains 190

Chains

creation of 217

Chain style

changing 219

chain styles 190

Char 86

CharSequence 161

CheckBox 165

checkSelfPermission() method 686

Code completion 64

Code Editor

basics 61

Code completion 64

Code Generation 66

Code Reformatting 69

Document Tabs 62

Editing area 62

Gutter Area 62

Live Templates 70

Splitting 63

Statement Completion 65

Status Bar 63

Code Generation 66

code samples

download 1

CollapsingToolbarLayout

example 472

introduction 472

parallax mode 472

pin mode 472

setting scrim color 475

setting title 475

with image 472

Color class 730

COLOR_MODE_COLOR 704, 724

COLOR_MODE_MONOCHROME 704, 724

com.android.application 785

com.android.dynamic-feature 785

Common Gestures 279

detection 279

Communicating Sequential Processes 525

Companion Objects 123

Component tree 17

Configuration APK file 782

Constraint Bias 189

adjusting 203

ConstraintLayout

advantages of 195

Availability 196

Barriers 192

Baseline Alignment 191

chain bias 220

chain head 190

chains 190

chain styles 190

Constraint Bias 189

Constraints 187

conversion to 214

convert to MotionLayout 401

deleting constraints 202

guidelines 209

Guidelines 192

manual constraint manipulation 199

Margins 188, 203

Opposing Constraints 188, 204

overview of 187

Packed chain 191, 220

ratios 195, 221

Spread chain 190

Spread inside 219

Spread inside chain 190

tutorial 225

using in Android Studio 197

Weighted chain 190, 220

Widget Dimensions 191, 207

Widget Group Alignment 213

ConstraintLayout chains

creation of 217

in layout editor 217

ConstraintLayout Chain style

changing 219

Constraints

deleting 202

ConstraintSet

addToHorizontalChain() method 244

addToVerticalChain() method 244

alignment constraints 243

apply to layout 242

applyTo() method 242

centerHorizontally() method 243

centerVertically() method 243

chains 243

clear() method 244

clone() method 243

connect() method 242

connect to parent 242

constraint bias 243

copying constraints 243

create 242

create connection 242

createHorizontalChain() method 243

createVerticalChain() method 243

guidelines 244

removeFromHorizontalChain() method 244

removeFromVerticalChain() method 244

removing constraints 244

rotation 245

scaling 244

setGuidelineBegin() method 244

setGuidelineEnd() method 244

setGuidelinePercent() method 244

setHorizonalBias() method 243

setRotationX() method 245

setRotationY() method 245

setScaleX() method 244

setScaleY() method 244

setTransformPivot() method 245

setTransformPivotX() method 245

setTransformPivotY() method 245

setVerticalBias() method 243

sizing constraints 243

tutorial 249

view IDs 251

ConstraintSet class 241, 242

ConstraintSet.PARENT_ID 242

Constraint Sets 242

ConstraintSets

configuring 390

Contacts permissions 682

container view 165

Content Provider 76

overview 79

Context class 79

CoordinatorLayout 166, 469, 471

Coroutine Builders 527

async 527

coroutineScope 527

launch 527

runBlocking 527

supervisorScope 527

withContext 527

Coroutine Dispatchers 526

Coroutines 525

adding libraries 533

channel communication 531

GlobalScope 526

returning results 529

Suspend Functions 526

suspending 528

tutorial 533

ViewModelScope 526

vs. Threads 525

coroutineScope 527

Coroutine Scope 526

CPU Profiler 752

createPrintDocumentAdapter() method 719

Custom Accessors 121

Custom Attribute 391

Custom Document Printing 707, 719

Custom Gesture

recognition 285

Custom Print Adapter

implementation 721

Custom Print Adapters 719

Cycle Editor 419

Cycle Keyframe 399

Cycle Keyframes

overview 415

D

dangerous permissions 681

list of 682

Dark Theme 33

enable on device 33

Data Access Object (DAO) 606

Database Inspector 612, 636

live updates 636

SQL query 636

Database Rows 600

Database Schema 599

Database Tables 599

Data binding

binding expressions 339

Data Binding 318

binding classes 338

enabling 344

event and listener binding 340

key components 335

overview 335

tutorial 343

variables 338

with LiveData 318

DDMS 33

Debugging

enabling on device 55

Default Function Parameters 113

deltaRelative 395

Density-independent pixels 235

Density Independent Pixels

converting to pixels 254

Device Definition

custom 182

Digital Asset Link file 746

Digital Assets Link file 735

Direct Reply Input 586

Direct Reply Notification 581

Dispatchers.Default 527

Dispatchers.IO 526

Dispatchers.Main 526

document provider 641

dp 235

Dynamic Delivery 784

Dynamic Feature APK 782

Dynamic Feature Module

architecture 781

overview 781

removal 806

tutorial 791

Dynamic Feature Modules

deferred installation 787

handling of large 788

Dynamic Feature Support

adding to project 791

Dynamic State 145

saving 159

E

Elvis Operator 93

Empty Process 139

Empty template 169

Emulator

battery simulation 42

cellular configuration 42

configuring fingerprints 44

creation 30

directional pad 42

extended control options 41

Extended controls 41

fingerprint 42

location configuration 41

phone settings 42

resize 41

rotate 40

Screen Record 42

Snapshots 42

starting 31

take screenshot 40

toolbar 39

toolbar options 39

Virtual Sensors 42

zoom 40

enabling ADB support 55

Energy Profiler 758

Escape Sequences 87

Event Handling 263

example 264

Event Listener 266

Event Listeners 264

Event Log tool window 51

Events

consuming 267

explicit

intent 78

explicit intent 487

Explicit Intent 487

Extended Control

options 41

F

Favorites tool window 51

Files

switching between 62

findPointerIndex() method 272

findViewById() 133

Fingerprint

emulation 44

Fingerprint authentication

device configuration 760

permission 760

steps to implement 759

Fingerprint Authentication

overview 759

tutorial 759

FLAG_INCLUDE_STOPPED_PACKAGES 509

Flame Chart 754

flexible space area 469

Float 86

floating action button 14, 170, 427

changing appearance of 431

margins 428

overview of 427

removing 171

sizes 428

Foldable Devices 147

multi-resume 147

Foldable Emulator 592

Foldables 591

Foreground Process 138

Fragment

creation 295

event handling 299

XML file 295, 296

FragmentActivity class 144

Fragment Communication 299

FragmentPagerAdapter class 442

Fragments 295

adding in code 298

duplicating 439

example 303

overview 295

FrameLayout 166

Function Parameters

variable number of 113

Functions 111

G

Gesture Builder Application 285

building and running 286

Gesture Detector class 279

GestureDetectorCompat 282

instance creation 282

GestureDetectorCompat class 279

GestureDetector.OnDoubleTapListener 279, 280

GestureDetector.OnGestureListener 280

GestureLibrary 285

GestureLibrary class 285

GestureOverlayView 285

configuring color 291

configuring multiple strokes 291

GestureOverlayView class 285

GesturePerformedListener 285

Gestures

interception of 291

Gestures File

creation 286

extract from SD card 287

loading into application 288

GET_ACCOUNTS permission 682

getAction() method 515

getId() method 242

getIntent() method 488

getPointerCount() method 272

getPointerId() method 272

getService() method 557

GlobalScope 526

GNU/Linux 74

Google Cloud Print 702

Google Drive 642

printing to 702

Google Play Developer Console 768

Gradle

APK signing settings 814

Build Variants 810

command line tasks 815

dependencies 809

Manifest Entries 810

overview 809

sensible defaults 809

Gradle Build File

top level 810

Gradle Build Files

module level 812

Gradle tool window 51

GridLayout 166

GridLayoutManager 449

H

Handler class 562

Higher-order Functions 115

HP Print Services Plugin 701

HTML printing 705

HTML Printing

example 709

I

IBinder 540, 555

IBinder object 553, 561, 562

Image Printing 704

Immutable Variables 88

implicit

intent 78

implicit intent 487

Implicit Intent 489

Implicit Intents

example 501

in 235

Initializer Blocks 121

In-Memory Database 612

Inner Classes 122

Instant Dynamic Feature Module 782

IntelliJ IDEA 81

Intent 78

explicit 78

implicit 78

Intent Availability

checking for 491

Intent.CATEGORY_OPENABLE 649

intent filters 487

Intent Filters 490

App Link 733

intent resolution 490

Intents 487

overview 487

Intent Service 539

IntentService 546

IntentService class 539, 542, 543

Intent URL 503

is 93

isInitialized property 93

J

Java

convert to Kotlin 81

Java Native Interface 75

JetBrains 81

Jetpack 315

overview 315

join() 527

K

KeyAttribute 394

Keyboard Shortcuts 52

KeyCycle 399, 415

Cycle Editor 419

tutorial 415

Keyframe 407

Keyframes 394

KeyFrameSet 424

KeyPosition 395

deltaRelative 395

parentRelative 395

pathRelative 396

Keystore File

creation 770

KeyTimeCycle 399, 415

KeyTrigger 399

Killed state 140

Kotlin

accessing class properties 121

and Java 81

arithmetic operators 95

assignment operator 95

augmented assignment operators 96

bitwise operators 98

Boolean 86

break 106

breaking from loops 105

calling class methods 121

Char 86

class declaration 117

class initialization 118

class properties 118

Companion Objects 123

conditional flow control 107

continue labels 106

continue statement 106

convert from Java 81

Custom Accessors 121

data types 85

decrement operator 96

Default Function Parameters 113

defining class methods 118

do ... while loop 105

Elvis Operator 93

equality operators 97

Escape Sequences 87

expression syntax 95

Float 86

flow control 103

for-in statement 103

function calling 112

Functions 111

Higher-order Functions 115

if ... else ... expressions 108

if expressions 107

Immutable Variables 88

increment operator 96

inheritance 127

Initializer Blocks 121

Inner Classes 122

introduction 81

Lambda Expressions 114

let Function 91

Local Functions 112

logical operators 97

looping 103

Mutable Variables 88

Not-Null Assertion 91

Nullable Type 90

Overriding inherited methods 130

playground 82

Primary Constructor 118

properties 121

range operator 98

Safe Call Operator 90

Secondary Constructors 118

Single Expression Functions 112

String 86

subclassing 127

Type Annotations 89

Type Casting 93

Type Checking 93

Type Inference 89

variable parameters 113

when statement 108

while loop 104

L

Lambda Expressions 114

lateinit 92

Late Initialization 92

launch 527

launcher activity 226

layout_collapseMode

parallax 474

pin 474

layout_constraintDimentionRatio 222

layout_constraintHorizontal_bias 220

layout_constraintVertical_bias 220

layout editor

ConstraintLayout chains 217

Layout Editor 16, 225

Autoconnect Mode 198

code mode 175

Component Tree 173

design mode 173

device screen 173

example project 225

Inference Mode 199

palette 173

properties panel 173

Sample Data 182

Setting Properties 177

toolbar 173

user interface design 227

view conversion 181

Layout Editor Tool

changing orientation 16

overview 172

Layout Managers 165

LayoutResultCallback object 725

Layouts 165

layout_scrollFlags

enterAlwaysCollapsed mode 471

enterAlways mode 471

exitUntilCollapsed mode 471

scroll mode 471

Layout Validation 184

let Function 91

libc 75

Lifecycle

awareness 359

components 318

observers 360

owners 359

states and events 360

tutorial 363

Lifecycle-Aware Components 359

Lifecycle Methods 145

Lifecycle Observer 363

creating a 363

Lifecycle Owner

creating a 366

Lifecycles

modern 318

LinearLayout 166

LinearLayoutManager 449

LinearLayoutManager layout 457

Linux Kernel 74

list devices 55

ListView

adaptor 432

adding items 432

example 431

LiveData 316, 329

adding to ViewModel 329

observer 331

tutorial 329

Live Templates 70

Local Bound Service 553

example 553

Local Functions 112

Location Manager 76

Location permission 682

LogCat

enabling 155

filter configuration 155

M

Main Thread 517

Manifest File

permissions 505

Master/Detail Flow

anatomy of 479

creation 478

Object Kind 478, 479

two pane mode 477

match_parent properties 235

Material design 427

MediaController

adding to VideoView instance 663

MediaController class 660

methods 660

MediaPlayer class 689

methods 689

MediaRecorder class 689

methods 690

recording audio 690

Memory Profiler 755

Messenger object 562

Microphone

checking for availability 692

Microphone permissions 682

mm 235

MotionEvent 271, 272, 293

getActionMasked() 272

MotionLayout 389

arc motion 394

Attribute Keyframes 394

ConstraintSets 390

Custom Attribute 410

Custom Attributes 391

Cycle Editor 419

Cycle Keyframes 399

Editor 401

KeyAttribute 394

KeyCycle 415

Keyframes 394

KeyFrameSet 424

KeyPosition 395

KeyTimeCycle 415

KeyTrigger 399

OnClick 393, 406

OnSwipe 393

overview 389

Position Keyframes 395

previewing animation 405

starting animation 392

Trigger Keyframe 399

Tutorial 401

MotionScene

ConstraintSets 390

Custom Attributes 391

file 390

overview 389

transition 390

Multiple Touches

handling 272

multi-resume 148

Multi-Touch

example 273

Multi-touch Event Handling 271

Multi-Window

attributes 595

Multi-Window Mode

detecting 596

entering 593

launching activity into 597

Multi-Window Notifications 596

multi-window support 148

Multi-Window Support

enabling 594

Mutable Variables 88

N

Navigation 369

adding destinations 379

overview 369

pass data with safeargs 385

passing arguments 374

safeargs 374

stack 369

tutorial 375

Navigation Action

triggering 373

Navigation Architecture Component 369

Navigation Component

tutorial 375

Navigation Controller

accessing 373

Navigation Graph 372, 376

adding actions 382

creating a 376

Navigation Host 370

declaring 377

Network Profiler 756

non-thread-safe code 517

normal permissions 681

Notification

adding actions 576

direct reply 581

Direct Reply Input 586

issuing a basic 572

launch activity from a 574

PendingIntent 583

Reply Action 584

updating direct reply 588

Notifications 567

bundled 576

overview 567

Notifications Manager 76

Not-Null Assertion 91

Nullable Type 90

O

Observer

implementing a LiveData 331

onActivityResult() method 489, 498, 648, 650

onAttach() method 300

onBind() method 540, 546, 553, 561

onBindViewHolder() method 457

OnClick 393

onClickListener 264, 266, 268

onClick() method 263

onCreateContextMenuListener 264

onCreate() method 138, 145, 540

on-demand modules 781

onDestroy() method 146, 540

onDoubleTap() method 279

onDown() method 279

onFling() method 279

onFocusChangeListener 264

OnFragmentInteractionListener

implementation 383

onGesturePerformed() method 285

onHandleIntent() method 539, 540, 544

onKeyListener 264

onLayoutFailed() method 725

onLayoutFinished() method 725

onLongClickListener 264, 267

onLongPress() method 279

onPageFinished() callback 710

onPause() method 146

onReceive() method 138, 510, 511, 513

onRequestPermissionsResult() method 685, 697

onRestart() method 145

onRestoreInstanceState() method 146

onResume() method 138, 146

onSaveInstanceState() method 146

onScaleBegin() method 291

onScaleEnd() method 291

onScale() method 291

onScroll() method 279

OnSeekBarChangeListener 308

onServiceConnected() method 553, 557, 563

onServiceDisconnected() method 553, 557, 563

onShowPress() method 279

onSingleTapUp() method 279

onStartCommand() method 540, 546, 548

onStart() method 145

onStop() method 146

onTabSelectedListener 444

onTouchEvent() method 279, 291

onTouchListener 264, 271

onTouch() method 271, 272

openFileDescriptor() method 642, 643

P

Package Explorer 15

Package Manager 76

PackageManager class 692

PackageManager.FEATURE_MICROPHONE 692

PackageManager.PERMISSION_DENIED 683

PackageManager.PERMISSION_GRANTED 683

Package Name 14

Packed chain 191, 220

PageRange 726, 728

Paint class 730

parentRelative 395

parent view 167

pathRelative 396

Paused state 140

PdfDocument 707

PdfDocument.Page 719, 726

PendingIntent class 583

Permission

checking for 683

permissions

dangerous 681

normal 681

Persistent State 145

Phone permissions 682

picker 641

Pinch Gesture

detection 291

example 292

Pinch Gesture Recognition 285

Play Core Library 787, 791

Position Keyframes 395

Primary Constructor 118

PrintAttributes 724

PrintDocumentAdapter 707, 719

PrintDocumentInfo 724

Printing

color 704

monochrome 704

Printing framework

architecture 701

Printing Framework 701

Print Job

starting 730

Print Manager 701

PrintManager service 711

PROCESS_OUTGOING_CALLS permission 682

Process States 137

Profiler 749

Bottom Up 753

Call Chart 754

CPU Profiler 752

enable advanced profiling 749

Energy Profiler 758

Flame Chart 754

Instrumented 752

Memory 755

Network 756

Sampled 752

Sessions Panel 751

Top Down 753

ProgressBar 165

proguard-rules.pro file 814

ProGuard Support 810

Project Name 14

Project tool window 15, 51

pt 235

putExtra() method 487, 509

px 236

Q

Quick Documentation 68

R

RadioButton 165

Range Operator 98

ratios 221

READ_CALENDAR permission 682

READ_CALL_LOG permission 682

READ_CONTACTS permission 682

READ_EXTERNAL_STORAGE permission 683

READ_PHONE_STATE permission 682

READ_SMS permission 682

RECEIVE_MMS permission 682

RECEIVE_SMS permission 682

RECEIVE_WAP_PUSH permission 682

Recent Files Navigation 52

RECORD_AUDIO permission 682

Recording Audio

permission 691

RecyclerView 449

adding to layout file 450

example 453

GridLayoutManager 449

initializing 457

LinearLayoutManager 449

StaggeredGridLayoutManager 449

RecyclerView Adapter

creation of 455

RecyclerView.Adapter 450, 455

getItemCount() method 450

onBindViewHolder() method 450

onCreateViewHolder() method 450

RecyclerView.ViewHolder

getAdapterPosition() method 460

registerReceiver() method 511

RelativeLayout 166

release mode 767

releasePersistableUriPermission() method 645

Release Preparation 767

Remote Bound Service 561

client communication 561

implementation 562

manifest file declaration 563

RemoteInput.Builder() method 583

RemoteInput Object 583

Remote Service

launching and binding 563

sending a message 565

Repository

tutorial 623

Repository Modules 318

requestPermissions() method 685

Resource

string creation 19

Resource File 21

Resource Management 137

Resource Manager 76

result receiver 511

Room

Data Access Object (DAO) 606

entities 606, 607

In-Memory Database 612

Repository 606

Room Database 606

tutorial 623

Room Database Persistence 605

Room Persistence Library 603, 605

root element 165

root view 167

runBlocking 527

Runtime Permission Requests 681

Run tool window 51

S

safeargs 374, 385

Safe Call Operator 90

Sample Data 182, 461

tutorial 461

Saved State 317, 353

library dependencies 355

SavedStateHandle 354, 355

contains() method 355

keys() method 355

remove() method 355

Saved State module 353

SavedStateViewModelFactory 354

ScaleGestureDetector class 291

Scale-independent 236

SD Card storage 691

SDK Manager 47

SDK Packages 6

SDK Settings 6

Secondary Constructors 118

Secure Sockets Layer (SSL) 75

SeekBar 303

sendBroadcast() method 509, 511

sendOrderedBroadcast() method 509, 511

SEND_SMS permission 682

sendStickyBroadcast() method 509

Sensor permissions 682

Service

anatomy 540

launch at system start 542

manifest file entry 541

overview 78

run in separate process 542

starting 545

ServiceConnection class 563

Service Process 138

Service Restart Options 541

setAudioEncoder() method 690

setAudioSource() method 690

setBackgroundColor() 242

setContentView() method 241, 249

setId() method 242

setOnClickListener() method 263, 266

setOnDoubleTapListener() method 279, 282

setOutputFile() method 690

setOutputFormat() method 690

setResult() method 489

setText() method 162

setTransition() 399

setVideoSource() method 690

shouldOverrideUrlLoading() method 710

shouldShowRequestPermissionRationale() method 687

SimpleOnScaleGestureListener 291

SimpleOnScaleGestureListener class 293

SMS permissions 682

Snackbar 427, 428, 429

adding an action item 434

overview of 428

Snapshots

emulator 43

sp 236

Space class 166

split APK files 782

SplitCompatApplication 786

SplitInstallManager 787

Spread chain 190

Spread inside 219

Spread inside chain 190

SQL 600

SQLite 599

AVD command-line use 601

Columns and Data Types 599

overview 600

Primary keys 600

StaggeredGridLayoutManager 449

startActivityForResult() method 488, 498

startActivity() method 487

Started Service 539

example 543

startForeground() method 138

START_NOT_STICKY 541

START_REDELIVER_INTENT 541

startService() method 539, 545

START_STICKY 541

State

restoring 162

State Change

handling 141

Statement Completion 65

status bar 469

Sticky Broadcast Intents 511

Stopped state 140

stopSelf() method 539

stopService() method 539

Storage Access Framework 641

ACTION_CREATE_DOCUMENT 642

ACTION_OPEN_DOCUMENT 642

deleting a file 645

example 647

file creation 649

file filtering 642

file reading 644

file writing 644

intents 642

MIME Types 643

Persistent Access 645

picker 641

Storage permissions 683

String 86

StringBuilder object 656

strings.xml file 23

Structured Query Language 600

Structure tool window 51

supervisorScope 527

Suspend Functions 526

Switcher 52

syncTask 517

synthetic properties 133

System Broadcasts 515

system requirements 3

T

tab bar 469

TabLayout 437

adding to layout 440

addTab() method 446

app

tabGravity property 446

tabMode property 446

example 438

fixed mode 445

getCount() method 437

getItem() method 437

onTabSelectedListener 444

overview 437

scrollable mode 445

setIcon() method 446

setting tab icons 446

TableLayout 166, 615

TableRow 615

Telephony Manager 76

Templates

blank vs. empty 169

Terminal tool window 51

Thread Handlers 517

Threads 517

creating 519

overview 517

Time Cycle Keyframes 399

TODO tool window 51

toolbar 469

ToolbarListener 300

tools

layout 297

tool window bars 49

Tool Windows 49

Top Down 753

Touch Actions 272

Touch Event Listener

implementation 274

Touch Events

intercepting 271

Touch handling 271

Type Annotations 89

Type Casting 93

Type Checking 93

Type Inference 89

U

unbindService() method 540

unregisterReceiver() method 511

URL Mapping 739

USB debugging

enabling 56

USE_BIOMETRIC 760

user interface state 145

USE_SIP permission 682

V

Video Playback 659

VideoView class 659

methods 659

supported formats 659

view bindings 133

enabling 134

using 135

View class

setting properties 250

view conversion 181

ViewGroup 165

View Groups 165

View Hierarchy 167

ViewHolder class 450

sample implementation 456

ViewModel

adding LiveData 329

data access 326

fragment association 325

overview 316

saved state 353

Saved State 317, 353

tutorial 321

ViewModelProvider 325

ViewModel Saved State 353

ViewModelScope 526

ViewPager 437, 441

adapter 441

adding to layout 440

example 438

Views 165

Java creation 241

View System 76

Virtual Device Configuration dialog 30

Virtual Sensors 42

Visible Process 138

W

WebViewClient 705, 710

WebView view 503

Weighted chain 190, 220

while Loop 104

Widget Dimensions 191

Widget Group Alignment 213

Widgets palette 228

withContext 527, 530

wrap_content properties 238

WRITE_CALENDAR permission 682

WRITE_CALL_LOG permission 682

WRITE_CONTACTS permission 682

WRITE_EXTERNAL_STORAGE permission 683

X

XML Layout File

manual creation 235

vs. Java Code 241

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.118.164.121