Java tutorial
//package com.java2s; import java.net.URI; public class Main { public static final String dereference(String idRef) { URI uri = URI.create(idRef); String part = uri.getSchemeSpecificPart(); if (part != null && part.length() > 0) { throw new UnsupportedOperationException( "modlur does not support external sources (" + uri.toString() + ")"); } return uri.getFragment(); } }