Friday, 21 October 2016

Store your own app on Google Play Store


Store Your own App On Google Play Store


How to put your app in Play Store

if you're creating an application that you want to distribute to public , the best way to do so is to upload you application to GooglePlay . Google has help specifically aimed at developers. its great ref. Google play for Developers Help . There is also a very useful document entitled: Publish CheakList for Google Play . that discusses what is requered  to publist Google Play.

For in depth walk though of Google Play. Please read Publishing 

Register For Google Play.


The first step in publishing is to register for Goole Play . at the Google Play Publisher . The Process is relatively straightforword and should only take you a few minutes. 

Note : There is 25$ (1500 rs) charge to register. 

Are You Going to Sell Your App ?

if you want to sell app, instance of offering them for free with adsyou also need set up a Google Wallet Merchant account as described in the Getting starte with publishing



Uplode an App

After you've signed up for a Google Play Developer account , you can upload apps to Google Play Developer Console.


Add an Apk

  1. Go to your Google Play Developer Console
  2. Select All Application > Add new Application.
  3. Using the drop down menu , select a default language and add title fot your app as you wqant it to appear in Goole Play.
  4. Select Upload Apk.
  5. Chose the production , Beta,ot Alpha channels and Upload you Apk . For more info. on alpha/beta testing , go to use alpha/beta testing & staged rollouts .

Manage APK files 

package names for app files are unique and permanent so pleasename them carefully . package name cant be deleted or reused in future.












Next Step





- Mahesh Kailash Saraswat

Wednesday, 19 October 2016

Android MVC , MVP , MVVM


    MVC , MVP , MVVM 



   In this blog i am disscussing about Model View Controller (MVC), Model View Presenter (MVP) and Model View-View Model



Model View Controller (MVC) 


                           MVC design pattern splits an application into 3 part : Model , View , Controler























View :
              Component  dairectly intracy with user and is responsible for how user going to see our application, In MVC , Xml treated as view.

Model :  
               Model is the data source for application and main bussiness logic is defined here. It contail data objects that are used in application and is show to user . data sorce can be web , local bussiness (Sqlite) etc.                

Controller :
              Controller is responsible to process incoming request. It receives input from users vie the View, Then proces the User data with the help of Model and passing the result  back to view . Typically , it act as the coordinator between view and model.


Model View Presenter

This is similer to MVC pattern in which controller has been replaced by presenter. 


Model :
              The Model represent a set of classes that describes the business logic and data. also define business rules for data means how the datacan be changed and manipulated.

View :
          The view represent the ui componunts. its only responcible for displaying data that is received from the presenter as the result this also transforms the model(s) into UI.

Presenter :
            The presenter is responsible for handling all UI events on behalf of the view. This receive input from user vie View, then process the User data with the help of model and passing the results back to the View. Unlike View and Controler and presenter are completly decoupled from each other's and communicate to each other's by an a interface.

Also, preseter does not manage the incoming request traffic as controller.


Key Point about MVP Pattern

  • User interface with View.
  • There is one to one relationship between View and Presenter means one View is mapped to only one Presenter.
  • View has a reference  to Presenter but View has nor reference to Model.
  • Provied Two way communication between View and Presenter.

Model View ViewModel

                           This pattern supports two-way data binding between view and View Model. This enables automatic propogation of changes , within the state of View . Typicaly, the View model uses the observe pattern to notify changes in the view model to model.


Model :
           As descuss above same info follow above.

View :
           As descuss above same info. follow above.

View Model :
           The ViewModel is responsible for exposing method, commands , and othe properties thats help to maintain the stage of view , manupulate the model as the result of action on the view, and trigger event in view itself.

Key point about MVVMPattern

  • User interact with View.
  • There is many-to-onr relationship between View and ViewModel means many View can be mapped to one ViewModel.
  • view has refrance to ViewModel but ViewModel no Information about view
  • Supports two-way data binding between View andViewModel.


ref. from 






-Mahesh Kailash Saraswat

            

              

Tuesday, 18 October 2016

Splash Screen code Android

This Blog for beginer. i am showing you simple code of splash screen

Inside the Anctivity OnCreate Method


//this is used for hide action bar

getSupportActionBar().hide();


//After that we are chaking sharedPrefrance for user is already loged in or not. if loged in then home activity open other wise login

SharedPreferences mCheak=getSharePreferences("CheakLogIn", Context.MODE_PRIVATE);
String Name=mCheak.getString("Name","");


//Handler is used for autometicaly after some second activity call

Handler h= new Handler();

Runnable r = new Runnable ()
{

    @override
    public void run()
       {

//here we cheak if name is null login page open else home page

           if(Name.equals(" "))
          {
                  Intent i= new Intent(getApplicationContext (), Activity_LogIn.class);
                    startActivity(i);
                    finish();

          }else

               {
                    Intent i=new Intent(getApplicationContext(),Activity_Home.Class);
                    startActivity(i)
                    finish();

             }
  
      }

};

h.postDelayed(r,3000);        // 3000 is mili second means 3 second





- Mahesh Saraswat