0% found this document useful (0 votes)
9 views10 pages

2maks MAD

The document outlines essential tools and software for Android application development, including Android Studio and ADB. It defines key concepts such as emulators, intents, fragments, and content providers, while also explaining the Android ecosystem and the need for permissions. Additionally, it covers installation steps for Android Studio, features of the Android SDK, and the process for deploying apps on the Google Play Store.
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)
9 views10 pages

2maks MAD

The document outlines essential tools and software for Android application development, including Android Studio and ADB. It defines key concepts such as emulators, intents, fragments, and content providers, while also explaining the Android ecosystem and the need for permissions. Additionally, it covers installation steps for Android Studio, features of the Android SDK, and the process for deploying apps on the Google Play Store.
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/ 10

1.

List all tools and software’s required for developing an android application
ANS-Android Studio • ADB (Android Debug Bridge) • AVD Manager • Eclipse • Fabric • FlowUp • GameMaker: Studio •
Genymotion • Gradle • IntelliJ IDEA
2.Define emulator.
Ans An Android emulator is a tool that creates virtual Android devices on your computer. The emulator lets you
prototype, develop and test Android applications without using a physical device.
3. List any four attributes of layout.
Ans • android:id • android:layout_width • android:layout_height • android:layout_margin

4. Define Geocoding and Reverse Geocoding.


Geocoding : Geocoding is the process of transforming a street address or other description of a location into a
(latitude, longitude) coordinate.
Reverse Geocoding : Reverse geocoding is the process of transforming a (latitude, longitude) coordinate into a
(partial) address.

5. State intent. List types of intent.


Ans Intent is the message that is passed between components such as activities. Android uses Intent for
communicating between the components of an Application and also from one application to another application.
Types: • Explicit Intent • Implicit Intent

6. Write difference between toggle button and radio button.


Ans (1)Toggle button 1. Toggle Button can be used to display checked/unchecked (On/Off) state on the button. 2. For
ON/OFF state two labels can be assign.
(2)Radio button 1. Radio Buttons are used to choose a single option from a list 2. There is only one label for radio
button.

7. Define: i)Fragment ii) Broadcast receiver


Fragment: Fragment is the part of activity, it is also known as sub-activity.
Broadcast receiver: A broadcast receiver is a dormant component of the Android system. The Broadcast Receiver’s
job is to pass a notification to the user, in case a specific event occurs.

_8. Define OHA and state goal of OHA.


The OHA is the group that is in charge of the Android smartphones operating system. It was created by Google. The
Open Handset Alliance (OHA) is consortium of multiple companies like Samsung, Sony, Intel and many more to
provide services and deploy handsets using android platform.
---9. Define Android Virtual Devices (AVD).
An Android Virtual Device (AVD) is a configuration that defines the characteristics of an Android phone, tablet, Wear
OS, Android TV, or Automotive OS device that you want to simulate in the Android Emulator. The AVD Manager is an
interface you can launch from Android Studio that helps you create and manage AVDs.

c) State how the APK files are built?


• The javac compiler compiles the java source file into the class file. • The dx tool takes all the class files of your
application and generates a single .dex file which is a platform specific tool. • Then Android Assets Packaging Tool
(aapt) handles the packaging process and finally creates an executable file with extension .apk. • An APK file contains
all of a program's code (such as .dex files), resources, assets, certificates, and manifest file.

d) Enlist the elements of UI.


Elements of UI. • EditText • TextView • ListView • GridView • ScrollView • ImageView • ToggleButton • CheckBox •
RadioButton

f) Name any four methods to get location data in android.


•float distanceTo(Location dest) •float getAccuracy() •float getBearing()•double getAltitude()

g) Explain significance of content provider


Content Providers are used to share data between two applications. This can be implemented in two ways: 1. When
you want to implement the existing content provider in another application. 2. When you want to create a new
content provider that can share its data with other Applications

) State Android ECO System


