|
|
@@ -155,6 +155,14 @@ public class CHttpHandler implements URIHandler {
|
|
|
c.connect();
|
|
|
return c.getOutputStream();
|
|
|
}
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public Reader reader(URIHandle ustream, Charset cs) throws IOException {
|
|
|
+ HttpURLConnection c = connect(ustream);
|
|
|
+ c.setRequestMethod("GET");
|
|
|
+ c.connect();
|
|
|
+ return new InputStreamReader(c.getInputStream(), cs);
|
|
|
+ }
|
|
|
|
|
|
@Override
|
|
|
public Reader reader(URIHandle ustream) throws IOException {
|
|
|
@@ -164,6 +172,14 @@ public class CHttpHandler implements URIHandler {
|
|
|
return new InputStreamReader(c.getInputStream(), getContentCharset(c.getContentType()));
|
|
|
}
|
|
|
|
|
|
+ @Override
|
|
|
+ public Writer writer(URIHandle ustream, Charset cs) throws IOException {
|
|
|
+ HttpURLConnection c = connect(ustream);
|
|
|
+ c.setRequestMethod("PUT");
|
|
|
+ c.connect();
|
|
|
+ return new OutputStreamWriter(c.getOutputStream(), cs);
|
|
|
+ }
|
|
|
+
|
|
|
@Override
|
|
|
public Writer writer(URIHandle ustream) throws IOException {
|
|
|
HttpURLConnection c = connect(ustream);
|