/** * Loads a new {@link XSDResourceImpl} into the resource set. * @param inputStream the contents of the new resource. * @param options any options to influence loading behavior. */ @Override protected void doLoad(InputStream inputStream, Map<?, ?> options) throws IOException { InputSource inputSource = inputStream instanceof URIConverter.ReadableInputStream ? new InputSource(((URIConverter.ReadableInputStream)inputStream).asReader()) : new InputSource(inputStream); if (getURI() != null) { String id = getURI().toString(); inputSource.setPublicId(id); inputSource.setSystemId(id); } doLoad(inputSource, options); }
/** * Loads a new {@link XSDResourceImpl} into the resource set. * @param inputStream the contents of the new resource. * @param options any options to influence loading behavior. * @return a new XSDResourceImpl. */ @Override protected void doLoad(InputStream inputStream, Map<?, ?> options) throws IOException { InputSource inputSource = inputStream instanceof URIConverter.ReadableInputStream ? new InputSource(((URIConverter.ReadableInputStream)inputStream).asReader()) : new InputSource(inputStream); if (getURI() != null) { String id = getURI().toString(); inputSource.setPublicId(id); inputSource.setSystemId(id); } doLoad(inputSource, options); }