• Ecosystem in Market terminology refers to the inter-dependence between demand and supply. ▪ Google develops
android ▪ Users buy devices and applications ▪ Original Equipment makers sell devices, sometimes bundled with
applications ▪ Developers buy devices, then make and sell applications ▪ Freelance Android Developer developers have
the skills to contribute to the ecosystem for android development , they are who creates their own applications and
published them on googles play store

b) List various tools for android application development


• Android Studio • ADB (Android Debug Bridge) • AVD Manager • Eclipse • Fabric • FlowUp • GameMaker: Studio •
Genymotion • Gradle IntelliJ IDEA

c) List various layouts used in android UI design.


• Linear Layout • Absolute Layout • Frame Layout • Table Layout • Relative Layout

) Name any four attributes of Edit Text control.


android:id ,android: gravity ,android: text ,android: hint ,android: textColor ,android: textSize android: textStyle,
android: background
-1)State the use of fragments in android App development.
Android Fragment is the part of activity, it is also known as sub-activity. There can be more than one fragment in an
activity. Fragments were added in Honeycomb version of Android i.e API version 11. We can add, replace or remove
Fragment’s in an Activity while the activity is running. Fragment can be used in multiple activities. We can also
combine multiple Fragments in a single activity to build a multi-plane UI.
1.Explain relative layout with all its attributes.
In Relative Layout we need to specify the position of child views relative to each other or relative to the parent. In
case if we didn’t specify the position of child views, by default all child views are positioned to top-left of the layout.
Attributed of Relative Layout:
1.layout_alignParentTop
- If it specified “true”, the top edge of view will match the top edge of parent.
2.layout_alignParentBottom
- If it specified “true”, the bottom edge of view will match the bottom edge of parent
. 3.layout_alignParentLeft
-If it specified “true”, the left edge of view will match the left edge of parent.
3.layout_centerInParent
- If it specified “true”, the view will be aligned to center of parent.
b) Explore all steps to install Android studio and SDK
Pre-Installation Check List 1. Before installing Android SDK, there is need to install Java Development Kit (JDK). Ensure
that JDK is at or above 1.8. 2. Uninstall older version(s) of "Android Studio" and "Android SDK", if any. We need to
install two packages: 1. Android Studio (IDE), which is an Integrated Development Environment (IDE) 2. Android SDK
(Software Development Kit) for developing and running Android apps.
Download Android Studio 1. Click Download Android Studio. The Terms and Conditions page with the Android Studio
License Agreement opens. 2. Read the License Agreement. 3. At the bottom of the page, if you agree with the terms
and conditions, select the I have read and agree with the above terms and s checkbox. 4. Click Download Android
Studio to start the download. 5. When prompted, save the file to a location where you can easily locate it, such as the
Downloads folder. 6. Wait for the download to complete. Installing Android SDK Within Android Studio, you can
install the Android SDK as follows: 1. Click Tools > SDK Manager. 2. In the SDK Platforms tab, select Android Tiramisu
Preview. 3. In the SDK Tools tab, select Android SDK Build. 4. Click OK to install the SDK.
C) Explain the need of Android Operating System. Also describe any four features of android.
Need of Android Operating System • Zero/negligible development cost: The development tools like Android SDK,
JDK, and Eclipse IDE etc. are free to download for the android mobile application development. • Open Source: The
Android OS is an open-source platform based on the Linux kernel and multiple open-source libraries. In this way
developers are free to contribute or extend the platform as necessary for building mobile apps which run on
Android devices. • Multi-Platform Support In market, there are a wide range of hardware devices powered by the
Android OS, including many different phones and tablet. Even development of android mobile apps can occur on
Windows, Mac OS or Linux. • Multi-Carrier Support World wide a large number of telecom carriers like Airtel,
Vodafone, Idea Cellular, AT&T Mobility, BSNL etc. are supporting Android powered phones.
Four features of android- 1) Near Field Communication (NFC) Most Android devices support NFC, which allows
electronic devices to easily interact across short distances. 2) Alternate Keyboards Android supports multiple
keyboards and makes them easy to install; the SwiftKey, Skype, and 8pen apps all offer ways to quickly change up
your keyboard style. 3) Infrared Transmission The Android operating system supports a built-in infrared
transmitter, allowing you to use your phone or tablet as a remote control. 4) No-Touch Control Using Android apps
such as Wave Control, users can control their phones touch-free, using only gestures. 5) Automation The Tasker app
controls the app permissions but also automate them 6) Wireless App Downloads Using the Android Market or
third-party options like AppBrain, we can download apps on PC and then automatically sync them with Android, no
plugging required.
a) Describe the different features of Android.
User Interface: The user interface of the Android operating system is straight forward, and these features make it very
user friendly. Multiple Language Support: Android supports multiple languages in its operating system and one can
change the language very easily based on one’s requirement, the International languages supported are English,
Germany, Chinese, Dutch, French, German, Japanese, Korean, Russian, and many more also some native language of
India is also Supported Like Hindi, Marathi, Gujarati, Punjabi and many more. Multi-tasking: Android provides support
to run apps and services in the background with ease which allows the users to use multiple apps at the same time.
Connectivity: Android has extensive support to the connectivity and it supports connectivity such as WiFi, Bluetooth,
Hotspot, CDMA, GSM, NFC, VOLTE, UBB, VPN, 3G network band, and 4G Network Band. Extensive Application
Support: Android have Play store which is used as the major tool to download and update applications on the
operating system, however, one can download the installer(often called as APK file) and install it manually, but it is
not much recommended as third party applications could be prone to some security breach in the smartphones.
b) Explain features of Android SDK.
Android SDK is a collection of libraries and Software Development tools that are essential for Developing Android
Applications. Whenever Google releases a new version or update of Android Software, a corresponding SDK also
releases with it. In the updated or new version of SDK, some more features are included which are not present in the
previous version. Android SDK consists of some tools which are very essential for the development of Android
Application. These tools provide a smooth flow of the development process from developing and debugging. Android
SDK is compatible with all operating systems such as Windows, Linux, macOS, etc. 1. Android Tool: This tool helps in
managing the Android Virtual Device projects as well as the installed components of the software development kit. 2.
Emulator Tool: It helps us in testing the applications without the need of using the application on an actual device. 3.
Dalvik Debug Monitor Server(DDMS): DDMS is very useful for debugging the Android Application. 4. Android Debug
Bridge (ADB): It is a very versatile command-line tool and is helpful for the communication between the developer
and the Emulator or the Android device that is connected.
d) Elaborate the need of permissions in Android. Explain the permissions to set system functionalitics like SEND-
SMS, bluetooth.
The purpose of a permission is to protect the privacy of an Android user. Android apps must
request permission to access sensitive user data (such as contacts and SMS), as well as certain
system features (such as camera and internet). Depending on the feature, the system might grant
the permission automatically or might prompt the user to approve the request.
android. permission. SEND_SMS
Allows the app to send SMS messages. This may result in unexpected charges.
Malicious apps may cost you money by sending messages without your confirmation.
Following is the code snippet to set SEND_SMS permissions in manifest file.
<uses-permission android: name="android.permission.SEND_SMS"/>
android. permission. BLUETOOTH
You need to provide following permissions in AndroidManifest.xml file.
<uses-permission android:name="android.permission.BLUETOOTH" />
<uses-permission android:name="android.permission.BLUETOOTH_ADMIN" />
a) Explain data and time picker with its method
Ans Date Picker: In Android, DatePicker is a widget used to select a date. It allows to select date by day, month and
year in our custom UI (user interface). If we need to show this view as a dialog then we have to use a DatePickerDialog
class. Methods of DatePicker:1. setSpinnersShown(boolean shown): This method is used to set whether the spinner of
the date picker in shown or not. In this method you have to set a Boolean value either true or false. True indicates
spinner is shown, false value indicates spinner is not shown. Default value for this function is true. Syntax: DatePicker
simpleDatePicker = (DatePicker)findViewById(R.id.simpleDatePicker); simpleDatePicker.setSpinnersShown(false);
2. getDayOfMonth(): This method is used to get the selected day of the month from a date picker. This method
returns an integer value. DatePicker simpleDatePicker = (DatePicker) findViewById(R.id.simpleDatePicker); int day =
simpleDatePicker.getDayOfMonth();Methods of TimePicker:1. setCurrentHour(Integer currentHour): This method
is used to set the current hours in a time picker. setHour(Integer hour): setCurrentHour() method was deprecated in
API level 23. From api level 23 we have to use setHour(Integer hour). In this method there is only one parameter of
integer type which is used to set the value for
hours.TimePickersimpleTimePicker=(TimePicker)findViewById(R.id.simpleTimePicker);
simpleTimePicker.setCurrentHour(5); simpleTimePicker.setHour(5);
2. setCurrentMinute(Integer currentMinute): This method is used to set the current minutes in a time picker.
setMinute(Integer minute): setCurrentMinute() method was deprecated in API level 23. From api level 23 we have to
use setMinute(Integer minute). In this method there is only one parameter of integer type which set the value for
minutes. TimePicker simpleTimePicker=(TimePicker)findViewById(R.id.simpleTimePicker);
simpleTimePicker.setCurrentMinute(35); simpleTimePicker.setMinute(35)
b) Explain the steps to install and configure Android studio and SDK.
• Download the latest version of Android Studio from above URL and launch Android Studio.exe file by double clicking
on it. • The initial android studio setup screen will open in that click Next to continue for further steps of environment
setup • Now we need to select a required components to setup an android environment. Here we selected all three
components (Android Studio, Android SDK and Android Virtual Device) and click Next. • Now we need to agree the
License agreements to proceed further, click on I Agree button • Now we need to specify the local machine drive
location to install Android Studio and Android SDK. • After selecting the location path to install required components,
click Next. • Now select the start menu folder to create a shortcut for android studio and click Install • Once we click
Install button the installation process will start and click Next after completion of Installation. • After that it will show
installation completion wizard in that click Finish to launch android studio While launching Android Studio it will give
you an option to import settings from previous version of studio. In case if you don’t have any previous version, select
second option and click OK
c) Explain the steps to deploy app on Google Play Store.
Step 1: Create a Developer Account Before you can publish any app on Google Play, you need to create a Developer
Account. You can easily sign up for one using your existing Google Account. You’ll need to pay a one-time registration
fee of $25 using your international credit or debit card. It can take up to 48 hours for your registration to be fully
processed. Step 2: Plan to Sell? Link Your Merchant Account If you want to publish a paid app or plan to sell in-app
purchases, you need to create a payments center profile, i.e. a merchant account. A merchant account will let you
manage your app sales and monthly payouts, as well as analyze your sales reports right in your Play Console. Step 3:
Create an App After creating application by clicking on ‘Create Application'. Here you have to select your app’s default
language from the drop-down menu and then type in a title for your app. The title of your app will show on Google
Play after you’ve published. Step 4: Prepare Store Listing Before you can publish your app, you need to prepare its
store listing. These are all the details that will show up to customers on your app’s listing on Google Play.
a) Describe android and importance of OHA.
Android Android is an open source and Linux-based Operating System .It is designed primarily for touch screens
mobile devices such as smartphones and tablet computers. Android offers a unified approach to application
development for mobile devices which means developers need only develop for Android, and their applications
should be able to run on different devices powered by Android. Android was developed by the Open Handset Alliance,
led by Google, and other companies. OHA • The Open Handset Alliance (OHA) is a business alliance that was created
for the purpose of developing open mobile device standards. • The OHA has approximately 80 member companies,
including HTC, Dell, Intel, Motorola, Qualcomm and Google. Importance of OHA • Lower overall handset costs: Opens
up resources, which facilitates the focus on creating innovative applications, solutions and services. • Developer-
friendly environment: In the open-source community, developers share notes to expedite application development. •
Post-development: Provides an ideal channel for application marketing and distribution.
b) Explain Dalvik Virtual Machine and state its importance
The Dalvik Virtual Machine (DVM) is an android virtual machine optimized for mobile devices. Dalvik VM is also a
virtual machine that is highly optimized for mobile devices. Thus, it provides all the three things, that are memory
management, high performance as well as battery life. It is strictly developed for Android mobile phones.
The Dex compiler converts the class files into the .dex file that run on the Dalvik VM. Multiple class files are converted
into one dex file. The javac tool compiles the java source file into the class file. The dx tool takes all the class files of
your application and generates a single .dex file. It is a platform-specific tool. The Android Assets Packaging Tool (aapt)
handles the packaging process.
c) Describe the process of getting the map API key.
Creating API keys The API key is a unique identifier that authenticates requests associated with your project for usage
and billing purposes. You must have at least one API key associated with your project. 1. Browse the site on your
browser. https://console. developers. google.com/project 2. Login with your google account. 3. Create a new project
by clicking on Create Project option. 4. Add your project name and organization name in the fields present on the
screen. 5. Now click on APIs and Services. 6. Enable APIs and services. 7. Select Google maps Android API 8. To create
an API key for Maps click on Create credentials option and then select the API key option Click on the API key option
to generate your API key. After clicking on this option your API key will be generated
a) Describe various installation steps of android studio and its environment.
Step 1: Go to Android https://developer.android.com/studio to get the Android Studio executable or zip file.
Step 2: ● Click on the Download Android Studio Button. ● Click on the “I have read and agree with the above terms
and conditions” checkbox followed by the download button ● Click on the Save file button in the appeared prompt
box and the file will start downloading. Step 3: After the downloading has finished, open the file from downloads and
will prompt the following dialog box. Click on next. In the next prompt, it’ll ask for a path for installation. Choose a
path and hit next. Step 4: It will start the installation, and once it is completed, it will be like the image shown below.
Step 5: Once “Finish” is clicked, it will ask whether the previous settings need to be imported [if the android studio
had been installed earlier], or not. It is better to choose the ‘Don’t import Settings option’. Click the OK button. Step 6:
This will start the Android Studio. Meanwhile, it will be finding the available SDK components. Step 7: After it has
found the SDK components, it will redirect to the Welcome dialog box. Choose Standard and click on Next. Now
choose the theme, whether the Light theme or the Dark one. The light one is called the IntelliJ theme whereas the
dark theme is called Dracula. Choose as required. Click on the Next button. Step 8: Now it is time to download the SDK
components. Click on Finish. Components begin to download let it complete. The Android Studio has been
successfully configured. Now it’s time to launch and build apps. Click on the Finish button to launch it. Step 9: Click on
Start a new Android Studio project to build a new app.
b) Explain property animation method to animate the properties of view object with example
Ans A property animation changes a property's (a field in an object) value over a specified length of time. To animate
something, you specify the object property that you want to animate, such as an object's position on the screen, how
long you want to animate it for, and what values you want to animate between. The property animation system lets
you define the following characteristics of an animation: Duration: You can specify the duration of an animation. The
default length is 300 ms. Time interpolation: You can specify how the values for the property are calculated as a
function of the animation's current elapsed time. Repeat count and behavior: You can specify whether or not to have
an animation repeat when it reaches the end of a duration and how many times to repeat the animation. You can also
specify whether you want the animation to play back in reverse. Setting it to reverse plays the animation forwards
then backwards repeatedly, until the number of repeats is reached. Animator sets: You can group animations into
logical sets that play together or sequentially or after specified delays. Frame refresh delay: You can specify how often
to refresh frames of your animation. The default is set to refresh every 10 ms, but the speed in which your application
can refresh frames is ultimately dependent on how busy the system is overall and how fast the system can service the
underlying timer.
c) Describe permissions required for android application development.
The Android security model is primarily based on a sandbox and permission mechanism. Each application is running in
a specific Dalvik virtual machine with a unique user ID assigned to it, which means the application code runs in
isolation from the code of all other applications. Therefore, one application has not granted access to other
applications’ files. Android application has been signed with a certificate with a private key Know the owner of the
application is unique. This allows the author of the application will be identified if needed. When an application is
installed in the phone is assigned a user ID, thus avoiding it from affecting it other applications by creating a sandbox
for it. This user ID is permanent on which devices and applications with the same user ID are allowed to run in a single
process. This is a way to ensure that a malicious application has Cannot access / compromise the data of the genuine
application. It is mandatory for an application to list all the resources it will Access during installation. Terms are
required of an application, in the installation process should be user-based or interactive Check with the signature of
the application. Declaring and Using Permissions The purpose of a permission is to protect the privacy of an Android
user. Android apps must request permission to access sensitive user data (such as contacts and SMS), as well as
certain system features (such as camera and internet). Depending on the feature, the system might grant the
permission automatically or might prompt the user to approve the request. Permissions are divided into several
protection levels. The protection level affects whether runtime permission requests are required. There are three
protection levels that affect third party apps: normal, signature, and dangerous permissions. Normal permissions
cover areas where your app needs to access data or resources outside the app’s sandbox, but where there’s very little
risk to the user’s privacy or the operation of other apps. For example, permission to set the time zone is a normal
permission. If an app declares in its manifest that it needs a normal permission, the system automatically grants the
app that permission at install time. The system doesn’t prompt the user to grant normal permissions, and users
cannot revoke these permissions. Signature permissions: The system grants these app permissions at install time, but
only when the app that attempts to use permission is signed by the same certificate as the app that defines the
permission. Dangerous permissions: Dangerous permissions cover areas where the app wants data or resources that
involve the user’s private information, or could potentially affect the user’s stored data or the operation of other
apps. For example, the ability to read the user’s contacts is a dangerous permission. If an app declares that it needs a
dangerous permission, the user must explicitly grant the permission to the app. Until the user approves the
permission, your app cannot provide functionality that depends on that permission. To use a dangerous permission,
your app must prompt the user to grant permission at runtime. For more details about how the user is prompted, see
Request prompt for dangerous permission.
a) Explain with example, code to create GUI using absolute layout (Assume suitable data).
● AbsoluteLayout is based on the simple idea of placing each control at an absolute position. We specify the exact x
and y coordinates on the screen for each control. This is not recommended for most UI development (in fact
AbsoluteLayout is currently deprecated) since absolutely positioning every element on the screen makes an inflexible
UI that is much more difficult to maintain.
Absolute Layout ● An Absolute Layout lets you specify exact locations (x/y coordinates) of its children. Absolute
layouts are less flexible and harder to maintain than other types of layouts without absolute positioning.
AbsoluteLayout is based on the simple idea of placing each control at an absolute position. ● We specify for the exact
x and y corodinates on the screen for every control. So this recommended for most UI development (in fact Absolute
Layout is currentaly deprecated)since absolute positioning of every element on the screen makes an inflexible UI that
is much more difficult to maintain. ● Consider what happens if a control needs to be added to the user interface UI,
we would have to change the position of every single element that is shifted by the new control. This allows child
views to be positioned at specified X and Y coordinates within the containing layout view.
Ex.
activity_main.xml
<AbsoluteLayoutxmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<TextView
android:layout_x="110px"
android:layout_y="110px"
android:text="User Name"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<EditText
android:layout_x="250px"
android:layout_y="80px"
android:width="100px"
android:layout_width="200dp"
android:layout_height="wrap_content" />
<TextView
android:layout_x="110px" android:layout_height="wrap_content"
android:layout_y="200px" android:text="Log In"
android:text="Password" android:layout_x="300px"
android:layout_width="wrap_content" android:layout_y="300px"/>
android:layout_height="wrap_content" /> </AbsoluteLayout>
<EditText
android:layout_x="250px"
android:layout_y="150px"
android:width="100px"
android:layout_width="200dp"
android:layout_height="wrap_content" />
<Button
android:layout_width="wrap_content"

You might also like