Android Open Source - Tiny-Journal Sync Service






From Project

Back to project page Tiny-Journal.

License

The source code is released under:

GNU General Public License

If you think the Android project Tiny-Journal 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.ubergrund.android.tinyjournal;
/*from w w w .  j  ava  2s .  com*/
import android.app.Service;
import android.content.Intent;
import android.os.IBinder;

/**
 * Created with IntelliJ IDEA.
 * User: Tim
 * Date: 10/28/13
 * Time: 6:40 AM
 */
public class SyncService extends Service {

    private static final String TAG = "TinyJournal/SyncService";

    private static JournalSyncAdapter syncAdapter = null;
    private static final Object syncAdapterMonitor = new Object();

    @Override
    public void onCreate() {
        super.onCreate();

        synchronized (syncAdapterMonitor) {
            if (syncAdapter == null)
                syncAdapter = new JournalSyncAdapter(getApplicationContext(), true);
        }
    }


    public IBinder onBind(Intent intent) {
        return syncAdapter.getSyncAdapterBinder();
    }

}




Java Source Code List

com.ubergrund.android.tinyjournal.AuthenticatorService.java
com.ubergrund.android.tinyjournal.JournalAuthenticator.java
com.ubergrund.android.tinyjournal.JournalContentProvider.java
com.ubergrund.android.tinyjournal.JournalSyncAdapter.java
com.ubergrund.android.tinyjournal.MyActivity.java
com.ubergrund.android.tinyjournal.SyncService.java