Updating tests
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/polySubstitution/Affine.java
|
||||
//Mattrixwv
|
||||
// Created: 01-26-22
|
||||
//Modified: 04-15-23
|
||||
//Modified: 05-04-23
|
||||
package com.mattrixwv.cipherstream.monosubstitution;
|
||||
|
||||
|
||||
@@ -15,16 +15,17 @@ import com.mattrixwv.NumberAlgorithms;
|
||||
|
||||
|
||||
public class Affine{
|
||||
protected static Logger logger = LoggerFactory.getLogger(Affine.class);
|
||||
|
||||
private static final Logger logger = LoggerFactory.getLogger(Affine.class);
|
||||
//Fields
|
||||
protected boolean preserveCapitals; //Whether to respect capitals in the output string
|
||||
protected boolean preserveSymbols; //Whether to respect symbols in the output string
|
||||
protected boolean preserveWhitespace; //Whether to respect whitespace in the output string
|
||||
protected String inputString; //The string that needs encoded/decoded
|
||||
protected String inputString; //The string that needs encoded/decoded
|
||||
protected String outputString; //The string that is output after encoding/decoding
|
||||
protected int key1; //The multiplicative key. Key1 must be relatively prime to 26
|
||||
protected int key2; //The additive key
|
||||
//Settings
|
||||
protected boolean preserveCapitals; //Persist capitals in the output string
|
||||
protected boolean preserveSymbols; //Persist symbols in the output string
|
||||
protected boolean preserveWhitespace; //Persist whitespace in the output string
|
||||
|
||||
|
||||
//Ensures key1 constraints
|
||||
protected void setKey1(int key1) throws InvalidKeywordException{
|
||||
@@ -225,19 +226,16 @@ public class Affine{
|
||||
return outputString;
|
||||
}
|
||||
|
||||
//Returns the cleaned inputString
|
||||
//Getters
|
||||
public String getInputString(){
|
||||
return inputString;
|
||||
}
|
||||
//Returns the outputString
|
||||
public String getOutputString(){
|
||||
return outputString;
|
||||
}
|
||||
//Returns the cleaned key1
|
||||
public int getKey1(){
|
||||
return key1;
|
||||
}
|
||||
//Returns the cleaned key2
|
||||
public int getKey2(){
|
||||
return key2;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user