Receive notification of the end of the document.

@see org.xml.sax.ContentHandler#endDocument

@throws org.xml.sax.SAXException Any SAX exception, possibly
wrapping another exception.
490401
public void endDocument() throws org.xml.sax.SAXException
  {

    try
    {
      if (null != getStylesheetRoot())
      {
        if (0 == m_stylesheetLevel)
          getStylesheetRoot().recompose();        
      }
      else
        throw new TransformerException(XSLMessages.createMessage(XSLTErrorResources.ER_NO_STYLESHEETROOT, null)); //"Did not find the stylesheet root!");

      XSLTElementProcessor elemProcessor = getCurrentProcessor();

      if (null != elemProcessor)
        elemProcessor.startNonText(this);

      m_stylesheetLevel--;			
      
      popSpaceHandling();

      // WARNING: This test works only as long as stylesheets are parsed
      // more or less recursively. If we switch to an iterative "work-list"
      // model, this will become true prematurely. In that case,
      // isStylesheetParsingComplete() will have to be adjusted to be aware
      // of the worklist.
      m_parsingComplete = (m_stylesheetLevel < 0);
    }
    catch (TransformerException te)
    {
      throw new org.xml.sax.SAXException(te);
    }
  }
679386
public void endElement (String qName)
    throws SAXException
    {
                // If we're not doing Namespace
                // processing, dispatch this quickly.
    if (!namespaces) {
        if (contentHandler != null) {
        contentHandler.endElement("", "", qName.intern());
        }
        return;
    }

                // Split the name.
    String names[] = processName(qName, false, false);
    if (contentHandler != null) {
        contentHandler.endElement(names[0], names[1], names[2]);
        Enumeration prefixes = nsSupport.getDeclaredPrefixes();
        while (prefixes.hasMoreElements()) {
        String prefix = (String)prefixes.nextElement();
        contentHandler.endPrefixMapping(prefix);
        }
    }
    nsSupport.popContext();
    }
311007
@Override
    public void endElement(String uri, String name, String qName) {
	setContent(content.toString().trim());
	content = new StringBuilder();
	inside = "";
	if (qName.equals("function")) endFunction();
	else if (qName.equals("argument")) endArg();
	else if (qName.equals("return")) endReturn();
	else if (qName.equals("bundle")) endBundle();

    }
1042069
private void endJSON()
    throws SAXException
    {   
        if (logger.isLoggable(Level.FINER)) logger.entering(className, "endJSON()");

        try
        {
            this.head.writeObject(this.osWriter, 0, true, this.compact);
            this.head    = null;
            this.current = null;
            this.previousObjects.clear();
        }
        catch (Exception ex)
        {
            SAXException saxEx = new SAXException(ex);
            saxEx.initCause(ex);
            throw saxEx;
        }

        if (logger.isLoggable(Level.FINER)) logger.exiting(className, "endJSON()");
    }
1067725
public void writeEndDocument() throws XMLStreamException {
		try {
			checkPendingATEvents();
			encoder.encodeEndDocument();
			encoder.flush();
		} catch (Exception e) {
			throw new XMLStreamException(e.getLocalizedMessage(), e);
		}
	}
1189875
public void endElement(String name) throws org.xml.sax.SAXException
    {
        endElement(null, null, name);
    }
1070117
public void writeEndElement() throws XMLStreamException {
		try {
			this.checkPendingATEvents();
			encoder.encodeEndElement();
		} catch (Exception e) {
			throw new XMLStreamException(e.getLocalizedMessage(), e);
		}
	}
314489
public void endAllElements() throws KNXMLException
	{
		try {
			while (!layout.empty())
				((Tag) layout.pop()).endTag();
			w.flush();
		}
		catch (final IOException e) {
			throw new KNXMLException(e.getMessage());
		}
	}
443137
@Override
    public void startDocument() throws SAXException {
        try {
            switch (doctype) {
                case NO_DOCTYPE:
                    return;
                case DOCTYPE_HTML5:
                    writer.write("<!DOCTYPE html>\n");
                    return;
                case DOCTYPE_HTML401_STRICT:
                    writer.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01//EN\" \"http://www.w3.org/TR/html4/strict.dtd\">\n");
                    return;
                case DOCTYPE_HTML401_TRANSITIONAL:
                    writer.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">\n");
                    return;
            }
        } catch (IOException ioe) {
            throw (SAXException)new SAXException(ioe).initCause(ioe);
        }
    }
946971
@Override
	public void endContentLine(ChainWriter out, WebSiteRequest req, HttpServletResponse resp, int rowspan, boolean endsInternal) {
		out.print("    </td>\n"
				+ "  </tr>\n");
	}
584116
public XMLDocument endElements(String uri, String name) throws SAXException{
        QName qname = findEndElement();
        while(true){
            endElement(qname);
            if(qname.getNamespaceURI().equals(uri) && qname.getLocalPart().equals(name))
                break;
        }
        return this;
    }
1289722
public void end() {
		// if (((ArrayList) this.featureCollection).size() == 0) {
		this.endNewElement();
		// }
		contentHandler.endFeatureCollection(this.featureCollection);
		if (writerContentHandler != null)
			geoJSON = writerContentHandler.endFeatureCollection(geoJSON);
	}
193205
public void endElement(
          StylesheetHandler handler, String uri, String localName, String rawName)
            throws SAXException
  {
   ElemTemplateElement function = handler.getElemTemplateElement();
   validate(function, handler); // may throw exception
   super.endElement(handler, uri, localName, rawName);   
  }
514058
public void endDocument() throws IOException {
        endChangesIfNecessary();
        ResponseWriter writer = getWrapped();
        /*
         * Because during a <script> writing an exception can occur we need to
         * make sure the wrapped response only writes one partial-response, but
         * also calls to end the document (so we can properly cleanup in the 
         * wrapped HtmlResponseWriter). See issue #3473.
         */
        if (!(writer instanceof PartialResponseWriter)) {
            writer.endElement("partial-response");
        }
        writer.endDocument();
    }
618071
protected void startDocumentInternal() throws org.xml.sax.SAXException
    {
        super.startDocumentInternal();

        m_needToCallStartDocument = false; 
        m_needToOutputDocTypeDecl = true;
        m_startNewLine = false;
        setOmitXMLDeclaration(true);
    }
538813
@Override
    public void endDocument(MetaData metadata)
    {
        this.builder.addBlock(new XDOM(this.builder.endBlockList(), metadata));
    }
715160
def end_output (self, **kwargs):
        
        self.xml_endtag(u"linkchecker")
        self.xml_end_output()
        self.close_fileoutput()