Android Open Source - Sunshine Sunshine Sync Service






From Project

Back to project page Sunshine.

License

The source code is released under:

MIT License

If you think the Android project Sunshine 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 cloudchen.com.sunshine.sync;
//w  w w . j  av  a 2s.  co  m
import android.app.Service;
import android.content.Intent;
import android.os.IBinder;
import android.util.Log;

public class SunshineSyncService extends Service {
    private static final Object sSyncAdapterLock = new Object();
    private static SunshineSyncAdapter sSunshineSyncAdapter = null;

    @Override
    public void onCreate() {
        Log.d("SunshineSyncService", "onCreate - SunshineSyncService");
        synchronized (sSyncAdapterLock) {
            if (sSunshineSyncAdapter == null) {
                sSunshineSyncAdapter = new SunshineSyncAdapter(getApplicationContext(), true);
            }
        }
    }

    @Override
    public IBinder onBind(Intent intent) {
        return sSunshineSyncAdapter.getSyncAdapterBinder();
    }
}




Java Source Code List

cloudchen.com.sunshine.ApplicationTest.java
cloudchen.com.sunshine.DetailActivity.java
cloudchen.com.sunshine.DetailFragment.java
cloudchen.com.sunshine.ForecastAdapter.java
cloudchen.com.sunshine.ForecastFragment.java
cloudchen.com.sunshine.FullTestSuite.java
cloudchen.com.sunshine.MainActivity.java
cloudchen.com.sunshine.SettingsActivity.java
cloudchen.com.sunshine.TestDb.java
cloudchen.com.sunshine.TestProvider.java
cloudchen.com.sunshine.Utility.java
cloudchen.com.sunshine.data.WeatherContract.java
cloudchen.com.sunshine.data.WeatherDbHelper.java
cloudchen.com.sunshine.data.WeatherProvider.java
cloudchen.com.sunshine.sync.SunshineAuthenticatorService.java
cloudchen.com.sunshine.sync.SunshineAuthenticator.java
cloudchen.com.sunshine.sync.SunshineSyncAdapter.java
cloudchen.com.sunshine.sync.SunshineSyncService.java