mirror of
https://bitbucket.org/Mattrixwv/cipherstream.git
synced 2025-12-07 10:43:59 -05:00
34 lines
769 B
C++
34 lines
769 B
C++
//Ciphers/Headers/Morse.hpp
|
|
//Matthew Ellison
|
|
// Created: 5-1-18
|
|
//Modified: 5-1-18
|
|
//This file contains the declaration of the Morse class
|
|
//This class is designed to translate Morse Code into regular letters and numbers
|
|
|
|
#ifndef MORSE_HPP
|
|
#define MORSE_HPP
|
|
|
|
#include <string>
|
|
#include <sstream>
|
|
|
|
|
|
class Morse{
|
|
private:
|
|
static std::string code[];
|
|
std::stringstream inputString;
|
|
std::string outputString;
|
|
std::string encode();
|
|
std::string decode();
|
|
public:
|
|
Morse();
|
|
~Morse();
|
|
void setEncodeInputString(std::string input);
|
|
void setDecodeInputString(std::string input);
|
|
std::string getInputString() const;
|
|
std::string getOutputString() const;
|
|
std::string encode(std::string input);
|
|
std::string decode(std::string input);
|
|
void reset();
|
|
};
|
|
|
|
#endif //MORSE_HPP
|