Thursday 26 December 2013

Android, Java Tutorial

Practical Interview

- Sqlite database tutorial and source code
- Json data posting on server

Note: add android library and clean buit project


http://hmkcode.com/android-simple-sqlite-database-tutorial/


Sliding menu with drawer
http://www.androidhive.info/2013/11/android-sliding-menu-using-navigation-drawer/

Action bar

http://www.androidhive.info/2013/11/android-working-with-action-bar/

Image galary

http://viralpatel.net/blogs/pick-image-from-galary-android-app/

How to start/ launch application at boot time Android

http://stackoverflow.com/questions/10428510/how-to-start-launch-application-at-boot-time-android

Endless Listview

https://github.com/survivingwithandroid/Surviving-with-android


upload file on php server

http://androidexample.com/Upload_File_To_Server_-_Android_Example/index.php?view=article_discription&aid=83&aaid=106

Good Map  v2 integration

http://ramsandroid4all.blogspot.in/2013/03/google-maps-android-api-v2.html

Androidmanifest.xml
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.example.androidapp"
    android:versionCode="1"
    android:versionName="1.0" >

    <uses-sdk
        android:minSdkVersion="10"
        android:targetSdkVersion="17" />

    <uses-feature
        android:glEsVersion="0x00020000"
        android:required="true" />

    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
    <uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES" />
    <!--
     The following two permissions are not required to use
     Google Maps Android API v2, but are recommended.
    -->
    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />

    <permission
        android:name="com.example.androidapp.permission.MAPS_RECEIVE"
        android:protectionLevel="signature" />

    <uses-permission android:name="com.example.androidapp.permission.MAPS_RECEIVE" />

    <application
        android:allowBackup="true"
        android:icon="@drawable/ic_launcher"
        android:label="@string/app_name"
        android:theme="@style/AppTheme" >
        <activity
            android:name="com.example.androidapp.MainActivity"
            android:label="@string/app_name" >
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>

        <meta-data
            android:name="com.google.android.gms.version"
            android:value="@integer/google_play_services_version" />
        <meta-data
            android:name="com.google.android.maps.v2.API_KEY"
            android:value="key" />
    </application>

</manifest>


Facebook  integration

http://stackoverflow.com/questions/16948180/login-approach-with-android-facebook-3-0-sdk


https://github.com/androidcook/Android-Cookbook-Examples


Rest web services  call from android

http://blog.enbake.com/integrating-google-maps-api-v2-with-android-application/

Get and post data using rest services
http://android-action.blogspot.in/2013/08/rest-client-api_30.html#more


Fragment example

http://bradipao.blogspot.in/2012/03/fragment-tutorial-part-2.html

Monday 23 December 2013

What are the differences between LinearLayout, RelativeLayout, and AbsoluteLayout?


FrameLayout : Layout that acts as a view frame to display a single object.
RelativeLayout :Enables you to specify the location of child objects relative to each other (child A to the left of child B) or to the parent (aligned to the top of the parent).
LinearLayout :A layout that organizes its children into a single horizontal or vertical row. It creates a scrollbar if the length of the window exceeds the length of the screen.
TableLayout :A tabular layout with an arbitrary number of rows and columns, each cell holding the widget of your choice. The rows resize to fit the largest column. The cell borders are not visible.