public void encode(Encoder encoder, DecompInterface iface) throws IOException {
		encoder.openElement(ELEM_OPTIONSLIST);
		if (predicate != PREDICATE_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_CURRENTACTION, "conditionalexe", predicate ? "on" : "off",
				"");
		}
		if (eliminateUnreachable != ELIMINATE_UNREACHABLE_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_CURRENTACTION, iface.getSimplificationStyle(), "unreachable",
				eliminateUnreachable ? "on" : "off");
		}
		if (simplifyDoublePrecision != SIMPLIFY_DOUBLEPRECISION_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_CURRENTACTION, iface.getSimplificationStyle(),
				"doubleprecis", simplifyDoublePrecision ? "on" : "off");
		}
		if (splitStructures != SPLITSTRUCTURES_OPTIONDEFAULT ||
			splitArrays != SPLITARRAYS_OPTIONDEFAULT ||
			splitPointers != SPLITPOINTERS_OPTIONDEFAULT) {
			String p1 = splitStructures ? "struct" : "";
			String p2 = splitArrays ? "array" : "";
			String p3 = splitPointers ? "pointer" : "";
			appendOption(encoder, ELEM_SPLITDATATYPE, p1, p2, p3);
		}
		if (nanIgnore != NANIGNORE_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_NANIGNORE, nanIgnore.getOptionString(), "", "");
		}

		appendOption(encoder, ELEM_READONLY, readOnly ? "on" : "off", "", "");
		// Must set language early so that the object is in place before other option changes
		appendOption(encoder, ELEM_SETLANGUAGE, displayLanguage.toString(), "", "");

		if (ignoreunimpl != IGNOREUNIMPL_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_IGNOREUNIMPLEMENTED, ignoreunimpl ? "on" : "off", "", "");
		}
		if (inferconstptr != INFERCONSTPTR_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_INFERCONSTPTR, inferconstptr ? "on" : "off", "", "");
		}
		if (analyzeForLoops != ANALYZEFORLOOPS_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_ANALYZEFORLOOPS, analyzeForLoops ? "on" : "off", "", "");
		}
		if (nullToken != NULLTOKEN_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_NULLPRINTING, nullToken ? "on" : "off", "", "");
		}
		if (inplaceTokens != INPLACEOP_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_INPLACEOPS, inplaceTokens ? "on" : "off", "", "");
		}
		if (aliasBlock != ALIASBLOCK_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_ALIASBLOCK, aliasBlock.getOptionString(), "", "");
		}
		if (conventionPrint != CONVENTION_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_CONVENTIONPRINTING, conventionPrint ? "on" : "off", "", "");
		}
		if (noCastPrint != NOCAST_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_NOCASTPRINTING, noCastPrint ? "on" : "off", "", "");
		}
		if (braceFunction != BRACEFUNCTION_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_BRACEFORMAT, "function", braceFunction.getOptionString(),
				"");
		}
		if (braceIfElse != BRACEIFELSE_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_BRACEFORMAT, "ifelse", braceIfElse.getOptionString(), "");
		}
		if (braceLoop != BRACELOOP_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_BRACEFORMAT, "loop", braceLoop.getOptionString(), "");
		}
		if (braceSwitch != BRACESWITCH_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_BRACEFORMAT, "switch", braceSwitch.getOptionString(), "");
		}
		if (maxwidth != MAXWIDTH_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_MAXLINEWIDTH, Integer.toString(maxwidth), "", "");
		}
		if (indentwidth != INDENTWIDTH_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_INDENTINCREMENT, Integer.toString(indentwidth), "", "");
		}
		if (commentindent != COMMENTINDENT_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_COMMENTINDENT, Integer.toString(commentindent), "", "");
		}
		if (commentStyle != COMMENTSTYLE_OPTIONDEFAULT) {
			String curstyle = CommentStyleEnum.CPPStyle.equals(commentStyle) ? "cplusplus" : "c";
			appendOption(encoder, ELEM_COMMENTSTYLE, curstyle, "", "");
		}
		if (commentPLATEInclude != COMMENTPLATE_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_COMMENTINSTRUCTION, "header",
				commentPLATEInclude ? "on" : "off", "");
		}
		if (commentPREInclude != COMMENTPRE_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_COMMENTINSTRUCTION, "user2",
				commentPREInclude ? "on" : "off", "");
		}
		if (commentEOLInclude != COMMENTEOL_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_COMMENTINSTRUCTION, "user1",
				commentEOLInclude ? "on" : "off", "");
		}
		if (commentPOSTInclude != COMMENTPOST_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_COMMENTINSTRUCTION, "user3",
				commentPOSTInclude ? "on" : "off", "");
		}
		if (commentWARNInclude != COMMENTWARN_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_COMMENTINSTRUCTION, "warning",
				commentWARNInclude ? "on" : "off", "");
		}
		if (commentHeadInclude != COMMENTHEAD_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_COMMENTHEADER, "header", commentHeadInclude ? "on" : "off",
				"");
		}
		if (commentWARNInclude != COMMENTWARN_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_COMMENTHEADER, "warningheader",
				commentWARNInclude ? "on" : "off", "");
		}
		if (namespaceStrategy != NAMESPACE_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_NAMESPACESTRATEGY, namespaceStrategy.getOptionString(), "",
				"");
		}
		if (integerFormat != INTEGERFORMAT_OPTIONDEFAULT) {
			appendOption(encoder, ELEM_INTEGERFORMAT, integerFormat.getOptionString(), "", "");
		}
		if (maxIntructionsPer != SUGGESTED_MAX_INSTRUCTIONS) {
			appendOption(encoder, ELEM_MAXINSTRUCTION, Integer.toString(maxIntructionsPer), "", "");
		}
		if (maxJumpTableEntries != SUGGESTED_MAX_JUMPTABLE_ENTRIES) {
			appendOption(encoder, ELEM_JUMPTABLEMAX, Integer.toString(maxJumpTableEntries), "", "");
		}
		appendOption(encoder, ELEM_PROTOEVAL, protoEvalModel, "", "");
		encoder.closeElement(ELEM_OPTIONSLIST);
	}
Encode all the configuration options to a stream for the decompiler process.
This object is global to all decompile processes so we can tailor to the specific process
by passing in the interface.
@param encoder is the stream encoder
@param iface  specific DecompInterface being sent options
@throws IOException for errors writing to the underlying stream
Ghidra/Features/Decompiler/src/main/java/ghidra/app/decompiler/DecompileOptions.java