@Override public void characters(char[] texto, int inicio, int tamaño) throws SAXException { String texto_eti = new String(texto, inicio, tamaño); if (texto_eti.indexOf("\n") == -1) { if (etiqueta_leida.equals("fecha")) { datos.setFecha(texto_eti); } if (etiqueta_leida.equals("autor")) { datos.setAutor(texto_eti); } if (etiqueta_leida.equals("nombre")) { datos.setNombre(texto_eti); } if (etiqueta_leida.equals("apellido")) { datos.setApellido(texto_eti); } if (etiqueta_leida.equals("calle")) { datos.setCalle(texto_eti); } if (etiqueta_leida.equals("ciudad")) { datos.setCiudad(texto_eti); } } }