All Downloads are FREE. Search and download functionalities are using the official Maven repository.

software.coley.llzip.format.read.ZipReaderStrategy Maven / Gradle / Ivy

package software.coley.llzip.format.read;

import software.coley.llzip.format.model.LocalFileHeader;
import software.coley.llzip.format.model.ZipArchive;
import software.coley.llzip.util.ByteData;

import java.io.IOException;

/**
 * Outlines reading binary data into a ZIP data type.
 *
 * @author Matt Coley
 */
public interface ZipReaderStrategy {
	/**
	 * @param zip
	 * 		Archive to read into.
	 * @param data
	 * 		Data to read.
	 *
	 * @throws IOException
	 * 		When the data cannot be read (EOF, not matching expectations, etc)
	 */
	void read(ZipArchive zip, ByteData data) throws IOException;

	default void postProcessLocalFileHeader(LocalFileHeader file) {
		// no-op by default
	}
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy