private String getXmlString(CompilerElement element) throws IOException {
		CompilerSpec compilerSpec = program.getCompilerSpec();
		PcodeInjectLibrary injectLibrary = compilerSpec.getPcodeInjectLibrary();
		InjectPayload payload;
		PrototypeModel model;
		String resultString;
		if (element.status == Status.CORE) {
			XmlEncode encoder = new XmlEncode();
			switch (element.type) {
				case CALL_FIXUP:
					payload = injectLibrary.getPayload(InjectPayload.CALLFIXUP_TYPE, element.name);
					if (payload != null) {
						payload.encode(encoder);
					}
					break;
				case CALLOTHER_FIXUP:
					payload =
						injectLibrary.getPayload(InjectPayload.CALLOTHERFIXUP_TYPE, element.name);
					if (payload != null) {
						payload.encode(encoder);
					}
					break;
				case PROTOTYPE_MODEL:
				case MERGE_MODEL:
					model = compilerSpec.getCallingConvention(element.name);
					if (model != null) {
						model.encode(encoder, injectLibrary);
					}
					break;
			}
			resultString = encoder.toString();
		}
		else {
			resultString =
				SpecExtension.getCompilerSpecExtension(program, element.type, element.name);
		}
		if (resultString == null || resultString.length() == 0) {
			throw new IOException("Unable to  build document for " + element.name);
		}
		return resultString;
	}
Present a file chooser, then
   - Load the file as a String
   - Test the validity of the file as an XML document describing an extension
   - Create a new CompilerElement representing the extension OR
   - Mark an existing CompilerElement as being overwritten with the new document
Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/plugin/processors/sleigh/SpecExtensionPanel.java