Files
Work/guitar/uutool.hpp
2024-08-07 09:16:27 -04:00

45 lines
591 B
C++

#ifndef _GUITAR_UUTOOL_HPP_
#define _GUITAR_UUTOOL_HPP_
#ifndef _COMMON_WINDOWS_HPP_
#include <common/windows.hpp>
#endif
#include <common/array.hpp>
class String;
class UUTool
{
public:
static String encode(String strLine);
static String decode(String strLine);
private:
UUTool(void);
virtual ~UUTool();
static BYTE chEncode(int ch);
static BYTE chDecode(int ch);
};
inline
UUTool::UUTool(void)
{
}
inline
UUTool::~UUTool()
{
}
inline
BYTE UUTool::chEncode(int ch)
{
return (ch?(ch&0x3F)+' ':'`');
}
inline
BYTE UUTool::chDecode(int ch)
{
return (ch-' ')&0x3F;
}
#endif