Moved classes to website appropriate directory
This commit is contained in:
@@ -1,9 +1,8 @@
|
||||
//CipherStreamJava/src/main/java/mattrixwv/CipherStreamJava/Atbash.java
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/Atbash.java
|
||||
//Matthew Ellison
|
||||
// Created: 07-25-21
|
||||
//Modified: 01-04-22
|
||||
//This is the declaration of the Atbash class
|
||||
package mattrixwv.CipherStreamJava;
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
public class Atbash{
|
||||
@@ -1,9 +1,8 @@
|
||||
//CipherStreamJava/src/main/java/mattrixwv/CipherStreamJava/Autokey.java
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/Autokey.java
|
||||
//Matthew Ellison
|
||||
// Created: 07-25-21
|
||||
//Modified: 12-30--21
|
||||
//This is the declaration of the Autokey class
|
||||
package mattrixwv.CipherStreamJava;
|
||||
//Modified: 01-04-22
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
public class Autokey extends Vigenere{
|
||||
@@ -1,9 +1,8 @@
|
||||
//CipherStreamJava/src/main/java/mattrixwv/CipherStreamJava/Caesar.java
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/Caesar.java
|
||||
//Matthew Ellison
|
||||
// Created: 07-25-21
|
||||
//Modified: 01-04-22
|
||||
//This is the declaration of the Caesar class
|
||||
package mattrixwv.CipherStreamJava;
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
public class Caesar{
|
||||
@@ -1,8 +1,8 @@
|
||||
//CipherStreamJava/src/main/java/mattrixwv/CipherStreamJava/Exceptions/InvalidCharacterException.java
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/Exceptions/InvalidCharacterException.java
|
||||
//Mattrixwv
|
||||
// Created: 01-04-22
|
||||
//Modified: 01-04-22
|
||||
package mattrixwv.CipherStreamJava.Exceptions;
|
||||
package com.mattrixwv.CipherStreamJava.Exceptions;
|
||||
|
||||
|
||||
public class InvalidCharacterException extends Exception{
|
||||
@@ -1,9 +1,8 @@
|
||||
//CipherStreamJava/src/main/java/mattrixwv/CipherStreamJava/Morse.java
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/Morse.java
|
||||
//Matthew Ellison
|
||||
// Created: 07-28-21
|
||||
//Modified: 07-28-21
|
||||
//This is the declaration of the Morse class
|
||||
package mattrixwv.CipherStreamJava;
|
||||
//Modified: 01-04-22
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
public class Morse{
|
||||
@@ -1,11 +1,12 @@
|
||||
//CipherStreamJava/src/main/java/mattrixwv/CipherStreamJava/Playfair.java
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/Playfair.java
|
||||
//Matthew Ellison
|
||||
// Created: 07-30-21
|
||||
//Modified: 01-04-22
|
||||
//This is the declaration of the Playfair class
|
||||
package mattrixwv.CipherStreamJava;
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
import com.mattrixwv.CipherStreamJava.Exceptions.InvalidCharacterException;
|
||||
|
||||
import mattrixwv.CipherStreamJava.Exceptions.InvalidCharacterException;
|
||||
|
||||
public class Playfair{
|
||||
//A class representing the location of a character in the grid
|
||||
@@ -1,12 +1,14 @@
|
||||
//CipherStreamJava/src/main/java/mattrixwv/CipherStreamJava/PolybiusSquare.java
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/PolybiusSquare.java
|
||||
//Mattrixwv
|
||||
// Created: 01-04-22
|
||||
//Modified: 01-04-22
|
||||
package mattrixwv.CipherStreamJava;
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
import java.util.StringJoiner;
|
||||
|
||||
import mattrixwv.CipherStreamJava.Exceptions.InvalidCharacterException;
|
||||
import com.mattrixwv.CipherStreamJava.Exceptions.InvalidCharacterException;
|
||||
|
||||
|
||||
public class PolybiusSquare{
|
||||
//A class representing the location of a character in the grid
|
||||
@@ -1,9 +1,8 @@
|
||||
//CipherStreamJava/src/main/java/mattrixwv/CipherStreamJava/Vigenere.java
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/Vigenere.java
|
||||
//Matthew Ellison
|
||||
// Created: 07-25-21
|
||||
//Modified: 01-04-22
|
||||
//This is the declaration of the Vigenere class
|
||||
package mattrixwv.CipherStreamJava;
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
//CipherStreamJava/src/main/java/mattrixwv/CipherStreamJava/TestAtbash.java
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/TestAtbash.java
|
||||
//Matthew Ellison
|
||||
// Created: 07-25-21
|
||||
//Modified: 12-30-21
|
||||
//These are the tests for the Atbash class
|
||||
package mattrixwv.CipherStreamJava;
|
||||
//Modified: 01-04-22
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
@@ -1,9 +1,8 @@
|
||||
//CipherStreamJava/src/main/java/mattrixwv/CipherStreamJava/TestAutokey.java
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/TestAutokey.java
|
||||
//Matthew Ellison
|
||||
// Created: 07-26-21
|
||||
//Modified: 12-30-21
|
||||
//These are the tests for the Vigenere class
|
||||
package mattrixwv.CipherStreamJava;
|
||||
//Modified: 01-04-22
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
@@ -1,9 +1,8 @@
|
||||
//CipherStreamJava/src/test/java/mattrixwv/CipherStreamJava/TestCaesar.java
|
||||
//CipherStreamJava/src/test/java/com/mattrixwv/CipherStreamJava/TestCaesar.java
|
||||
//Matthew Ellison
|
||||
// Created: 07-25-21
|
||||
//Modified: 12-30-21
|
||||
//These are the tests for the Caesar class
|
||||
package mattrixwv.CipherStreamJava;
|
||||
//Modified: 01-04-22
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
@@ -1,59 +1,58 @@
|
||||
//CipherStreamJava/src/main/java/mattrixwv/CipherStreamJava/TestMorse.java
|
||||
//Matthew Ellison
|
||||
// Created: 07-28-21
|
||||
//Modified: 07-28-21
|
||||
//These are the tests for the Morse class
|
||||
package mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
|
||||
import org.junit.Test;
|
||||
|
||||
|
||||
public class TestMorse{
|
||||
@Test
|
||||
public void testDecode(){
|
||||
Morse cipher = new Morse();
|
||||
|
||||
//Test 1
|
||||
String input = "... --- ...";
|
||||
String correctOutput = "SOS";
|
||||
String output = cipher.decode(input);
|
||||
assertEquals("Morse Decoding failed the first test", correctOutput, output);
|
||||
|
||||
//Test 2
|
||||
input = "-- --- .-. ... . -.-. --- -.. .";
|
||||
correctOutput = "MORSECODE";
|
||||
output = cipher.decode(input);
|
||||
assertEquals("Morse Decoding failed the second test", correctOutput, output);
|
||||
|
||||
//Test 3
|
||||
input = ".---- ..--- ...-- ----. ---.. --...";
|
||||
correctOutput = "123987";
|
||||
output = cipher.decode(input);
|
||||
assertEquals("Morse Decoding failed the third test", correctOutput, output);
|
||||
}
|
||||
@Test
|
||||
public void testEncode(){
|
||||
Morse cipher = new Morse();
|
||||
|
||||
//Test 1
|
||||
String input = "sos";
|
||||
String correctOutput = "... --- ...";
|
||||
String output = cipher.encode(input);
|
||||
assertEquals("Morse Encoding failed the first test", correctOutput, output);
|
||||
|
||||
//Test 2
|
||||
input = "MORSE, CODE";
|
||||
correctOutput = "-- --- .-. ... . -.-. --- -.. .";
|
||||
output = cipher.encode(input);
|
||||
assertEquals("Morse Encoding failed the second test", correctOutput, output);
|
||||
|
||||
//Test 3
|
||||
input = "1.23 987";
|
||||
correctOutput = ".---- ..--- ...-- ----. ---.. --...";
|
||||
output = cipher.encode(input);
|
||||
assertEquals("Morse Encoding failed the third test", correctOutput, output);
|
||||
}
|
||||
}
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/TestMorse.java
|
||||
//Matthew Ellison
|
||||
// Created: 07-28-21
|
||||
//Modified: 01-04-22
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
|
||||
import org.junit.Test;
|
||||
|
||||
|
||||
public class TestMorse{
|
||||
@Test
|
||||
public void testDecode(){
|
||||
Morse cipher = new Morse();
|
||||
|
||||
//Test 1
|
||||
String input = "... --- ...";
|
||||
String correctOutput = "SOS";
|
||||
String output = cipher.decode(input);
|
||||
assertEquals("Morse Decoding failed the first test", correctOutput, output);
|
||||
|
||||
//Test 2
|
||||
input = "-- --- .-. ... . -.-. --- -.. .";
|
||||
correctOutput = "MORSECODE";
|
||||
output = cipher.decode(input);
|
||||
assertEquals("Morse Decoding failed the second test", correctOutput, output);
|
||||
|
||||
//Test 3
|
||||
input = ".---- ..--- ...-- ----. ---.. --...";
|
||||
correctOutput = "123987";
|
||||
output = cipher.decode(input);
|
||||
assertEquals("Morse Decoding failed the third test", correctOutput, output);
|
||||
}
|
||||
@Test
|
||||
public void testEncode(){
|
||||
Morse cipher = new Morse();
|
||||
|
||||
//Test 1
|
||||
String input = "sos";
|
||||
String correctOutput = "... --- ...";
|
||||
String output = cipher.encode(input);
|
||||
assertEquals("Morse Encoding failed the first test", correctOutput, output);
|
||||
|
||||
//Test 2
|
||||
input = "MORSE, CODE";
|
||||
correctOutput = "-- --- .-. ... . -.-. --- -.. .";
|
||||
output = cipher.encode(input);
|
||||
assertEquals("Morse Encoding failed the second test", correctOutput, output);
|
||||
|
||||
//Test 3
|
||||
input = "1.23 987";
|
||||
correctOutput = ".---- ..--- ...-- ----. ---.. --...";
|
||||
output = cipher.encode(input);
|
||||
assertEquals("Morse Encoding failed the third test", correctOutput, output);
|
||||
}
|
||||
}
|
||||
@@ -1,16 +1,15 @@
|
||||
//CipherStreamJava/src/main/java/mattrixwv/CipherStreamJava/TestPlayfair.java
|
||||
//CipherStreamJava/src/main/java/com/mattrixwv/CipherStreamJava/TestPlayfair.java
|
||||
//Matthew Ellison
|
||||
// Created: 07-30-21
|
||||
//Modified: 01-04-22
|
||||
//These are the tests for the Playfair class
|
||||
package mattrixwv.CipherStreamJava;
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
|
||||
import org.junit.Test;
|
||||
import com.mattrixwv.CipherStreamJava.Exceptions.InvalidCharacterException;
|
||||
|
||||
import mattrixwv.CipherStreamJava.Exceptions.InvalidCharacterException;
|
||||
import org.junit.Test;
|
||||
|
||||
|
||||
public class TestPlayfair{
|
||||
@@ -1,15 +1,15 @@
|
||||
//CipherStreamJava/src/test/java/mattrixwv/CipherStreamJava/TestPolybiusSquare.java
|
||||
//CipherStreamJava/src/test/java/com/mattrixwv/CipherStreamJava/TestPolybiusSquare.java
|
||||
//Mattrixwv
|
||||
// Created: 01-04-22
|
||||
//Modified: 01-04-22
|
||||
package mattrixwv.CipherStreamJava;
|
||||
package com.mattrixwv.CipherStreamJava;
|
||||
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
|
||||
import org.junit.Test;
|
||||
import com.mattrixwv.CipherStreamJava.Exceptions.InvalidCharacterException;
|
||||
|
||||
import mattrixwv.CipherStreamJava.Exceptions.InvalidCharacterException;
|
||||
import org.junit.Test;
|
||||
|
||||
|
||||
public class TestPolybiusSquare{
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user