I have a HashMap with two Strings Map<String, String> ldapContent = new HashMap<String, String>.
Now I want to save the Map in an external file to use the Map later without initializing it again…
So how must I save the Map to use it later again?
HashMapimplementsSerializableso you can use normal serialization to write hashmap to fileHere is the link for Java – Serialization example