Recover Eclipse editing session

If Windows crashes while you have a document open in Eclipse, you may find that the contents are cleared when you get back in.

To fix this, locate your workspace.

Then find .metadata/.plugins/org.eclipse.core.resources/.history/

Sort the folders by date. Find the most recent.

Open the folder contents in an editor like Sublime Text.