private AddressFactory parseAddressSpaces(Element element) throws SAXException {
		AddressSpace defaultSpace = null;
		List<AddressSpace> list = new ArrayList<AddressSpace>();
		List<?> children = element.getChildren();
		Iterator<?> iter = children.iterator();
		int unique = 0; // used by old address map
		while (iter.hasNext()) {
			Element childElement = (Element) iter.next();
			String elementName = childElement.getName();

			if (!"space".equals(elementName) && !"segmented_space".equals(elementName)) {
				throw new SAXException("Unsupported spaces element '" + elementName + "'");
			}
			AddressSpace space;
			String name = childElement.getAttributeValue("name");
			if (name == null) {
				throw new SAXException("Missing required space 'name' attribute");
			}
			String valStr = childElement.getAttributeValue("unique");
			if (valStr != null) {
				try {
					unique = XmlUtilities.parseInt(valStr);
				}
				catch (NumberFormatException e) {
					throw new SAXException("bad attribute value unique=\"" + valStr + "\"");
				}
			}

			if ("segmented_space".equals(elementName)) {
				String segmentType = childElement.getAttributeValue("type");
				if (segmentType == null) {
					throw new SAXException("Missing required segmented_space 'type' attribute");
				}
				if (segmentType.equals("protected")) {
					space = new ProtectedAddressSpace(name, unique);
				}
				else {
					space = new SegmentedAddressSpace(name, unique);
				}
			}
			else {
				String typeStr = childElement.getAttributeValue("type");
				if (typeStr == null) {
					throw new SAXException("Missing required space 'type' attribute");
				}
				int type;
				if ("ram".equalsIgnoreCase(typeStr)) {
					type = AddressSpace.TYPE_RAM;
				}
				else if ("code".equalsIgnoreCase(typeStr)) {
					type = AddressSpace.TYPE_CODE;
				}
				else if ("register".equalsIgnoreCase(typeStr)) {
					type = AddressSpace.TYPE_REGISTER;
				}
				else {
					throw new SAXException("unsupported space type: " + typeStr);
				}
				int size = parseIntAttribute(childElement, "size");
				int wordsize = 1;
				if (childElement.getAttribute("wordsize") != null) {
					wordsize = parseIntAttribute(childElement, "wordsize");
				}
				space = new GenericAddressSpace(name, 8 * size, wordsize, type, unique);
			}
			list.add(space);
			boolean isDefault = parseBooleanAttribute(childElement, "default", Boolean.FALSE);
			if (isDefault) {
				if (defaultSpace != null) {
					throw new SAXException("only one default space may be specified");
				}
				defaultSpace = space;
			}
			++unique;
		}
		if (defaultSpace == null) {
			throw new SAXException("default address space not specified");
		}
		AddressSpace[] spaces = new AddressSpace[list.size()];
		list.toArray(spaces);
		return new DefaultAddressFactory(spaces, defaultSpace);
	}
Returns language description associated with this old language.
Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/util/OldLanguage.java