Accessing File Over A Network Using Service Account in Java
问题 I am trying to read a file from a network location using Java.The problem is that the access to that network location requires specific credentials. Is there any way to specify these credentials in Java and then access teh file over the network. I am trying to do this from my web application which is running on Weblogic Thanks, Abhishek 回答1: Here is a sample code. try { URL url = new URL("https://www.visruthcv.appspot.com"); URLConnection con = url.openConnection(); HttpURLConnection