mirror of
https://github.com/oxen-io/session-android.git
synced 2025-08-11 15:07:46 +00:00
fix: fixing up LokiMessageDatabase.kt table structure, deletion closer to finished
This commit is contained in:
@@ -3,5 +3,5 @@ package org.session.libsignal.service.loki.database
|
||||
interface LokiMessageDatabaseProtocol {
|
||||
|
||||
fun getQuoteServerID(quoteID: Long, quoteePublicKey: String): Long?
|
||||
fun setServerID(messageID: Long, serverID: Long)
|
||||
fun setServerID(messageID: Long, serverID: Long, isSms: Boolean)
|
||||
}
|
||||
|
@@ -3,8 +3,10 @@ package org.session.libsignal.utilities;
|
||||
import com.fasterxml.jackson.core.JsonGenerator;
|
||||
import com.fasterxml.jackson.core.JsonParser;
|
||||
import com.fasterxml.jackson.core.JsonProcessingException;
|
||||
import com.fasterxml.jackson.core.type.ResolvedType;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import com.fasterxml.jackson.databind.DeserializationFeature;
|
||||
import com.fasterxml.jackson.databind.JavaType;
|
||||
import com.fasterxml.jackson.databind.JsonDeserializer;
|
||||
import com.fasterxml.jackson.databind.JsonNode;
|
||||
import com.fasterxml.jackson.databind.JsonSerializer;
|
||||
@@ -42,6 +44,10 @@ public class JsonUtil {
|
||||
return objectMapper.readValue(serialized, clazz);
|
||||
}
|
||||
|
||||
public static<T> T fromJson(String serialized, JavaType clazz) throws IOException {
|
||||
return objectMapper.readValue(serialized, clazz);
|
||||
}
|
||||
|
||||
public static <T> T fromJson(InputStream serialized, Class<T> clazz) throws IOException {
|
||||
return objectMapper.readValue(serialized, clazz);
|
||||
}
|
||||
|
Reference in New Issue
Block a user