XMLInputSource (XMLResourceIdentifier xmlResourceIdentifier, String publicId, String defaultText) { try { myErrorReporter.processError( new SAXParseException(XmlPsiBundle.message("xml.inspections.validate.external.resource.is.not.registered", publicId), publicId, null, 0, 0), ValidateXmlActionHandler.ProblemType.ERROR); } catch (SAXException ignore) { } final XMLInputSource source = new XMLInputSource(xmlResourceIdentifier); source.setPublicId(publicId); source.setCharacterStream(new StringReader(defaultText)); return source; }