default <T> T metadata(@NonNull NodeMetadataKey<T> key) throws IllegalStateException {
        return getMetadata(key).orElseThrow(() -> new IllegalStateException("Node '" + getKey() + "' does not have '" + key.name() + "' attached."));
    }
Gets the metadata corresponding to the given <code>key</code>, throwing an exception
if no data is present.

@param key the key
@param <T> the metadata type
@return the data
@throws IllegalStateException if data isn't present
api/src/main/java/net/luckperms/api/node/Node.java