Examples of closeWeakly()


Examples of org.apache.felix.framework.util.WeakZipFileFactory.WeakZipFile.closeWeakly()

            assertNotNull("Zip entry not found", ze);
            byte[] firstHalf = new byte[contentBytes.length / 2];
            byte[] secondHalf = new byte[contentBytes.length - firstHalf.length];
            InputStream is = zipFile.getInputStream(ze);
            is.read(firstHalf);
            zipFile.closeWeakly();
            assertTrue("Zip file not recorded.",
                factory.getZipZiles().contains(zipFile));
            assertFalse("Open zip file still recorded.",
                factory.getOpenZipZiles().contains(zipFile));
            is.read(secondHalf);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.