anotherim/src/eu/siacs/conversations/AbstractConnectionManager.java

26 lines
670 B
Java
Raw Normal View History

2014-10-13 23:06:45 +00:00
package eu.siacs.conversations;
import eu.siacs.conversations.services.XmppConnectionService;
public class AbstractConnectionManager {
protected XmppConnectionService mXmppConnectionService;
public AbstractConnectionManager(XmppConnectionService service) {
this.mXmppConnectionService = service;
}
public XmppConnectionService getXmppConnectionService() {
return this.mXmppConnectionService;
}
public long getAutoAcceptFileSize() {
String config = this.mXmppConnectionService.getPreferences().getString(
"auto_accept_file_size", "524288");
try {
return Long.parseLong(config);
} catch (NumberFormatException e) {
return 524288;
}
}
}