Java tutorial
//package com.java2s; //License from project: Apache License import java.util.Enumeration; import java.util.LinkedList; import java.util.List; import java.util.zip.ZipEntry; import java.util.zip.ZipFile; public class Main { @SuppressWarnings("unchecked") public static List<ZipEntry> zipEntries(ZipFile zipFile) { final List<ZipEntry> result = new LinkedList<ZipEntry>(); final Enumeration<ZipEntry> en = (Enumeration<ZipEntry>) zipFile.entries(); while (en.hasMoreElements()) { result.add(en.nextElement()); } return result; } }