@Test public void testMarkMessagesDeleted() { Set<String> keys = new HashSet<>(); keys.add("1_message_id"); keys.add("2_message_id"); keys.add("6_message_id"); int updated = resolver.markMessagesDeleted(keys); assertEquals(keys.size(), updated); for (Message message : resolver.getMessages()) { if (!message.isDeleted()) { continue; } if (keys.contains(message.getMessageId())) { keys.remove(message.getMessageId()); } else { fail("Unexpected message marked for deletion: " + message); } } assertEquals(0, keys.size()); assertEquals(10, resolver.getMessages().size()); }
int markMessagesDeleted(@NonNull Set<String> messageIds) { ContentValues values = new ContentValues(); values.put(MessageCenterDataManager.MessageTable.COLUMN_NAME_DELETED, true); return this.updateMessages(messageIds, values); }
MessageCenterResolver extends UrbanAirshipResolver { int markMessagesDeleted(@NonNull Set<String> messageIds) { ContentValues values = new ContentValues(); values.put(MessageCenterDataManager.MessageTable.COLUMN_NAME_DELETED, true); return this.updateMessages(messageIds, values); } }
MessageCenterResolver extends UrbanAirshipResolver { int markMessagesDeleted(@NonNull Set<String> messageIds) { ContentValues values = new ContentValues(); values.put(MessageCenterDataManager.MessageTable.COLUMN_NAME_DELETED, true); return this.updateMessages(messageIds, values); } MessageCenterResolver(Context context); }
MessageCenterResolver extends UrbanAirshipResolver { int markMessagesDeleted(@NonNull Set<String> messageIds) { ContentValues values = new ContentValues(); values.put(MessageCenterDataManager.MessageTable.COLUMN_NAME_DELETED, true); return this.updateMessages(messageIds, values); } MessageCenterResolver(Context context);  }
MessageCenterResolver extends UrbanAirshipResolver { int markMessagesDeleted(@NonNull Set<String> messageIds) { ContentValues values = new ContentValues(); values.put(MessageCenterDataManager.MessageTable.COLUMN_NAME_DELETED, true); return this.updateMessages(messageIds, values); } MessageCenterResolver(Context context);   }