@Override
	public void startElement(String uri, String localName, String qName,
			Attributes attributes) throws SAXException {
		try {
			if (skip) {
				return;
			}

			if ("BIBLEBOOK".equals(qName)) {

				int bnumber = Integer.parseInt(attributes.getValue("bnumber"));

				if (bnumber > maxBooks) {
					skip = true;
				}

				if (skip) {
					return;
				}
				BOOK_ENUM be = BOOK_ENUM.values()[bnumber - 1];
				String bookName = be.getName();
				String bookTitle = be.getTitle();

				String readedBookTitle = attributes.getValue("bname");
				if (readedBookTitle != null)
					bookTitle = readedBookTitle;

				logger.log(Level.INFO, "Parsing book: " + bookTitle);

				currentBook = new JSONObject();
				currentBook.put("name", bookName);
				currentBook.put("title", bookTitle);
				currentBook.put("primaryNodeType", "sling:Folder");
				currentBook.put("sling:resourceType", "godswill/book");

				result.put(bookName.toLowerCase(), currentBook);

			} else if ("CHAPTER".equals(qName)) {
				currentChapter = new JSONObject();
				currentChapter.put("primaryNodeType", "sling:Folder");
				currentChapter.put("sling:resourceType", "godswill/chapter");

				String chapterNumber = attributes.getValue("cnumber");

				currentBook.put(chapterNumber, currentChapter);

			} else if ("CAPTION".equals(qName)) {
				isCaption = true;

			} else if ("VERS".equals(qName)) {
				currentVerse = new JSONObject();
				currentVerse.put("primaryNodeType", "sling:Folder");
				currentVerse.put("sling:resourceType", "godswill/verse");
				String verseNumber = attributes.getValue("vnumber");

				currentChapter.put(verseNumber, currentVerse);
				isVerse = true;
			}

		} catch (JSONException e) {
			logger.log(Level.SEVERE, e.getMessage(), e);
		}

	}