Download Latest Version shoshone_http_client_v1.97_library_with_source.7z (118.7 kB)
Email in envelope

Get an email when there's a new version of Shoshone

Home
Name Modified Size InfoDownloads / Week
shoshone_http_client_v1.97_library_with_source.7z 2014-04-09 118.7 kB
README 2013-09-25 1.3 kB
EUPL v.1.1 - Licence.pdf 2011-11-05 34.3 kB
GNU_General_Public_License_v2 2011-11-05 18.1 kB
GNU_General_Public_License_v3 2011-11-05 35.1 kB
Totals: 5 Items   207.5 kB 1
license:
	GNU General Public License v2 or v3 (outside EU only)
	European Union Public License (inside EU)
	

build path:
	- first include all jar files

examples:

	- get webpage
	-----------
	ShoshoneClient sc = new ShoshoneClient("http://www.google.com");
	sc.applyGetRequest(); // fetches the webpage, e.g. google.com
	String html = sc.getResponse(); // get html document as string
	Set<Cookie> cookies = sc.getCookies(); // get the cookies as Set


	- perform login via "post" method
	-------------------------------
	ShoshoneClient sc = new ShoshoneClient("http://www.imagebanana.com/member/"); // login, e.g. on Imagebanana
	List<PostParameter> params = new LinkedList<PostParameter>();
	params.add(new PostParameter("member_nick","myusername")); // add post parameter
	params.add(new PostParameter("member_password","mypassword")); // add post parameter
	sc.applyPostRequest(params); // perform login
	Set<Cookie> cookies = sc.getCookies(); // get (login) cookies
	
	
	- download
	----------
	ShoshoneClient sc = new ShoshoneClient("http://sourceforge.net/projects/binfile2imgconv/files/latest/download?source=files");
	sc.applyGetRequest(false); // fetches the response header first
	sc.readResponseAndSave(Paths.get(sc.getFilename()); // save to disk
	
Source: README, updated 2013-09-25