I'm trying to write this method that takes some parameters from my text editor, and encrypt the text. I got part of it written, but I'm stuck on the next bit.
I got the part where you convert the "key", but I just can't figure out what to do next.
import java.util.*;
public class Encryptor
{
public String encryptText(String key, String text)
{
String finalResult = "";
for (int i=0; i<key.length(); i++)
{
long convert = (long)key.charAt(i);
convert *= 128;
finalResult += convert;
}
Random randomNumGenerator = new Random(keyResult);
String returnString = "";
return returnString;
}
}