final String currLoadedDoc = context.getSystemId();
String currLoadedDoc = context.getSystemId();
    public void parseContents(final Parser parser) {	final Stylesheet context = parser.getCurrentStylesheet();	try {	    String docToLoad = getAttribute("href");	    if (context.checkForLoop(docToLoad)) {		final int errno = ErrorMsg.CIRCULAR_INC;		final ErrorMsg msg = new ErrorMsg(errno, docToLoad, this);		parser.reportError(Constants.FATAL, msg);		return;	    }	    final String currLoadedDoc = context.getSystemId();	    SourceLoader loader = context.getSourceLoader();	    InputSource input = null;	    if (loader != null) {		final XSLTC xsltc = parser.getXSLTC();		input = loader.loadSource(docToLoad, currLoadedDoc, xsltc);	    }	    else {		final URL url = new URL(new URL(currLoadedDoc), docToLoad);		docToLoad = url.toString();		input = new InputSource(docToLoad);	    }	    final SyntaxTreeNode root = parser.parse(input);	    if (root == null) return;	    final Stylesheet _included = parser.makeStylesheet(root);	    if (_included == null) return;	    _included.setSourceLoader(loader);	    _included.setSystemId(docToLoad);	    _included.setParentStylesheet(context);	    _included.setIncludingStylesheet(context);	    // An included stylesheet gets the same import precedence	    // as the stylesheet that included it.	    final int precedence = context.getImportPrecedence();	    _included.setImportPrecedence(precedence);	    parser.setCurrentStylesheet(_included);	    _included.parseContents(parser);	    final Enumeration elements = _included.elements();	    final Stylesheet topStylesheet = parser.getTopLevelStylesheet();	    while (elements.hasMoreElements()) {		final Object element = elements.nextElement();		if (element instanceof TopLevelElement) {		    topStylesheet.addElement((TopLevelElement)element);		}	    }	}	catch (Exception e) {	    e.printStackTrace();	}	finally {	    parser.setCurrentStylesheet(context);	}    }