@Override
	public void endElement(String namespaceURI, String localName, String qName) {
		String elementName = (String) elements_stack.peek();
		Attributes atts = (Attributes) attributes_stack.peek();
		String text = ((StringBuffer) characters_stack.peek()).toString();
		
		if (qName.equals(ELEMENT_OUTLINE)) {
			Node parentNode = currentParent.getParent();
			currentParent = parentNode;
		} else if (elementName.equals(ELEMENT_METADATA)) {
			String name = atts.getValue(ATTRIBUTE_NAME);
			if (!handleMetaDataCharacters(name, text)) {
				System.out.println("Error handling metadata element.");
			}
		} else if (elementName.equals(ELEMENT_ITEM)) {
			String name = atts.getValue(ATTRIBUTE_NAME);
			if (!handleItemCharacters(name, text)) {
				System.out.println("Error handling item element.");
			}
		} else if (elementName.equals(ELEMENT_DATA)) {
			if (!handleDataCharacters(text)) {
				System.out.println("Error handling data element.");
			}
		}
		
		super.endElement(namespaceURI, localName, qName);
	}