private void handleStartDocument() throws SAXException { final Location location = staxStreamReader.getLocation(); if (location != null) { filter.setDocumentLocator(new Locator() { public int getColumnNumber() { return location.getColumnNumber(); } public int getLineNumber() { return location.getLineNumber(); } public String getPublicId() { return location.getPublicId(); } public String getSystemId() { return location.getSystemId(); } }); } else { filter.setDocumentLocator(new DummyLocator()); } filter.startDocument(); }
protected void handleStartDocument() throws SAXException { final Location location = staxStreamReader.getLocation(); if (location != null) { filter.setDocumentLocator(new Locator() { public int getColumnNumber() { return location.getColumnNumber(); } public int getLineNumber() { return location.getLineNumber(); } public String getPublicId() { return location.getPublicId(); } public String getSystemId() { return location.getSystemId(); } }); } else { filter.setDocumentLocator(new DummyLocator()); } filter.startDocument(); }
filter.setDocumentLocator(new DummyLocator());
private void handleStartDocument(final XMLEvent event) throws SAXException { final Location location = event.getLocation(); if (location != null) { filter.setDocumentLocator(new Locator() { public int getColumnNumber() { return location.getColumnNumber(); } public int getLineNumber() { return location.getLineNumber(); } public String getPublicId() { return location.getPublicId(); } public String getSystemId() { return location.getSystemId(); } }); } else { filter.setDocumentLocator(new DummyLocator()); } filter.startDocument(); }
this.filter.setDocumentLocator(new DummyLocator());