Code example for FileEntity

	private static FileEntity createFileEntity(final String filePath, final String contentType) {
		File file = new File(filePath);
		FileEntity fileEntity = new FileEntity(file, contentType);
		return fileEntity;
	private static Header[] createHeaders() {
		return new Header[] {
				new BasicHeader("Accept-Charset", "UTF-8"),
				new BasicHeader("DataServiceVersion", "1.0;NetFx"),
				new BasicHeader("MaxDataServiceVersion", "2.0;NetFx"),
				new BasicHeader("Accept", "application/json;odata=verbose"),
				new BasicHeader("Host", "localhost"),
				new BasicHeader("Expect", "100-continue"),
				new BasicHeader("User-Agent",
						"Mozilla/5.0 (X11; U; Linux i686; en-US; rv: Gecko/20100316 Firefox/3.6.2") }; 
Connect your IDE to all the code out there  Get Codota for Java