org.keyczar.interop.Tester Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of keyczar Show documentation
Show all versions of keyczar Show documentation
Keyczar is a toolkit to make cryptography safer and easier
The newest version!
package org.keyczar.interop;
import org.keyczar.exceptions.KeyczarException;
import org.keyczar.interop.operations.Operation;
import java.util.Map;
import java.util.Set;
/**
* Class used for gson data to call test commands
*/
public class Tester {
@SuppressWarnings("unused")
private final String command;
private final String operation;
private final String keyPath;
private final String algorithm;
private final Map generateOptions;
private final Map testOptions;
private final Map output;
private final String testData;
public Tester(
String command, String operation, String keyPath, String algorithm,
Map generateOptions, Map testOptions,
Map output, String testData) {
this.command = command;
this.operation = operation;
this.keyPath = keyPath;
this.algorithm = algorithm;
this.generateOptions = generateOptions;
this.testOptions = testOptions;
this.output = output;
this.testData = testData;
}
public void test() throws KeyczarException {
Operation op = Operation.getOperationByName(operation, keyPath, testData);
op.test(output, algorithm, generateOptions, testOptions);
}
}