
public class DatabaseImpl 
implements Database {

	// add private data member
	private static Database m_singleton = null;
			
	// make this private
	private DatabaseImpl () {
		System.out.println("constructor");
	}

	// this is the method that will be invoked to instantiate a DatabaseImpl object
	// if one does not already exist, it will create one
	// if one does already exist, it will just return it
	public static Database getInstance() {
		if (m_singleton == null) {
			m_singleton = new DatabaseImpl();
		}
		return (m_singleton);
	}
	
	public void open() {
		System.out.println("open()");
	}

	public void close() {
		System.out.println("close()");
	}

	
}
