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

org.jwat.tools.tasks.arc2warc.Arc2WarcTaskCLI Maven / Gradle / Ivy

Go to download

JWAT-Tools uses the available JWAT libraries to make high level tasks available either from command-line or programmatically. Common tasks include: Test, Compress, Decompress, CDX, Arc2Warc. More specialised tasks include: Changed, ContainerMD, Delete, Extract, Interval, PathIndex, Unpack, Headers2CDX.

There is a newer version: 0.7.1
Show newest version
package org.jwat.tools.tasks.arc2warc;

import org.jwat.tools.tasks.TaskCLI;

import com.antiaction.common.cli.CommandLine;

public class Arc2WarcTaskCLI extends TaskCLI {

	public static final String commandName = "arc2warc";

	public static final String commandDescription = "convert ARC to WARC";

	@Override
	public void show_help() {
		System.out.println("jwattools arc2warc [-d DIR] [--overwrite]... [-w THREADS] ...");
		System.out.println("");
		System.out.println("arc2warc will convert one or more ARC file(s) to WARC file(s).");
		System.out.println("");
		System.out.println("options:");
		System.out.println("");
		System.out.println(" -d           destination directory (defaults to current dir)");
		System.out.println("    --overwrite    overwrite destination file (default is to skip file)");
		System.out.println("    --prefix       destination filename prefix (default is '" + Arc2WarcOptions.DEFAULT_PREFIX + "')");
		System.out.println("    --queue-first  queue files before processing");
		System.out.println(" -w             set the amount of worker thread(s) (defaults to 1)");
	}

	@Override
	public void runtask(CommandLine cmdLine) {
		Arc2WarcTask task = new Arc2WarcTask();
		task.runtask(Arc2WarcTaskCLIParser.parseArguments(cmdLine));
	}

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy