LEFT | RIGHT |
1 /* | 1 /* |
2 * Copyright (c) 2010 Google Inc. | 2 * Copyright (c) 2010 Google Inc. |
3 * | 3 * |
4 * Licensed under the Apache License, Version 2.0 (the "License"); you may not u
se this file except | 4 * Licensed under the Apache License, Version 2.0 (the "License"); you may not u
se this file except |
5 * in compliance with the License. You may obtain a copy of the License at | 5 * in compliance with the License. You may obtain a copy of the License at |
6 * | 6 * |
7 * http://www.apache.org/licenses/LICENSE-2.0 | 7 * http://www.apache.org/licenses/LICENSE-2.0 |
8 * | 8 * |
9 * Unless required by applicable law or agreed to in writing, software distribut
ed under the License | 9 * Unless required by applicable law or agreed to in writing, software distribut
ed under the License |
10 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY K
IND, either express | 10 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY K
IND, either express |
11 * or implied. See the License for the specific language governing permissions a
nd limitations under | 11 * or implied. See the License for the specific language governing permissions a
nd limitations under |
12 * the License. | 12 * the License. |
13 */ | 13 */ |
14 | 14 |
15 package com.google.api.client.http.javanet; | 15 package com.google.api.client.http.javanet; |
16 | 16 |
17 import com.google.api.client.http.HttpTransport; | 17 import com.google.api.client.http.HttpTransport; |
18 | 18 |
19 import java.io.IOException; | 19 import java.io.IOException; |
20 | 20 |
21 /** | 21 /** |
22 * Thread-safe HTTP low-level transport based on the {@code java.net} package. | 22 * Thread-safe HTTP low-level transport based on the {@code java.net} package. |
23 * | 23 * |
24 * <p> | 24 * <p> |
25 * Users should consider modifying the alive property on {@link NetHttpTransport
} to control | 25 * Users should consider modifying the keep alive property on {@link NetHttpTran
sport} to control |
26 * whether the socket should be returned to a pool of connected sockets. | 26 * whether the socket should be returned to a pool of connected sockets. More in
formation is |
| 27 * available <a |
| 28 * href='http://docs.oracle.com/javase/7/docs/technotes/guides/net/http-keepaliv
e.html'>here</a>. |
27 * </p> | 29 * </p> |
28 * | 30 * |
29 * <p> | 31 * <p> |
30 * Implementation is thread-safe. For maximum efficiency, applications should us
e a single | 32 * Implementation is thread-safe. For maximum efficiency, applications should us
e a single |
31 * globally-shared instance of the HTTP transport. | 33 * globally-shared instance of the HTTP transport. |
32 * </p> | 34 * </p> |
33 * | 35 * |
34 * @since 1.0 | 36 * @since 1.0 |
35 * @author Yaniv Inbar | 37 * @author Yaniv Inbar |
36 */ | 38 */ |
(...skipping 22 matching lines...) Expand all Loading... |
59 @Override | 61 @Override |
60 public NetHttpRequest buildPostRequest(String url) throws IOException { | 62 public NetHttpRequest buildPostRequest(String url) throws IOException { |
61 return new NetHttpRequest("POST", url); | 63 return new NetHttpRequest("POST", url); |
62 } | 64 } |
63 | 65 |
64 @Override | 66 @Override |
65 public NetHttpRequest buildPutRequest(String url) throws IOException { | 67 public NetHttpRequest buildPutRequest(String url) throws IOException { |
66 return new NetHttpRequest("PUT", url); | 68 return new NetHttpRequest("PUT", url); |
67 } | 69 } |
68 } | 70 } |
LEFT | RIGHT |