keythai 0.1.0

Thai <-> English when you forgot to change language
Documentation
///change to Thai word
///to_th(input:&str)-> std::string::String
pub fn to_th(input:&str)-> std::string::String {
    let mut output = std::string::String::new();

        for mut i in input.chars() {
            match i{
                '1'=>{i=''},
                '!'=>{i='+'},
                '2'=>{i='/'},
                '@'=>{i=''},
                '3'=>{i='-'},
                '#'=>{i=''},
                '4'=>{i=''},
                '$'=>{i=''},
                '5'=>{i=''},
                '%'=>{i=''},
                '6'=>{i=''},
                '^'=>{i=''},
                '7'=>{i=''},
                '&'=>{i='฿'},
                '8'=>{i=''},
                '*'=>{i=''},
                '9'=>{i=''},
                '('=>{i=''},
                '0'=>{i=''},
                ')'=>{i=''},
                '-'=>{i=''},
                '_'=>{i=''},
                '='=>{i=''},
                '+'=>{i=''},
                'q'=>{i=''},
                'Q'=>{i=''},
                'w'=>{i=''},
                'W'=>{i='"'},
                'e'=>{i=''},
                'E'=>{i=''},
                'r'=>{i=''},
                'R'=>{i=''},
                't'=>{i=''},
                'T'=>{i=''},
                'y'=>{i=''},
                'Y'=>{i=''},
                'u'=>{i=''},
                'U'=>{i=''},
                'i'=>{i=''},
                'I'=>{i=''},
                'o'=>{i=''},
                'O'=>{i=''},
                'p'=>{i=''},
                'P'=>{i=''},
                '['=>{i=''},
                '{'=>{i=''},
                ']'=>{i=''},
                '}'=>{i=','},
                'a'=>{i=''},
                'A'=>{i=''},
                's'=>{i=''},
                'S'=>{i=''},
                'd'=>{i=''},
                'D'=>{i=''},
                'f'=>{i=''},
                'F'=>{i=''},
                'g'=>{i=''},
                'G'=>{i=''},
                'h'=>{i=''},
                'H'=>{i=''},
                'j'=>{i=''},
                'J'=>{i=''},
                'k'=>{i=''},
                'K'=>{i=''},
                'l'=>{i=''},
                'L'=>{i=''},
                ';'=>{i=''},
                ':'=>{i=''},
                '\''=>{i=''},
                '"'=>{i='.'},
                '\\'=>{i=''},
                '|'=>{i=''},
                'z'=>{i=''},
                'Z'=>{i='('},
                'x'=>{i=''},
                'X'=>{i=')'},
                'c'=>{i=''},
                'C'=>{i=''},
                'v'=>{i=''},
                'V'=>{i=''},
                'b'=>{i=''},
                'B'=>{i=''},
                'n'=>{i=''},
                'N'=>{i=''},
                'm'=>{i=''},
                'M'=>{i='?'},
                ','=>{i=''},
                '<'=>{i=''},
                '.'=>{i=''},
                '>'=>{i=''},
                '/'=>{i=''},
                '?'=>{i=''},
                _ =>{}
            }
            output.push(i);
        }
        output
}

///change to English word
///to_en(input:&str)-> std::string::String
pub fn to_en(input:&str)-> std::string::String {
    let mut output = std::string::String::new();

        for mut i in input.chars() {
            match i{
                ''=>{i='1'},
                '+'=>{i='!'},
                '/'=>{i='2'},
                ''=>{i='@'},
                '-'=>{i='3'},
                ''=>{i='#'},
                ''=>{i='4'},
                ''=>{i='$'},
                ''=>{i='5'},
                ''=>{i='%'},
                ''=>{i='6'},
                ''=>{i='^'},
                ''=>{i='7'},
                '฿'=>{i='&'},
                ''=>{i='8'},
                ''=>{i='*'},
                ''=>{i='9'},
                ''=>{i='('},
                ''=>{i='0'},
                ''=>{i=')'},
                ''=>{i='-'},
                ''=>{i='_'},
                ''=>{i='='},
                ''=>{i='+'},
                ''=>{i='q'},
                ''=>{i='Q'},
                ''=>{i='w'},
                '"'=>{i='W'},
                ''=>{i='e'},
                ''=>{i='E'},
                ''=>{i='r'},
                ''=>{i='R'},
                ''=>{i='t'},
                ''=>{i='T'},
                ''=>{i='y'},
                ''=>{i='Y'},
                ''=>{i='u'},
                ''=>{i='U'},
                ''=>{i='i'},
                ''=>{i='I'},
                ''=>{i='o'},
                ''=>{i='O'},
                ''=>{i='p'},
                ''=>{i='P'},
                ''=>{i='['},
                ''=>{i='{'},
                ''=>{i=']'},
                ','=>{i='}'},
                ''=>{i='a'},
                ''=>{i='A'},
                ''=>{i='s'},
                ''=>{i='S'},
                ''=>{i='d'},
                ''=>{i='D'},
                ''=>{i='f'},
                ''=>{i='F'},
                ''=>{i='g'},
                ''=>{i='G'},
                ''=>{i='h'},
                ''=>{i='H'},
                ''=>{i='j'},
                ''=>{i='J'},
                ''=>{i='k'},
                ''=>{i='K'},
                ''=>{i='l'},
                ''=>{i='L'},
                ''=>{i=';'},
                ''=>{i=':'},
                ''=>{i='\''},
                '.'=>{i='"'},
                ''=>{i='\\'},
                ''=>{i='|'},
                ''=>{i='z'},
                '('=>{i='Z'},
                ''=>{i='x'},
                ')'=>{i='X'},
                ''=>{i='c'},
                ''=>{i='C'},
                ''=>{i='v'},
                ''=>{i='V'},
                ''=>{i='b'},
                ''=>{i='B'},
                ''=>{i='n'},
                ''=>{i='N'},
                ''=>{i='m'},
                '?'=>{i='M'},
                ''=>{i=','},
                ''=>{i='<'},
                ''=>{i='.'},
                ''=>{i='>'},
                ''=>{i='/'},
                ''=>{i='?'},
                _ =>{}
            }
            output.push(i);
        }
        output
}