Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(138)

Side by Side Diff: pkg/http_server/README.md

Issue 51003002: Update headings to use sentence case. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « pkg/html_import/README.md ('k') | pkg/polymer_expressions/README.md » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 Library of HTTP server classes. 1 Library of HTTP server classes.
2 2
3 This package contains a set of high-level classes that, together with 3 This package contains a set of high-level classes that, together with
4 HttpServer, makes is easy to provide content through HTTP servers. 4 HttpServer, makes is easy to provide content through HTTP servers.
5 5
6 ## Virtual Directory 6 ## Virtual directory
7 7
8 The VirtualDirectory class makes it possible to easy serve static content from 8 The VirtualDirectory class makes it possible to easy serve static content from
9 the drive. It supports: 9 the drive. It supports:
10 10
11 * Range-based request, making it possible to pause/resume downloads and stream 11 * Range-based request, making it possible to pause/resume downloads and stream
12 videos. 12 videos.
13 * If-Modified-Since based caching. 13 * If-Modified-Since based caching.
14 * Automatic GZip-compression of content. 14 * Automatic GZip-compression of content.
15 * Ability to follow links within, either throughout the system or in a jailed 15 * Ability to follow links within, either throughout the system or in a jailed
16 root. 16 root.
17 * Optional directory listing. 17 * Optional directory listing.
18 18
19 The following example shows how to set up a Virtual Directory of a given path 19 The following example shows how to set up a Virtual Directory of a given path
20 20
21 var virtualDirectory = new VirtualDirectory('/var/www/'); 21 var virtualDirectory = new VirtualDirectory('/var/www/');
22 virtualDirectory.serve(new HttpServer('0.0.0.0', 8080)); 22 virtualDirectory.serve(new HttpServer('0.0.0.0', 8080));
23 23
24 See [VirtualDirectory]( 24 See [VirtualDirectory](
25 http://api.dartlang.org/docs/http_server/VirtualDirectory.html) 25 http://api.dartlang.org/docs/http_server/VirtualDirectory.html)
26 for more info about how to customize the class. 26 for more info about how to customize the class.
27 27
28 ## Virtual Host 28 ## Virtual host
29 29
30 The VirtualHost class makes it possible to serve multiple hosts on the same 30 The VirtualHost class makes it possible to serve multiple hosts on the same
31 address, by using the `Host` field of the incoming requests. It also provides 31 address, by using the `Host` field of the incoming requests. It also provides
32 the ability to work on wildcards for sub-domains. 32 the ability to work on wildcards for sub-domains.
33 33
34 var virtualHost = new VirtualHost(server); 34 var virtualHost = new VirtualHost(server);
35 // Filter out on a specific host 35 // Filter out on a specific host
36 var stream1 = virtualServer.addHost('static.myserver.com'); 36 var stream1 = virtualServer.addHost('static.myserver.com');
37 // Wildcard for any other sub-domains. 37 // Wildcard for any other sub-domains.
38 var stream2 = virtualServer.addHost('*.myserver.com'); 38 var stream2 = virtualServer.addHost('*.myserver.com');
39 // Requets not matching any hosts. 39 // Requets not matching any hosts.
40 var stream3 = virtualServer.unhandled; 40 var stream3 = virtualServer.unhandled;
41 41
42 See [VirtualHost]( 42 See [VirtualHost](
43 http://api.dartlang.org/docs/http_server/VirtualHost.html) 43 http://api.dartlang.org/docs/http_server/VirtualHost.html)
44 for more information. 44 for more information.
OLDNEW
« no previous file with comments | « pkg/html_import/README.md ('k') | pkg/polymer_expressions/README.md » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698