private Put updateRoute(int routeKey, String category, Integer fileKey, String description,
String authenticationUserName, String authenticationPassword) throws IOException, JAXBException {
String xml = createRouteXml(category, fileKey, description);
Put request = new Put(ROUTES_URL + routeKey + GPX_URL_POSTFIX, new SimpleCredentials(authenticationUserName, authenticationPassword));
request.addFile("file", xml.getBytes());
return request;
}
private Put updateRoute(int routeKey, String category, Integer fileKey, String description) throws IOException, JAXBException {
return updateRoute(routeKey, category, fileKey, description, USERNAME, PASSWORD);