public DataType parse(String dataTypeString, DataType suggestedBaseDataType)
			throws InvalidDataTypeException, CancelledException {
		dataTypeString = dataTypeString.replaceAll("\\s+", " ").trim();
		String dataTypeName = getBaseString(dataTypeString);
		if (StringUtils.isBlank(dataTypeName)) {
			throw new InvalidDataTypeException("missing base data-type name");
		}

		DataType namedDt;
		if (suggestedBaseDataType != null && dataTypeName.equals(suggestedBaseDataType.getName())) {
			namedDt = suggestedBaseDataType;
			if (namedDt.getDataTypeManager() != destinationDataTypeManager) {
				namedDt = namedDt.clone(destinationDataTypeManager);
			}
		}
		else {
			namedDt = getNamedDataType(dataTypeName, null);
			if (namedDt == null) {
				throw new InvalidDataTypeException("valid data-type not specified");
			}
		}

		return parseDataTypeModifiers(namedDt, dataTypeString.substring(dataTypeName.length()));
	}
Parse a data type string specification using the specified baseDatatype.

@param suggestedBaseDataType base data type (may be null), this will be used as the base 
       data-type if its name matches the base name in the specified dataTypeString.
@param dataTypeString a base data-type followed by a sequence of zero or more pointer/array 
       decorations to be applied.
The string may start with the baseDataType's name.
@return parsed data-type or null if not found
@throws InvalidDataTypeException if data-type string is invalid or length exceeds specified 
        maxSize
@throws CancelledException parse cancelled through user interaction (only if parser 
        constructed with service)
Ghidra/Features/Base/src/main/java/ghidra/util/data/DataTypeParser.java