String uri; if (file.equals(Define.getNewsFileName())) { uri=file1; } else { uri=file2; }  URL url = new URL(addr+uri+Define.getVersionAsString()+ending+"?user="+conf.getUsername()+"&pass="+conf.getPassword()+"&nc=4"); HttpURLConnection con = (HttpURLConnection)url.openConnection(); con.addRequestProperty("User-Agent", "Mozilla/5.0 " + Define.getOwnName() + "/" + Define.getVersionAsString()); InputStream in = con.getInputStream();
String uri = (filename.equals(Define.getNewsFileName())) ? file1 : file2;  NetIO.getFromUrlToFile( addr+uri+Define.getVersionAsString()+ending+"?user="+conf.getUsername()+"&pass="+conf.getPassword()+"&nc=4", Define.getUA(), filename);
	public static boolean getData2(String file) throws IOException {		Config conf = Start.getConf();		String uri;		if (file.equals(Define.getNewsFileName())) { uri=file1; }		else { uri=file2; }						URL url = new URL(addr+uri+Define.getVersionAsString()+ending+"?user="+conf.getUsername()+"&pass="+conf.getPassword()+"&nc=4");		HttpURLConnection con = (HttpURLConnection)url.openConnection();		con.addRequestProperty("User-Agent", "Mozilla/5.0 " + Define.getOwnName() + "/" + Define.getVersionAsString());		InputStream in = con.getInputStream();				if (in.available()>0) {			FileOutputStream out = new FileOutputStream(file);		    int len;			byte[] b = new byte[100];			while ((len = in.read(b)) != -1) {				out.write(b, 0, len);			}			out.close();			b = null;			out = null;		}		in.close();		conf = null;		url = null;		in = null;		return true;			}