public int getLength(Memory memory, Address startAddress) {
		Program program = memory.getProgram();
		int preNameLength = getNameOffset(program);
		int totalLength = preNameLength;
		// Add the length of the name string too if we can get it.
		Address nameAddress = startAddress.add(preNameLength);
		TerminatedStringDataType terminatedStringDt =
			new TerminatedStringDataType(program.getDataTypeManager());
		DumbMemBufferImpl nameMemBuffer = new DumbMemBufferImpl(memory, nameAddress);
		int nameLength =
			terminatedStringDt.getLength(nameMemBuffer, StringDataInstance.MAX_STRING_LENGTH);
		if (nameLength <= 0) {
			return 0; // Can't get name, so return 0 for invalid.
		}
		totalLength += nameLength;
		// Add on bytes for alignment at the end.
		int alignment = getAlignment();
		int mod = totalLength % alignment;
		if (mod != 0) {
			int numAlignBytes = alignment - mod;
			totalLength += numAlignBytes;
		}
		return totalLength;
	}
Gets the total length of the data created when this data type is placed at the indicated
address in memory.
@param memory the program memory for this data.
@param startAddress the start address of the data.
@return the length of the data. zero is returned if valid data can't be created at the
indicated address using this data type.
Ghidra/Features/Base/src/main/java/ghidra/app/util/datatype/microsoft/RTTI0DataType.java