Commit ab61dbfd authored by Fabian Becker's avatar Fabian Becker

Remove unused class

parent 54371159
Pipeline #112 passed with stage
package eva2.tools;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.URL;
import java.net.URLConnection;
public class URLGetter {
public URLGetter() {
}
public static String getData(String urlstr) {
System.getProperties().put("proxySet", "true");
System.getProperties().put("proxyHost",
"www-cache.informatik.uni-tuebingen.de");
System.getProperties().put("proxyPort", "3128");
StringBuilder res = new StringBuilder();
try {
URL url = new URL(urlstr);
URLConnection conn = url.openConnection();
BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream()));
String line;
while ((line = rd.readLine()) != null) {
res.append(line + "\n");
}
rd.close();
} catch (Exception ex) {
System.out.println("URLGETTER ERROR: " + ex);
}
return res.toString();
}
public static void main(String[] args) {
URLGetter URLGetter1 = new URLGetter();
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment