public void decode(Decoder decoder, DecisionNode par, SubtableSymbol sub)
			throws DecoderException {
		int el = decoder.openElement(ELEM_DECISION);

		contextdecision = decoder.readBool(ATTRIB_CONTEXT);
		startbit = (int) decoder.readSignedInteger(ATTRIB_STARTBIT);
		bitsize = (int) decoder.readSignedInteger(ATTRIB_SIZE);

		ArrayList<Object> patlist = new ArrayList<>();
		ArrayList<Object> conlist = new ArrayList<>();
		ArrayList<Object> childlist = new ArrayList<>();
//		num = 0;
		int subel = decoder.peekElement();
		while (subel != 0) {
			if (subel == ELEM_PAIR.id()) {
				decoder.openElement();
				int id = (int) decoder.readSignedInteger(ATTRIB_ID);
				conlist.add(sub.getConstructor(id));
				patlist.add(DisjointPattern.decodeDisjoint(decoder));
				decoder.closeElement(subel);
			}
			else if (subel == ELEM_DECISION.id()) {
				DecisionNode subnode = new DecisionNode();
				subnode.decode(decoder, this, sub);
				childlist.add(subnode);
			}
			subel = decoder.peekElement();
		}
		patternlist = new DisjointPattern[patlist.size()];
		patlist.toArray(patternlist);
		constructlist = new Constructor[conlist.size()];
		conlist.toArray(constructlist);
		children = new DecisionNode[childlist.size()];
		childlist.toArray(children);
		decoder.closeElement(el);

		unmodifiablePatternList = Collections.unmodifiableList(Arrays.asList(patternlist));
		unmodifiableConstructorList = Collections.unmodifiableList(Arrays.asList(constructlist));
		unmodifiableChildren = Collections.unmodifiableList(Arrays.asList(children));
	}
//   * NOTE! Do not delete this method even if commented-out!
//	 * Test method to discover where a particular mnemonic constructor exists.
//	 * within the parse tree.
//   * This method relies on TestEnv which is inappropriate for a production core class. 
//	 * @param node 
//	 * @param name
//	 * @param path
//
Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/plugin/processors/sleigh/DecisionNode.java