@Nonnull
	static String workspaceInput(@Nonnull Workspace workspace) {
		// The workspace hashCode reflects the state of its contents (which updates as the user makes changes)
		// We want to generate a key based on some info that is consistent and re-producible over time.
		// Ideally we can get a sort of 'source' of the loaded content from each primary resource of the given workspace.
		WorkspaceResource resource = workspace.getPrimaryResource();
		if (resource instanceof WorkspaceFileResource fileResource) {
			// Hash based on file path of input, or file name if full path not known.
			FileInfo fileInfo = fileResource.getFileInfo();
			Path path = InputFilePathProperty.get(fileInfo);
			return path == null ? fileInfo.getName() : path.toString();
		} else if (resource instanceof WorkspaceDirectoryResource directoryResource) {
			// Hash based on directory path of input.
			return directoryResource.getDirectoryPath().toString();
		} else if (resource instanceof WorkspaceRemoteVmResource remoteVmResource) {
			// Hash based on VM id, which is generally consistent when re-running the same application.
			return remoteVmResource.getVirtualMachine().id();
		}

		// Unsupported workspace content.
		return "unknown-workspace";
	}
@param workspace
		Workspace instance.

@return Path of input from workspace.
recaf-core/src/main/java/software/coley/recaf/services/comment/CommentKey.java