I need a function that gives a one-to-one map from a string to another string, but the output string the nice property of being a proper name for a file.
More specifically my problem is that, given a URL of an image, I want to save the image with a unique name given that URL. I need a code like this
string url;
string uniqueName = UrlToName (url);
string fileName = path + uniqueName + ".png";
The problem is how to get the UrlToName
function. An possible solution could be GetHashCode
but I don't know if its correct.