2010-10-03 07:08:42 -04:00
|
|
|
package com.fsck.k9.helper;
|
|
|
|
|
|
|
|
import android.content.Context;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Classes that implement this interface know how to query the system for the
|
|
|
|
* current state of the auto-sync setting. This method differs from SDK 3 to
|
2010-05-11 22:51:59 -04:00
|
|
|
* SDK 5, so there are specialized implementations for each SDK version.
|
2010-10-03 07:08:42 -04:00
|
|
|
*/
|
|
|
|
public interface IAutoSync
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* Do the necessary reflection magic to get the necessary objects and/or
|
|
|
|
* methods to later query the state of the auto-sync setting.
|
2010-05-11 22:51:59 -04:00
|
|
|
*
|
2010-10-03 07:08:42 -04:00
|
|
|
* @param context The application context object.
|
2010-05-11 22:51:59 -04:00
|
|
|
* @throws NoSuchMethodException if something went wrong.
|
2010-10-03 07:08:42 -04:00
|
|
|
*/
|
|
|
|
public void initialize(Context context) throws NoSuchMethodException;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Query the state of the auto-sync setting.
|
2010-05-11 22:51:59 -04:00
|
|
|
*
|
2010-10-03 07:08:42 -04:00
|
|
|
* @return the state of the auto-sync setting.
|
|
|
|
*/
|
|
|
|
public boolean getMasterSyncAutomatically();
|
|
|
|
}
|