public ScriptAttributes parseStream(InputStream stream, String scriptName) throws IOException {
		try (BufferedReader reader =
			new BufferedReader(new InputStreamReader(stream))) {
			String line;
			for (int lineNo = 1; (line = reader.readLine()) != null; lineNo++) {
				if (ignoreLine(lineNo, line)) {
					continue;
				}
				String comment = removeDelimiter(line);
				if (comment == null) {
					break;
				}
				parseComment(new Location(scriptName, lineNo), comment);
			}
			return validate(scriptName);
		}
	}
Parse the header from the give input stream

@param stream the stream from of the input stream file
@param scriptName the name of the script file
@return the parsed attributes
@throws IOException if there was an issue reading the stream
Ghidra/Debug/Debugger-rmi-trace/src/main/java/ghidra/app/plugin/core/debug/gui/tracermi/launcher/ScriptAttributesParser.java