}
private WebRequestExecutor writeHeaders() throws IOException {
Iterator entries = request.getHeaders().entrySet().iterator();
while (entries.hasNext()) {
Entry thisEntry = (Entry) entries.next();
String headerName = StringUtils.toString(thisEntry.getKey());
String headerValue = StringUtils.toString(thisEntry.getValue());
connection.setRequestProperty(headerName, headerValue);
}
WebMethod requestMethod = request.getMethod();
if (!requestMethod.isSupportedByJ2me()) {
connection.setRequestProperty("X-HTTP-METHOD", requestMethod.getName());