code: @SuppressWarnings("unchecked")
  	private <T extends Resource> T submit(Form form, Parameters parameters) {
  		RequestBuilder<Resource> request = doRequest(form.getUri()).set(parameters);
  		boolean doPost = form.isDoPost();
  		boolean multiPart = form.isMultiPart();
  		if(doPost && multiPart) {
  			request.multiPart();
  			addFiles(request, form);
  		}
  		return (T) (doPost ? request.post() : request.get()); 
  	}
docs: Returns the page object received as response to the form submit action.