0% found this document useful (0 votes)
10 views23 pages

Lesson 2 Java and Android Concepts

Uploaded by

Yahya Gigi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views23 pages

Lesson 2 Java and Android Concepts

Uploaded by

Yahya Gigi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 23

Java and Android Concepts

Reading Java
Basic Concept
File, Package, class, Methods
• Java Code Components
Syntax Symbols
Method Signatures
• Collection of code of what defines what goes into and out of method,
what gets run when a method is called or triggered by app, who can
access the method
• Every method has unique signature, every signature contains clues of
how that method is supposed to work
• All signatures follow same basic format
Visualizing a Java Method
Memory lockers
Lets think of locker as a metaphor
• Lockers are numbered just like memory
(memory addresses)
• Effort of putting something in and out of
locker (write and read)
• Access of locker (sequential, random)
• Fixed size (memory block)
• How do we deal with a lot of information, we
distribute
Managing Memory in Programming
• Transistors; a switch is either ON or OFF
• Use data types (logical)
• Primitive Data types; Boolean, byte, short, int, long, char, float,
double
• Reference Types; stores a pointer to a place in Memory (memory
address)
• NB: As a programmer you need to use least amount of memory to be
efficient
Data Types and Variables
Memory Primitives
References and Null

Help you troubleshoot your code, and enable things


work best
Android Studio
• Every good professional has its environment; a good cook has a
kitchen; Mechanic has garage, for us its going to be Android Studio.
• Android studio is used for creating android applications
• Best on intelliJ engine loaded with features, smart editing, amazing
layout editor
• Gives you feedback as you code
• Get Android studio IDE, setup to use android studio SDK effectively
Instruction
• Run android studio, itelliJ
• Click configure
• Click SDK Manager
• Allows you to configure SDK to install in your machine
• Install
• Tools; Android 4.4.2 (API 19)
• Extras (Android Support Repository, Android Support Library, Google
Repository, Google USB Driver-connect to your device
• Click Install Package
• Accept License
• NB: It takes a bit to download
Open Project
• Open project and follow path where your SDK is located
Change Theme and Put line numbers
Line Numbers
• Navigate to res folder; contains descriptions on how things look
(images etc)
• Click layout, then activity_name..xml
Changes converted into xml
Methods of Deploying Mobile App
• When you click Run, Gradle(system that compounds things) will begin
to run
• You can deploy your application in
1. Android virtual device
2. Physical device
3. Genymotion

You might also like