source: josm/trunk/src/oauth/signpost/basic/UrlStringRequestAdapter.java@ 4231

Last change on this file since 4231 was 4231, checked in by stoecker, 13 years ago

add signpost and metadata extractor code to repository directly

File size: 990 bytes
Line 
1package oauth.signpost.basic;
2
3import java.io.IOException;
4import java.io.InputStream;
5import java.util.Collections;
6import java.util.Map;
7
8import oauth.signpost.http.HttpRequest;
9
10public class UrlStringRequestAdapter implements HttpRequest {
11
12 private String url;
13
14 public UrlStringRequestAdapter(String url) {
15 this.url = url;
16 }
17
18 public String getMethod() {
19 return "GET";
20 }
21
22 public String getRequestUrl() {
23 return url;
24 }
25
26 public void setRequestUrl(String url) {
27 this.url = url;
28 }
29
30 public void setHeader(String name, String value) {
31 }
32
33 public String getHeader(String name) {
34 return null;
35 }
36
37 public Map<String, String> getAllHeaders() {
38 return Collections.emptyMap();
39 }
40
41 public InputStream getMessagePayload() throws IOException {
42 return null;
43 }
44
45 public String getContentType() {
46 return null;
47 }
48
49 public Object unwrap() {
50 return url;
51 }
52}
Note: See TracBrowser for help on using the repository browser.