Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
SlideShare a Scribd company logo
Introduction to Android Learning
BN1020 – Demo PPT
Demo Android
http://www.conlinetraining.com/courses/android-elearning-online-training/
Agenda
1. Introduction
2. Prerequisites
3. Android Basics
4. Core Content
5. Advantages and Jobs availability
6. Queries
7. Conclusion
http://www.conlinetraining.com/courses/android-elearning-online-training/
Prerequisites :
•Core JAVA Concepts
•OOPs Concepts
•JDK Installation
•Android SDK Setup
•Eclipse or Android Studio
http://www.conlinetraining.com/courses/android-elearning-online-training/
Android is ?
Android is a mobile operating system (OS) based on the Linux
kernel and developed by Google.
Android Components
Activity
Content
Provider
Broadcast
ReceiverServiceIntent
http://www.conlinetraining.com/courses/android-elearning-online-training/
Android
•Activity: A screen with which users can interact in order to do something.
•Intent: Messaging objects which used to request to perform a given
action from other components.
•Service: Used to run long running background task and does not
provide user interface.
•Broadcast Receiver: It allows to register and listen for device broadcast
announcements.
•Content Provider: (Next slide)
http://www.conlinetraining.com/courses/android-elearning-online-training/
Content Provider
•
• What is Content Provider?
• What does it do?
• Why do we need this?
• When we should use?
• How can we use?
http://www.conlinetraining.com/courses/android-elearning-online-training/
ACTIVITY
Your Facebook Wall is an “ACTIVITY”. As you click on the Photo
Button, an “INTENT” is passed, that conveys the message and the
“CONTENT PROVIDER” (Photo Gallery) opens. The photo is
uploaded using a network upload “SERVICE”.
http://www.conlinetraining.com/courses/android-elearning-online-training/
Content provider
http://www.conlinetraining.com/courses/android-elearning-online-training/
Content providers are
•Content providers are Android’s central mechanism that enables
you to access data of other applications – mostly information stored
in databases or flat files.
•Content providers are the standard interface that connects data in
one process with code running in another process.
http://www.conlinetraining.com/courses/android-elearning-online-training/
Content Provider performs
•Content providers support the four basic operations, normally
called CRUD-operations. CRUD is the acronym for create, read, upd
ate and delete.
•Querying: Queries the Content Provider for all the objects, based
on the specified URI.
•Delete: Deletes the specified objects from the database of a Content
Provider.
•Update: Makes updates to the objects in the database.
•Insert: Inserts new object to the database.
http://www.conlinetraining.com/courses/android-elearning-online-training/
Cont..
http://www.conlinetraining.com/courses/android-elearning-online-training/
Needs of Content providers
•You do not need to develop your own provider if you want a private
database for a particular application (this database would not be
accessible to applications other than the one that created it).
•You however need a Custom provider to provide custom search
suggestions in your own application system.
•You would also need a Content Provider to copy and paste complex
data from your application to other applications.
http://www.conlinetraining.com/courses/android-elearning-online-training/
Content Providers available
http://www.conlinetraining.com/courses/android-elearning-online-training/
Content Provider structure
Content Provider
Application #1
Activity
#1
Activity
#2
Activity
#3
Activity #1
Activity #1
Activity #2
Application #2
Database Files XML
Remote
connection …
http://www.conlinetraining.com/courses/android-elearning-online-training/
URI Permissions
Content URIs
• The most important concept to understand when dealing with content
providers is the content URI. Whenever you want to access data from a
content provider you have to specify a URI. URIs for content providers
look like this:
content://com.example.provider/articles
Scheme Authority Path
http://www.conlinetraining.com/courses/android-elearning-online-training/
SCHEME
•The scheme for content providers is always “content”. The colon and
double-slash “://” are a fixed part of the URI-RFC and separate the scheme
from the authority.
•The next part is the authority for the content provider. Authorities have to
be unique for every content provider. Thus the naming conventions should
follow the Java package name rules. That is you should use the reversed do
main name of your organization plus a qualifier for each and every content
provider you publish.
•The third part, the optional path, is used to distinguish the kinds of data
your content provider offers.
•You can include another element i.e. the id(optional), which – if present –
must be numeric. The id is used whenever you want to access a single
record (e.g. a specific video file).
http://www.conlinetraining.com/courses/android-elearning-online-training/
Cursors
➢ Cursor is an interface that provides random read-write access to the result of
a database query from a content provider.
➢ A cursor is a collection of rows
➢ All field access methods are based on column number. You have to convert
column name to a column number first
➢ You can also find size / traverse result set easily.
Cursor cur;
for(cur.moveToFirst();!cur.isAfterLast();cur.moveToNext()) {
//access methods
}
http://www.conlinetraining.com/courses/android-elearning-online-training/
Android Market, Career & Jobs
•Android Development: A big career boost!!!
•Need for Android developers
with over 200K applications available on Google’s Android
Market, and more than 4.5 Billion downloads
•The average salary starts from Rs 15,000-Rs 18,000 per
month
http://www.conlinetraining.com/courses/android-elearning-online-training/
Questions ???
http://www.conlinetraining.com/courses/android-elearning-online-training/
Email us : info@conlineTraining.com
Visit : www.conlinetraining.com

More Related Content

Bn1 1020 demo android