use of com.android.voicemail.impl.mail.store.ImapConnection in project android_packages_apps_Dialer by LineageOS.
the class ImapHelper method changeVoicemailTuiLanguage.
public void changeVoicemailTuiLanguage(String languageCode) throws MessagingException {
ImapConnection connection = imapStore.getConnection();
try {
String command = getConfig().getProtocol().getCommand(OmtpConstants.IMAP_CHANGE_VM_LANG_FORMAT);
connection.sendCommand(String.format(Locale.US, command, languageCode), true);
} catch (IOException ioe) {
LogUtils.e(TAG, ioe.toString());
} finally {
connection.destroyResponses();
}
}
use of com.android.voicemail.impl.mail.store.ImapConnection in project android_packages_apps_Dialer by LineageOS.
the class ImapHelper method closeNewUserTutorial.
public void closeNewUserTutorial() throws MessagingException {
ImapConnection connection = imapStore.getConnection();
try {
String command = getConfig().getProtocol().getCommand(OmtpConstants.IMAP_CLOSE_NUT);
connection.executeSimpleCommand(command, false);
} catch (IOException ioe) {
throw new MessagingException(MessagingException.SERVER_ERROR, ioe.toString());
} finally {
connection.destroyResponses();
}
}
use of com.android.voicemail.impl.mail.store.ImapConnection in project android_packages_apps_Dialer by LineageOS.
the class ImapHelper method changePin.
@ChangePinResult
public int changePin(String oldPin, String newPin) throws MessagingException {
ImapConnection connection = imapStore.getConnection();
try {
String command = getConfig().getProtocol().getCommand(OmtpConstants.IMAP_CHANGE_TUI_PWD_FORMAT);
connection.sendCommand(String.format(Locale.US, command, newPin, oldPin), true);
return getChangePinResultFromImapResponse(connection.readResponse());
} catch (IOException ioe) {
VvmLog.e(TAG, "changePin: ", ioe);
return PinChanger.CHANGE_PIN_SYSTEM_ERROR;
} finally {
connection.destroyResponses();
}
}
Aggregations