public class Zip extends Object
Modifier and Type | Method and Description |
---|---|
String |
basedir() |
Zip |
delete() |
List<String> |
entries()
syntactic sugar for all entries (entries(null))
|
List<String> |
entries(String pattern)
returns entry names of zip, matching given pattern if provided
|
Zip |
extractTo(File dir)
unzips to directory
|
Zip |
extractTo(String dir) |
File |
getFile() |
String |
id() |
public File getFile()
public String id()
public List<String> entries(String pattern) throws IOException
pattern
- a Java regular expression as a stringIOException
- the zip archive could not be correctly unzippedpublic List<String> entries() throws IOException
IOException
- the zip archive could not be correctly unzippedpublic String basedir() throws IOException
IOException
- the zip archive could not be correctly unzippedpublic Zip extractTo(String dir) throws IOException
IOException
public Zip extractTo(File dir) throws IOException
dir
- the target directoryIOException
- the zip archive could not be correctly unzippedpublic Zip delete()
Copyright © 2016–2017 CLIF project. All rights reserved.