public void grabTokens(List<String> tokens) {
			String escaped = removeEscapeChars(text);
			String[] strings = escaped.split("\\s");
			for (String string : strings) {
				// 0 length strings can happen when 'content' begins with a space
				if (string.length() > 0) {
					tokens.add(string);
				}
			}
		}
A simple class to hold text and extract tokens
Ghidra/Features/Base/src/main/java/ghidra/app/util/viewer/field/Annotation.java