Could someone please direct me to more information about this topic.
The only thing I could find was decoder() method that was not working at all. Oracle is even more vague about this topic and writes in a language that is incomprehensible to me.
I have no idea where even to begin with this task. Have I missed an important lesson on url parsing?
If someone can direct me to a tutorial on this topic very much appreciated!
package com.codegym.task.task15.task1527;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.UnsupportedEncodingException;
import java.net.URLDecoder;
import java.nio.charset.StandardCharsets;
/*
Request parser
*/
public class Solution {
public static void main(String[] args) {
//write your code here
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
String url = "";
try
{
url = reader.readLine();
System.out.println(URLDecoder.decode(url, "UTF-8"));
reader.close();
}
catch (IOException e){}
}
public static void alert(double value) {
System.out.println("double: " + value);
}
public static void alert(String value) {
System.out.println("String: " + value);
}
}