Hi there,
I have this method which stores some actions that have change a text in a JTextPane
private void createActionTable(JTextComponent textComponent) {
actions = new HashMap();
Action[] actionsArray = textComponent.getActions();
for (int i = 0; i < actionsArray.length; i++) {
Action a = actionsArray;
actions.put(a.getValue(Action.NAME), a);
}
}
this comes from the example provided from sun which is here
http://java.sun.com/docs/books/tutorial/uiswing/components/generaltext.html
I want somehow to store the text changes in a database so when I open the program again to be able to load them and I don't how. I was thinking to store the HashMap above but I don't know if it is possible or if you have a better solution.
Thanks