Added version information for all classes

This commit is contained in:
2018-05-16 10:33:17 -04:00
parent 5cc3b935c1
commit d54b34f4c2
12 changed files with 124 additions and 16 deletions

View File

@@ -1,7 +1,7 @@
//Ciphers/Headers/Morse.hpp
//Matthew Ellison
// Created: 5-1-18
//Modified: 5-5-18
//Modified: 5-16-18
//This file contains the declaration of the Morse class
//This class is designed to translate Morse Code into regular letters and numbers
@@ -15,11 +15,10 @@
class Morse{
private:
//Holds the Morse representation of the alphanumeric characters
const std::string code[36] {".-", "-...", "-.-.", "-..", ".", "..-.", "--.", "....", "..", ".---", "-.-", ".-..", //A-L
"--", "-.", "---", ".--.", "--.-", ".-.", "...", "-", "..-", "...-", ".--", "-..-", "-.--", "--..", //M-Z
"-----", ".----", "..---", "...--", "....-", ".....", "-....", "--...", "---..", "----."}; //0-9
static const std::string code[];
std::stringstream inputString; //The string that needs encoded/decoded
std::string outputString; //The encoded/decoded message
static const std::string version; //The current library's version number
std::string encode(); //Encodes inputString and stores the result in outputString
std::string decode(); //Decodes inputString and stores the result in outputString
void setEncodeInputString(std::string input); //Encodes input and returns the result
@@ -32,6 +31,7 @@ public:
std::string encode(std::string input); //Encodes input and returns the result
std::string decode(std::string input); //Decodes input and returns the result
void reset(); //Makes sure all variables are empty
static std::string getVersion();
};
#endif //MORSE_HPP