Skip to content

Instantly share code, notes, and snippets.

@orhanobut
Last active October 14, 2015 08:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save orhanobut/f41b7617f21141284f3e to your computer and use it in GitHub Desktop.
Save orhanobut/f41b7617f21141284f3e to your computer and use it in GitHub Desktop.
final class DiskPersistence {
private final static DiskPersistence instance = new DiskPersistence();
public static DiskPersistence getInstance() {
return instance;
}
private DiskPersistence() {
// prevents to create a new instance
}
void add(String value){
// save persistent
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment