matyr #4988(2007/12/27 04:08 GMT) [ JavaScript ] Rating0/0=0.00
Java / Scala とほぼ同じ。
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
importPackage(java.net); importPackage(java.io); (function doukaku113(prox, timeout, port){ port || (port = 8080); prox = new Proxy(Proxy.Type.HTTP, new InetSocketAddress(prox, port)); with(new URL('http://ja.doukaku.org/feeds/comments/').openConnection(prox)) try{ setConnectTimeout(timeout); setReadTimeout(timeout); connect(); with(new BufferedReader(new InputStreamReader(getInputStream(), 'UTF-8'))) for(var b; b = readLine();) print(b); } catch(e){ print(e) } return arguments.callee; })( 'localhost', 1000 // => <?xml version="1.0" ... )( 'localhost', 100 // => JavaException: java.net.SocketTimeoutException: Read timed out );
Rating0/0=0.00-0+
[ reply ]
matyr
#4988()
[
JavaScript
]
Rating0/0=0.00
Java / Scala とほぼ同じ。
Rating0/0=0.00-0+
[ reply ]