code: public void close() throws IOException {
  		// close last tag, if present
  		if(lastChildNode!=null) {
  			lastChildNode.close();
  			lastChildNode = null;
  		}
  		writer.write("\n");
  		writer.flush();
  		isOpen = false;
  	}
docs: Closes this document.
  <b>NOTICE:</b> It is <b>absolutely necessary</b> to call this method in the end,
  as otherwise the last added child node will not be appropriately finished!