Here you can find the source of renderRequest(URLConnection connection)
Parameter | Description |
---|---|
connection | a parameter |
private static void renderRequest(URLConnection connection)
//package com.java2s; //License from project: Apache License import java.net.*; public class Main { private static Integer connectTimeout = null; private static Integer socketTimeout = null; /**/*from ww w . j a va 2 s .c o m*/ * Render request according setting * * @param connection */ private static void renderRequest(URLConnection connection) { if (connectTimeout != null) { connection.setConnectTimeout(connectTimeout); } if (socketTimeout != null) { connection.setReadTimeout(socketTimeout); } } }