Android Open Source - AndroidFinally Service On Start Command

From Project

Back to project page AndroidFinally.


The source code is released under:

GNU General Public License

If you think the Android project AndroidFinally listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package com.example.androidfinallyapp;
/*from  w  w  w.j  a v  a 2 s . com*/
import android.content.Intent;
import android.os.IBinder;
import android.util.Log;

public class ServiceOnStartCommand extends Service {

  private static final String TAG = "ServiceOnStartCommand";

  public IBinder onBind(Intent intent) {
    // TODO Auto-generated method stub
    Log.i(TAG, "at onBind");
    return null;

  public void onCreate() {
    // TODO Auto-generated method stub
    Log.i(TAG, "at onCreate");

  public int onStartCommand(Intent intent, int flags, int startId) {
    // TODO Auto-generated method stub
    Log.i(TAG, "at onStartCommand");
    return super.onStartCommand(intent, flags, startId);


  public void onDestroy() {
    // TODO Auto-generated method stub
    Log.i(TAG,"at onDestroy");


Java Source Code List