private void encodeAbstractIntegerDataType(Encoder encoder, AbstractIntegerDataType type,
			int size) throws IOException {
		encoder.openElement(ELEM_TYPE);
		boolean signed = type.isSigned();
		int sz = type.getLength();
		if (sz <= 0) {
			sz = size;
		}
		encodeNameIdAttributes(encoder, type);
		encoder.writeString(ATTRIB_METATYPE, signed ? "int" : "uint");
		encoder.writeSignedInteger(ATTRIB_SIZE, sz);
		encoder.closeElement(ELEM_TYPE);
	}
Encode an integer data-type to the stream
@param encoder is the stream encoder
@param type is the integer data-type
@param size if non-zero, is the size of the data-type in context
@throws IOException for errors in the underlying stream
Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/pcode/PcodeDataTypeManager.java