session-android/src/org/thoughtcrime/securesms/logging/CustomSignalProtocolLogger.java
Greyson Parrelli acb40c6133 Added new logger.
Added a new logger that persists logs for a longer duration to the
user's cache directory. Logs are encrypted. The new logs are sent
in addition to the user's logcat output.
2018-08-06 10:50:06 -04:00

30 lines
671 B
Java

package org.thoughtcrime.securesms.logging;
import org.whispersystems.libsignal.logging.SignalProtocolLogger;
public class CustomSignalProtocolLogger implements SignalProtocolLogger {
@Override
public void log(int priority, String tag, String message) {
switch (priority) {
case VERBOSE:
Log.v(tag, message);
break;
case DEBUG:
Log.d(tag, message);
break;
case INFO:
Log.i(tag, message);
break;
case WARN:
Log.w(tag, message);
break;
case ERROR:
Log.e(tag, message);
break;
case ASSERT:
Log.wtf(tag, message);
break;
}
}
}