The Manager constructor has been changed from:
public Manager(File dir, ManagerOptions options) throws IOException
to:
public Manager(Context context, ManagerOptions options) throws IOException
Note that the Context object passed in is a com.couchbase.lite.Context, which wraps an android.content.Context, and certain calls are simply proxied down to the wrapped android.content.Context.
The normal way to create a Manager instance now is as follows:
AndroidContext androidContext = new AndroidContext(getApplicationContext());
manager = new Manager(androidContext, Manager.DEFAULT_OPTIONS);
However, you can also customize the AndroidContext, for example you can call setNetworkReachabilityManager() to have it use your own implementation if you want to fine-tune how it reacts to Android network reachability events, or possibly disable it completely.
An example of doing that:
AndroidContext androidContext = new AndroidContext(getApplicationContext());
androidContext.setNetworkReachabilityManager(new NetworkReachabilityManager() {
@Override
public void startListening() {
// do nothing
}
@Override
public void stopListening() {
// do nothing
}
});
manager = new Manager(androidContext, Manager.DEFAULT_OPTIONS);
This has recently been pushed to the master branch, let me know if you run into problems.