Browse Source

javadoc

git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@277309 13f79535-47bb-0310-9956-ffa450edef68
master
Peter Reilly 20 years ago
parent
commit
deb89a8e9e
1 changed files with 13 additions and 5 deletions
  1. +13
    -5
      src/main/org/apache/tools/zip/ExtraFieldUtils.java

+ 13
- 5
src/main/org/apache/tools/zip/ExtraFieldUtils.java View File

@@ -1,5 +1,5 @@
/*
* Copyright 2001-2002,2004 The Apache Software Foundation
* Copyright 2001-2002,2004-2005 The Apache Software Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -45,6 +45,7 @@ public class ExtraFieldUtils {
*
* <p>The given class must have a no-arg constructor and implement
* the {@link ZipExtraField ZipExtraField interface}.</p>
* @param c the class to register
*
* @since 1.1
*/
@@ -64,7 +65,10 @@ public class ExtraFieldUtils {
/**
* Create an instance of the approriate ExtraField, falls back to
* {@link UnrecognizedExtraField UnrecognizedExtraField}.
*
* @param headerId the header identifier
* @return an instance of the appropiate ExtraField
* @exception InstantiationException if unable to instantiate the class
* @exception IllegalAccessException if not allowed to instatiate the class
* @since 1.1
*/
public static ZipExtraField createExtraField(ZipShort headerId)
@@ -81,8 +85,10 @@ public class ExtraFieldUtils {
/**
* Split the array into ExtraFields and populate them with the
* give data.
*
* @param byte an array of bytes
* @return an array of ExtraFields
* @since 1.1
* @throws ZipException on error
*/
public static ZipExtraField[] parse(byte[] data) throws ZipException {
Vector v = new Vector();
@@ -117,7 +123,8 @@ public class ExtraFieldUtils {

/**
* Merges the local file data fields of the given ZipExtraFields.
*
* @param data an array of ExtraFiles
* @return an array of bytes
* @since 1.1
*/
public static byte[] mergeLocalFileDataData(ZipExtraField[] data) {
@@ -141,7 +148,8 @@ public class ExtraFieldUtils {

/**
* Merges the central directory fields of the given ZipExtraFields.
*
* @param data an array of ExtraFields
* @return an array of bytes
* @since 1.1
*/
public static byte[] mergeCentralDirectoryData(ZipExtraField[] data) {


Loading…
Cancel
Save