I wrote a code to establish an HttpsUrlConnection
and setRequestMethod
as PUT
. While debugging I see the method as GET
. My SetRequestMethod
is not working. I don't know why HttpsUrlConnection
method in default GET
.
My code looks like this
DisbleSSL disble = new DisbleSSL();
disble.disableSSLVerification();
URL url = new URL(url_string);
httpsUrlConnection = (HttpsURLConnection) url.openConnection();
httpsUrlConnection.setDoOutput(true);
httpsUrlConnection.setRequestMethod("PUT");
httpsUrlConnection.connect();
HttpsUrlConnection definitely support setrequestMethod.Actually but it may be Wrong Labled in Debugg console.