public static String parseIndex(String key) {
		if (isIndex(key)) {
			return key.substring(1, key.length() - 1);
		}
		throw new IllegalArgumentException("Index keys must be of the form '[index]'. Got " + key);
	}
Parse an index value from a key

<p>
Where key is the form {@code [index]}, this merely returns {@code index}.

@param key the key
@return the index
@throws IllegalArgumentException if key is not of the required form
Ghidra/Debug/Framework-TraceModeling/src/main/java/ghidra/trace/model/target/path/KeyPath.java