this.fragmentRootElements.toArray(new String[this.fragmentRootElements.size()])); reader.setStrict(this.strict); reader.setUnmarshaller(this.unmarshaller); reader.setCurrentItemCount(this.currentItemCount);
@Test public void testDirectoryResource() throws Exception { FileSystemResource resource = new FileSystemResource("build/data"); resource.getFile().mkdirs(); assertTrue(resource.getFile().isDirectory()); source.setResource(resource); source.afterPropertiesSet(); source.setStrict(false); source.open(executionContext); assertNull(source.read()); }
@Test(expected = ItemStreamException.class) public void testStrictness() throws Exception { source.setResource(new NonExistentResource()); source.setStrict(true); source.afterPropertiesSet(); source.open(executionContext); }
@Test public void testNonExistentResource() throws Exception { source.setResource(new NonExistentResource()); source.afterPropertiesSet(); source.setStrict(false); source.open(executionContext); assertNull(source.read()); }
this.fragmentRootElements.toArray(new String[this.fragmentRootElements.size()])); reader.setStrict(this.strict); reader.setUnmarshaller(this.unmarshaller); reader.setCurrentItemCount(this.currentItemCount);