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

com.redislabs.riot.cli.HashExportCommand Maven / Gradle / Ivy

package com.redislabs.riot.cli;

import java.util.Map;

import org.springframework.batch.item.ItemProcessor;
import org.springframework.batch.item.ItemReader;

import com.redislabs.picocliredis.RedisOptions;
import com.redislabs.riot.cli.redis.RedisHashReaderOptions;

import picocli.CommandLine.ArgGroup;
import picocli.CommandLine.Command;

@Command
public abstract class HashExportCommand extends ExportCommand, Map> {

	@ArgGroup(exclusive = false, heading = "Redis reader options%n")
	private RedisHashReaderOptions readerOptions = new RedisHashReaderOptions();
	@ArgGroup(exclusive = false, heading = "Processor options%n", order = 40)
	private ProcessorOptions processorOptions = new ProcessorOptions();

	@Override
	protected ItemReader> reader(RedisOptions redisOptions) {
		return readerOptions.reader(redisOptions());
	}

	@Override
	protected ItemProcessor, Map> processor() throws Exception {
		return processorOptions.processor(null);
	}

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy