Browse Source

provide access to compression method

git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@808262 13f79535-47bb-0310-9956-ffa450edef68
master
Stefan Bodewig 16 years ago
parent
commit
e0b4aa354f
1 changed files with 10 additions and 0 deletions
  1. +10
    -0
      src/main/org/apache/tools/ant/types/resources/ZipResource.java

+ 10
- 0
src/main/org/apache/tools/ant/types/resources/ZipResource.java View File

@@ -41,6 +41,7 @@ public class ZipResource extends ArchiveResource {


private String encoding; private String encoding;
private ZipExtraField[] extras; private ZipExtraField[] extras;
private int method;


/** /**
* Default constructor. * Default constructor.
@@ -183,6 +184,14 @@ public class ZipResource extends ArchiveResource {
return extras; return extras;
} }


/**
* The compression method that has been used.
* @since Ant 1.8.0
*/
public int getMethod() {
return method;
}

/** /**
* fetches information from the named entry inside the archive. * fetches information from the named entry inside the archive.
*/ */
@@ -211,6 +220,7 @@ public class ZipResource extends ArchiveResource {
setSize(e.getSize()); setSize(e.getSize());
setMode(e.getUnixMode()); setMode(e.getUnixMode());
extras = e.getExtraFields(); extras = e.getExtraFields();
method = e.getMethod();
} }


} }

Loading…
Cancel
Save