Author: nick
Date: Fri Feb 10 11:43:01 2017
New Revision: 1782454
URL: http://svn.apache.org/viewvc?rev=1782454&view=rev
Log:
Update the big file test to use POIFSFileSystem.create(File), and tweak javadocs
Modified:
poi/trunk/src/java/org/apache/poi/poifs/filesystem/POIFSFileSystem.java
poi/trunk/src/testcases/org/apache/poi/poifs/filesystem/TestNPOIFSFileSystem.java
Modified:
poi/trunk/src/java/org/apache/poi/poifs/filesystem/POIFSFileSystem.java
URL:
http://svn.apache.org/viewvc/poi/trunk/src/java/org/apache/poi/poifs/filesystem/POIFSFileSystem.java?rev=1782454&r1=1782453&r2=1782454&view=diff
==============================================================================
--- poi/trunk/src/java/org/apache/poi/poifs/filesystem/POIFSFileSystem.java
(original)
+++ poi/trunk/src/java/org/apache/poi/poifs/filesystem/POIFSFileSystem.java Fri
Feb 10 11:43:01 2017
@@ -27,9 +27,10 @@ import org.apache.poi.util.CloseIgnoring
/**
* Transition class for the move from {@link POIFSFileSystem} to
* {@link OPOIFSFileSystem}, and from {@link NPOIFSFileSystem} to
- * {@link POIFSFileSystem}. Currently, this is OPOIFS-powered
+ * {@link POIFSFileSystem}.
+ * <p>This has been updated to be powered by the NIO-based NPOIFS
+ * {@link NPOIFSFileSystem}.
*/
-
public class POIFSFileSystem
extends NPOIFSFileSystem // TODO Temporary workaround during #56791
implements POIFSViewable
Modified:
poi/trunk/src/testcases/org/apache/poi/poifs/filesystem/TestNPOIFSFileSystem.java
URL:
http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/poifs/filesystem/TestNPOIFSFileSystem.java?rev=1782454&r1=1782453&r2=1782454&view=diff
==============================================================================
---
poi/trunk/src/testcases/org/apache/poi/poifs/filesystem/TestNPOIFSFileSystem.java
(original)
+++
poi/trunk/src/testcases/org/apache/poi/poifs/filesystem/TestNPOIFSFileSystem.java
Fri Feb 10 11:43:01 2017
@@ -1569,8 +1569,7 @@ public final class TestNPOIFSFileSystem
* Note that to run this test, you will require 2.5+gb of free
* space on your TMP/TEMP partition/disk
*
- * TODO Fix this to work
- * TODO Update this to use a "create as new file" constructor too
+ * TODO Fix this to work...
*/
@Test
@Ignore("Work in progress test for #60670")
@@ -1584,14 +1583,8 @@ public final class TestNPOIFSFileSystem
int s512mb = 512*1024*1024;
DocumentEntry entry;
- // TODO Provide a create method that takes a file
-
// Create a just-sub 2gb file
- NPOIFSFileSystem fs = new NPOIFSFileSystem();
- fs.writeFilesystem(new FileOutputStream(big));
- fs.close();
-
- fs = new NPOIFSFileSystem(big, false);
+ NPOIFSFileSystem fs = POIFSFileSystem.create(big);
for (int i=0; i<19; i++) {
fs.createDocument(new DummyDataInputStream(s100mb), "Entry"+i);
}
@@ -1627,11 +1620,7 @@ public final class TestNPOIFSFileSystem
// Create a >2gb file
- fs = new NPOIFSFileSystem();
- fs.writeFilesystem(new FileOutputStream(big));
- fs.close();
-
- fs = new NPOIFSFileSystem(big, false);
+ fs = POIFSFileSystem.create(big);
for (int i=0; i<4; i++) {
fs.createDocument(new DummyDataInputStream(s512mb), "Entry"+i);
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]