docs(API): 翻译完了 common/http

This commit is contained in:
Zhicheng Wang 2018-09-04 15:04:47 +08:00
parent 719650b41f
commit 3819d7de3b
2 changed files with 13 additions and 2 deletions

View File

@ -65,13 +65,13 @@
[x] | common/JsonPipe | 0.25
[x] | forms/FormArray | 0.25
[x] | common/CommonModule | 0.24
[ ] | router/NavigationExtras | 0.24
[x] | router/NavigationExtras | 0.24
[x] | core/HostBinding | 0.23
[x] | core/ContentChild | 0.22
[x] | core/ViewChildren | 0.22
[x] | common/http/HttpResponse | 0.22
[x] | router/ActivatedRouteSnapshot | 0.22
[ ] | common/http | 0.21
[x] | common/http | 0.21
[ ] | core/ChangeDetectorRef | 0.21
[ ] | router/NavigationStart | 0.21
[ ] | common/formatDate | 0.21

View File

@ -14,12 +14,18 @@ import {HttpEvent} from './response';
* Transforms an `HttpRequest` into a stream of `HttpEvent`s, one of which will likely be a
* `HttpResponse`.
*
* `HttpRequest` `HttpEvent` `HttpResponse`
*
* `HttpHandler` is injectable. When injected, the handler instance dispatches requests to the
* first interceptor in the chain, which dispatches to the second, etc, eventually reaching the
* `HttpBackend`.
*
* `HttpHandler`
* `HttpBackend`
*
* In an `HttpInterceptor`, the `HttpHandler` parameter is the next interceptor in the chain.
*
* `HttpInterceptor` `HttpHandler`
*
*/
export abstract class HttpHandler {
@ -29,11 +35,16 @@ export abstract class HttpHandler {
/**
* A final `HttpHandler` which will dispatch the request via browser HTTP APIs to a backend.
*
* `HttpHandler` HTTP API
*
* Interceptors sit between the `HttpClient` interface and the `HttpBackend`.
*
* `HttpClient` `HttpBackend`
*
* When injected, `HttpBackend` dispatches requests directly to the backend, without going
* through the interceptor chain.
*
* `HttpBackend`
*
*/
export abstract class HttpBackend implements HttpHandler {