public synchronized void dispose() {
		if (!isCached && dbDir != null && dbDir.exists()) {
			File tmpDbDir = new File(dbDir.getParentFile(), dbDir.getName() + ".delete");
			if (!dbDir.renameTo(tmpDbDir)) {
				Msg.error(this,
					"Failed to dispose PackedDatabase - it may still be in use!\n" + packedDbFile,
					new Exception());
				return;
			}
			deleteDir(tmpDbDir);
		}
		if (dbHandle != null) {
			dbHandle = null;
			if (updateLock != null && updateLock.haveLock(true)) {
				updateLock.removeLock();
			}
		}
		if (packedDbLock != null && packedDbLock.haveLock(true)) {
			packedDbLock.removeLock();
		}
		removeInstance(this);
	}
Free resources consumed by this object.
If there is an associated database handle it will be closed.
Ghidra/Framework/FileSystem/src/main/java/ghidra/framework/store/db/PackedDatabase.java