Commit 747fb401 authored by Ajit Deshmukh's avatar Ajit Deshmukh

Upload New File

parent 73528bf2
package ibase.communication.whatsApp;
import java.util.HashMap;
public class ChatDataManager {
private static HashMap<String, HashMap<String, Object>> chatDataMap = new HashMap<>();
static synchronized HashMap<String, Object> getChatData(String chatId) {
// Retrieve chat-specific data from HashMap
return chatDataMap.computeIfAbsent(chatId, k -> new HashMap<>());
}
static synchronized void removeChatData(String chatId) {
// Remove chat-specific data from HashMap after processing
chatDataMap.remove(chatId);
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment