Android Studio
Android Studio
Android Studio main Questions:-
1.What is Android?
Android is open source operating system and is mainly popular for Smartphone and Tablets .This operating system is Linux-Kernel based, the developer develops the functions or program which can be perform basic as well as advanced types of operations on the smartphone.
2.What is Android Architecture?
Android Architecture is made up 4 components as
a. Linux Kernel
b. Libraries
c. Android Frameworks
d. Android Applications
3.Explain Android Framework?
The Android Framework is important aspect of the Android Architecture .In this Find all class and methods that developer need in over to write application on the android environment.
4.What is AAPT?
AAPT full form is Android Asset Packaging Tools This Tools provides developers with the ability to deal with zip-compatible archives, which includes creating , extracting as well as viewing its contents.
5.Describe Activities?
Activities are what you refer to as the window to a user interface. just as you create windows in order to display output or to ask for an input in the form of dialog boxes, activities play the same role, through it may not always be in the form of a user interface.
6.What is Intents?
Intents displays notifications messages to the user from within the android enabled device. It can be used to alert the user of a particular state that occurred. Users can be made to respond to intents.
Types Of Intent:
- Implicit Intent: Implicit intent is when the target component is not defined in the intent and the android system has to evaluate the registered components based on the intent data.
- Explicit Intent: Explicit intent is when an application defines the target component directly in the intent.
7.What is AndroidManifest.xml?
This file is essential in every application.it is declared in the root directory and contains information about the application that the Android system must know before the codes can be executed.
8.Explain import packages?
- Import android.appcompat.app.AppCompatActivity : - It is Base Class For activity that wish too use some of the newer platform feature on older Android Devices.
- Import android.os.Bundle :- It is used to pass the data between Activities.
- Import android.view.View :- It is a simple rectangle the building block of application as the documentation refers to it every widget extent this class (Button , Text)
- Android EditText :- It is standard entry widget in android app it is subclass of TextView with text editing operations.
- Java.text.Decimalformat :- It is used to format numbers using a formatting pattern you specific yourself.
- import contents.Context:- Context Provides the connection to the Android system and the resources of the projects It is the interface to global information about the application environment.
- import database.Cursor :- It implementation that exposes results from a query on a SQLLiteDatabase . Thi interface provides random read-write access to the result set returned by the database query.
- import widget.Toast :-A toast is a view containing a quick little message for the user. The toast class helps you create and show those . When the view is shown to the user Appear as a floating view over the application.
8.What is APK Format?
The Android packaging key is compressed with classed , UI , supportive assets and manifest All files are compressed to a single file is called APK.
9.Which method is implemented by all subclasses of an Activity?
- OnCreate(Bundle):-It is a method where your initialization is done. Under this, you will callsetContentView(int) with a layout resource which defines your UI. Also, you can retrieve the widgets in that UI by using findViewById(Int). These are required to interact programmatically.
- onPause():- It is a method which deals with the user whenever it leaves the activity. So any changes made by the user should be commited which is done by the ContentProvider that holds the data.
10. What is the Features of Android?
- Open-source
- Customizable operating System
- Variety of apps can be developed.
- Reduces overall complexity
- Supports messaging services, web browser, storage(SQLite), connectivity ,media and many more.
11.What is the difference between an implicit intent and explicit intent?
Implicit Intent is used whenever you are performing an action for example send mail, SMS , dial number or you can use a Uri to specify the data type.
For Example:-
Intent i = new Intent(ACTION_VIEW,Uri.parse("<a href="google.com">"));
startActivity(i);
Explicit on the other hand , helps you to switch from one activity to another activity .It is also used to pass data using putExtra method and retrived by other activity by getIntent().getExtras() methods.
for Example:-
Intent i = new Intent (this, Activitytwo.class);
i.putExtra("Value1","This is ActivityTwo");
i.putExtra("Value2","This Value two for ActivityTwo");
startactivity(i);
Comments
Post a Comment