DefaultProjectData getLocalProjectData(boolean readOnlyAccess) throws IOException {
		if (connect(readOnlyAccess) != StatusCode.OK) {
			return null;
		}

		try {
			return new DefaultProjectData(localStorageLocator, !readOnlyAccess, false);
		}
		catch (NotOwnerException | ReadOnlyException e) {
			statusCode = StatusCode.UNAUTHORIZED;
		}
		catch (LockException e) {
			statusCode = StatusCode.LOCKED;
		}
		return null;
	}
Connect and establish a local project data instance.  Opening a project for
write access is subject to in-use lock restriction.
See {@link #getStatusCode()} if null is returned.
@param readOnlyAccess true if project data should be read-only
@return project data instance or null if project not found
@throws IOException if IO error occurs
Ghidra/Framework/Project/src/main/java/ghidra/framework/protocol/ghidra/DefaultLocalGhidraProtocolConnector.java