private void addHttpMethod(ByteArrayOutputStream outputStream, String verb,
            URI uri) {
        try {
            String method = String.format("%s %s HTTP/1.1\r\n", verb, uri);
            outputStream.write(method.getBytes("UTF-8"));
        } catch (UnsupportedEncodingException e) {
            throw new RuntimeException(e);
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }
private void addHttpMethod ( ByteArrayOutputStream outputStream , String verb , URI uri ) { try { String method = String . format ( "%s %s HTTP/1.1\r\n" , verb , uri ) ; outputStream . write ( method . getBytes ( "UTF-8" ) ) ; } catch ( UnsupportedEncodingException e ) { throw new RuntimeException ( e ) ; } catch ( IOException e ) { throw new RuntimeException ( e ) ; } }
Adds the http method.

@param outputStream
the output stream
@param verb
the verb
@param uri
the uri