diff --git a/collects/web-server/docs/doc-installer.ss b/collects/web-server/docs/doc-installer.ss deleted file mode 100644 index 0aeea77783..0000000000 --- a/collects/web-server/docs/doc-installer.ss +++ /dev/null @@ -1,22 +0,0 @@ -(module doc-installer mzscheme - (require (lib "dirs.ss" "setup") - (lib "to-html.ss" "scribblings") - (prefix ref: "reference/reference.scrbl") - (prefix guide: "guide/guide.scrbl")) - - (provide post-installer) - - (define post-installer - (lambda (path) - (let ([doc (find-doc-dir)]) - (when doc - (build))))) - - (define (build) - (to-html #t #t - (list ref:doc - guide:doc) - (list "web-server-reference" - "web-server-guide"))) - - (build)) \ No newline at end of file diff --git a/collects/web-server/docs/guide/guide.scrbl b/collects/web-server/docs/guide/web-guide.scrbl similarity index 100% rename from collects/web-server/docs/guide/guide.scrbl rename to collects/web-server/docs/guide/web-guide.scrbl diff --git a/collects/web-server/docs/reference/configuration.scrbl b/collects/web-server/docs/reference/configuration.scrbl index e08699de2b..321904dcc8 100644 --- a/collects/web-server/docs/reference/configuration.scrbl +++ b/collects/web-server/docs/reference/configuration.scrbl @@ -11,8 +11,9 @@ configuring the @web-server . @; ------------------------------------------------------------ @section[#:tag "configuration-table-structs.ss"]{Configuration Table Structure} +@require[(for-label web-server/configuration/configuration-table-structs)] -@file{configuration/configuration-table-structs.ss} provides the following structures that +@filepath{configuration/configuration-table-structs.ss} provides the following structures that represent a standard configuration (see @secref["web-server-unit.ss"]) of the @web-server . The contracts on this structure influence the valid types of values in the configuration table S-expression file format described in @@ -78,8 +79,9 @@ the configuration table S-expression file format described in @; ------------------------------------------------------------ @section[#:tag "configuration-table.ss"]{Configuration Table} +@require[(for-label web-server/configuration/configuration-table)] -@file{configuration/configuration-table.ss} provides functions for +@filepath{configuration/configuration-table.ss} provides functions for reading, writing, parsing, and printing @scheme[configuration-table] structures. @@ -148,10 +150,11 @@ This function writes a @scheme[configuration-table] to @scheme[path]. @; ------------------------------------------------------------ @section[#:tag "namespace.ss"]{Servlet Namespaces} +@require[(for-label web-server/configuration/namespace)] -@file{configuration/namespace.ss} provides a function to help create the +@filepath{configuration/namespace.ss} provides a function to help create the @scheme[make-servlet-namespace] procedure needed by the @scheme[make] functions -of @file{dispatchers/dispatch-servlets.ss} and @file{dispatchers/dispatch-lang.ss}. +of @filepath{dispatchers/dispatch-servlets.ss} and @filepath{dispatchers/dispatch-lang.ss}. @; XXX Define make-servlet-namespace? @; XXX Use actual keyword argument syntax @@ -188,8 +191,9 @@ of servlets can share different sets of modules. @; ------------------------------------------------------------ @section[#:tag "responders.ss"]{Standard Responders} +@require[(for-label web-server/configuration/responders)] -@file{configuration/responders.ss} provides some functions that help constructing HTTP responders. +@filepath{configuration/responders.ss} provides some functions that help constructing HTTP responders. These functions are used by the default dispatcher constructor (see @secref["web-server-unit.ss"]) to turn the paths given in the @scheme[configuration-table] into responders for the associated circumstance. diff --git a/collects/web-server/docs/reference/dispatchers.scrbl b/collects/web-server/docs/reference/dispatchers.scrbl index e3277cae30..698a8a5417 100644 --- a/collects/web-server/docs/reference/dispatchers.scrbl +++ b/collects/web-server/docs/reference/dispatchers.scrbl @@ -15,8 +15,9 @@ documentation will be useful. @; ------------------------------------------------------------ @section[#:tag "dispatch.ss"]{General} +@require[(for-label web-server/dispatchers/dispatch)] -@file{dispatchers/dispatch.ss} provides a few functions for dispatchers in general. +@filepath{dispatchers/dispatch.ss} provides a few functions for dispatchers in general. @defthing[dispatcher? contract?]{ Equivalent to @scheme[(connection? request? . -> . void)]. @@ -57,8 +58,9 @@ Consider the following example dispatcher, that captures the essence of URL rewr @; ------------------------------------------------------------ @section[#:tag "filesystem-map.ss"]{Mapping URLs to Paths} +@require[(for-label web-server/dispatchers/filesystem-map)] -@file{dispatchers/filesystem-map.ss} provides a means of mapping +@filepath{dispatchers/filesystem-map.ss} provides a means of mapping URLs to paths on the filesystem. @defthing[url-path? contract?]{ @@ -85,8 +87,9 @@ URLs to paths on the filesystem. @; ------------------------------------------------------------ @section[#:tag "dispatch-sequencer.ss"]{Sequencing} +@require[(prefix-in seq: (for-label web-server/dispatchers/dispatch-sequencer))] -@file{dispatchers/dispatch-sequencer.ss} defines a dispatcher constructor +@filepath{dispatchers/dispatch-sequencer.ss} defines a dispatcher constructor that invokes a sequence of dispatchers until one applies. @defproc[(make (dispatcher dispatcher?) ...) @@ -99,8 +102,9 @@ that invokes a sequence of dispatchers until one applies. @; XXX Kind of timeout that is proportional to bindings @; ------------------------------------------------------------ @section[#:tag "dispatch-timeout.ss"]{Timeouts} +@require[(prefix-in timeout: (for-label web-server/dispatchers/dispatch-timeout))] -@file{dispatchers/dispatch-timeout.ss} defines a dispatcher constructor +@filepath{dispatchers/dispatch-timeout.ss} defines a dispatcher constructor that changes the timeout on the connection and calls the next dispatcher. @@ -112,8 +116,9 @@ dispatcher. @; ------------------------------------------------------------ @section[#:tag "dispatch-lift.ss"]{Lifting Procedures} +@require[(prefix-in lift: (for-label web-server/dispatchers/dispatch-lift))] -@file{dispatchers/dispatch-lift.ss} defines: +@filepath{dispatchers/dispatch-lift.ss} defines: @defproc[(make (proc (request? . -> . response?))) dispatcher?]{ @@ -124,8 +129,9 @@ dispatcher. @; XXX Change filtering to take predicate, rather than regexp @; ------------------------------------------------------------ @section[#:tag "dispatch-filter.ss"]{Filtering Requests} +@require[(prefix-in filter: (for-label web-server/dispatchers/dispatch-filter))] -@file{dispatchers/dispatch-filter.ss} defines a dispatcher constructor +@filepath{dispatchers/dispatch-filter.ss} defines a dispatcher constructor that calls an underlying dispatcher with all requests that pass a predicate. @@ -137,8 +143,9 @@ with all requests that pass a predicate. @; ------------------------------------------------------------ @section[#:tag "dispatch-pathprocedure.ss"]{Procedure Invocation upon Request} +@require[(prefix-in pathproc: (for-label web-server/dispatchers/dispatch-pathprocedure))] -@file{dispatchers/dispatch-pathprocedure.ss} defines a dispatcher constructor +@filepath{dispatchers/dispatch-pathprocedure.ss} defines a dispatcher constructor for invoking a particular procedure when a request is given to a particular URL path. @@ -153,8 +160,9 @@ a URL that refreshes the password file, servlet cache, etc. @; ------------------------------------------------------------ @section[#:tag "dispatch-log.ss"]{Logging} +@require[(prefix-in log: (for-label web-server/dispatchers/dispatch-log))] -@file{dispatchers/dispatch-log.ss} defines a dispatcher constructor +@filepath{dispatchers/dispatch-log.ss} defines a dispatcher constructor for transparent logging of requests. @defthing[format-req/c contract?]{ @@ -205,8 +213,9 @@ for transparent logging of requests. @; ------------------------------------------------------------ @section[#:tag "dispatch-passwords.ss"]{Password Protection} +@require[(prefix-in passwords: (for-label web-server/dispatchers/dispatch-passwords))] -@file{dispatchers/dispatch-passwords.ss} defines a dispatcher constructor +@filepath{dispatchers/dispatch-passwords.ss} defines a dispatcher constructor that performs HTTP Basic authentication filtering. @defproc[(make [#:password-file password-file path-string? "passwords"] @@ -240,8 +249,9 @@ that performs HTTP Basic authentication filtering. @; ------------------------------------------------------------ @section[#:tag "dispatch-host.ss"]{Virtual Hosts} +@require[(prefix-in host: (for-label web-server/dispatchers/dispatch-host))] -@file{dispatchers/dispatch-host.ss} defines a dispatcher constructor +@filepath{dispatchers/dispatch-host.ss} defines a dispatcher constructor that calls a different dispatcher based upon the host requested. @defproc[(make (lookup-dispatcher (symbol? . -> . dispatcher?))) @@ -254,8 +264,9 @@ that calls a different dispatcher based upon the host requested. @; ------------------------------------------------------------ @section[#:tag "dispatch-files.ss"]{Serving Files} +@require[(prefix-in files: (for-label web-server/dispatchers/dispatch-files))] -@file{dispatchers/dispatch-files.ss} allows files to be served. +@filepath{dispatchers/dispatch-files.ss} allows files to be served. It defines a dispatcher construction procedure: @defproc[(make [#:url->path url->path url->path?] @@ -274,8 +285,9 @@ It defines a dispatcher construction procedure: @; ------------------------------------------------------------ @section[#:tag "dispatch-servlets.ss"]{Serving Scheme Servlets} +@require[(prefix-in servlets: (for-label web-server/dispatchers/dispatch-servlets))] -@file{dispatchers/dispatch-servlets.ss} defines a dispatcher constructor +@filepath{dispatchers/dispatch-servlets.ss} defines a dispatcher constructor that runs servlets written in Scheme. @; XXX Remove config:scripts @@ -316,8 +328,9 @@ that runs servlets written in Scheme. @; ------------------------------------------------------------ @section[#:tag "dispatch-lang.ss"]{Serving Web Language Servlets} +@require[(prefix-in lang: (for-label web-server/dispatchers/dispatch-lang))] -@file{dispatchers/dispatch-lang.ss} defines a dispatcher constructor +@filepath{dispatchers/dispatch-lang.ss} defines a dispatcher constructor that runs servlets written in the Web Language. @defproc[(make [#:url->path url->path url->path?] @@ -338,8 +351,9 @@ that runs servlets written in the Web Language. @; ------------------------------------------------------------ @section[#:tag "dispatch-stat.ss"]{Statistics} +@require[(prefix-in stat: (for-label web-server/dispatchers/dispatch-stat))] -@file{dispatchers/dispatch-stat.ss} provides services related to performance +@filepath{dispatchers/dispatch-stat.ss} provides services related to performance statistics. @defproc[(make-gc-thread [time integer?]) diff --git a/collects/web-server/docs/reference/lang.scrbl b/collects/web-server/docs/reference/lang.scrbl index 0ebdeefc67..fa3b7e0fff 100644 --- a/collects/web-server/docs/reference/lang.scrbl +++ b/collects/web-server/docs/reference/lang.scrbl @@ -26,23 +26,22 @@ the following identifier: @; ------------------------------------------------------------ @section[#:tag "considerations"]{Usage Considerations} - A servlet has the following process performed on it automatically: @itemize[ @item{All uses of @scheme[letrec] are removed and replaced with equivalent uses of - @scheme[let] and imperative features. (@file{lang/elim-letrec.ss})} + @scheme[let] and imperative features. (@filepath{lang/elim-letrec.ss})} @item{The program is converted into ANF (Administrative Normal Form), - making all continuations explicit. (@file{lang/anormal.ss})} + making all continuations explicit. (@filepath{lang/anormal.ss})} @item{All continuations (and other continuations marks) are recorded in the continuation marks of the expression - they are the continuation of. (@file{lang/elim-callcc.ss})} + they are the continuation of. (@filepath{lang/elim-callcc.ss})} @item{All calls to external modules are identified and marked. - (@file{lang/elim-callcc.ss})} + (@filepath{lang/elim-callcc.ss})} @item{All uses of @scheme[call/cc] are removed and replaced with equivalent gathering of the continuations through the continuation-marks. - (@file{lang/elim-callcc.ss})} + (@filepath{lang/elim-callcc.ss})} @item{The program is defunctionalized with a serializable data-structure for each - anonymous lambda. (@file{lang/defun.ss})} + anonymous lambda. (@filepath{lang/defun.ss})} ] This process allows the continuations captured by your servlet to be serialized. @@ -100,8 +99,9 @@ by the Web language API. @; ------------------------------------------------------------ @section[#:tag "lang/web.ss"]{Web} +@require[(for-label web-server/lang/web)] -@file{lang/web.ss} provides the most basic Web functionality. +@filepath{lang/web.ss} provides the most basic Web functionality. @defproc[(send/suspend/url [response-generator (url? . -> . response?)]) request?]{ @@ -139,8 +139,9 @@ by the Web language API. @; ------------------------------------------------------------ @section[#:tag "lang/stuff-url.ss"]{Stuff URL} +@require[(for-label web-server/lang/stuff-url)] -@file{lang/stuff-url.ss} provides an interface for "stuffing" +@filepath{lang/stuff-url.ss} provides an interface for "stuffing" serializable values into URLs. Currently there is a particular hard-coded behavior, but we hope to make it more flexible in the future. @@ -150,7 +151,7 @@ the future. url?]{ Serializes @scheme[v] and computes the MD5 of the serialized representation. The serialization of @scheme[v] is written to - @file{$HOME/.urls/M} where `M' is the MD5. `M' is then + @filepath{$HOME/.urls/M} where `M' is the MD5. `M' is then placed in @scheme[u] as a URL param. } @@ -174,18 +175,20 @@ In the future, we will offer the facilities to: @; ------------------------------------------------------------ @section[#:tag "lang/web-extras.ss"]{Web Extras} +@require[(for-label web-server/lang/web-extras)] -@file{lang/web-extras.ss} provides @scheme[send/suspend/dispatch] and +@filepath{lang/web-extras.ss} provides @scheme[send/suspend/dispatch] and @scheme[redirect/get] as @secref["web.ss"], except they use @scheme[embed-proc/url] + @scheme[extract-proc/url] and @scheme[send/suspend/url] respectively. @; ------------------------------------------------------------ @section[#:tag "lang/file-box.ss"]{File Boxes} +@require[(for-label web-server/lang/file-box)] As mentioned earlier, it is dangerous to rely on the store in Web Language servlets, due to the deployment scenarios available -to them. @file{lang/file-box.ss} provides a simple API to replace +to them. @filepath{lang/file-box.ss} provides a simple API to replace boxes in a safe way. @defproc[(file-box? [v any/c]) @@ -219,9 +222,10 @@ are on a shared medium.} @; ------------------------------------------------------------ @section[#:tag "lang/web-param.ss"]{Web Parameters} +@require[(for-label web-server/lang/web-param)] As mentioned earlier, it is not easy to use @scheme[parameterize] in the -Web Language. @file{lang/web-param.ss} provides (roughly) the same +Web Language. @filepath{lang/web-param.ss} provides (roughly) the same functionality in a way that is serializable. Like other serializable things in the Web Language, they are sensitive to source code modification. @@ -246,7 +250,8 @@ things in the Web Language, they are sensitive to source code modification. @; ------------------------------------------------------------ @section[#:tag "lang/web-cells.ss"]{Web Cells} +@require[(for-label web-server/lang/web-cells)] -@file{lang/web-cells.ss} provides the same API as @secref["web-cells.ss"], +@filepath{lang/web-cells.ss} provides the same API as @secref["web-cells.ss"], but in a way compatible with the Web Language. The one difference is that @scheme[make-web-cell] is syntax, rather than a function. diff --git a/collects/web-server/docs/reference/managers.scrbl b/collects/web-server/docs/reference/managers.scrbl index 847ccf0db9..293ea7c03a 100644 --- a/collects/web-server/docs/reference/managers.scrbl +++ b/collects/web-server/docs/reference/managers.scrbl @@ -15,8 +15,9 @@ pluggable through the manager interface. @; ------------------------------------------------------------ @section[#:tag "manager.ss"]{General} +@require[(for-label web-server/managers/manager)] -@file{managers/manager.ss} defines the manager interface. It is required by +@filepath{managers/manager.ss} defines the manager interface. It is required by the users and implementers of managers. @defstruct[manager ([create-instance ((-> void) . -> . number?)] @@ -62,8 +63,9 @@ the users and implementers of managers. @; ------------------------------------------------------------ @section[#:tag "none.ss"]{No Continuations} +@require[(for-label web-server/managers/none)] -@file{managers/none.ss} defines a manager constructor: +@filepath{managers/none.ss} defines a manager constructor: @defproc[(create-none-manager (instance-expiration-handler expiration-handler?)) manager?]{ @@ -78,8 +80,9 @@ Web Language. (See @secref["lang"].) @; ------------------------------------------------------------ @section[#:tag "timeouts.ss"]{Timeouts} +@require[(for-label web-server/managers/timeouts)] -@file{managers/timeouts.ss} defines a manager constructor: +@filepath{managers/timeouts.ss} defines a manager constructor: @defproc[(create-timeout-manager [instance-exp-handler expiration-handler?] [instance-timeout number?] @@ -105,8 +108,9 @@ deployments of the @web-server . @; ------------------------------------------------------------ @section[#:tag "lru.ss"]{LRU} +@require[(for-label web-server/managers/lru)] -@file{managers/lru.ss} defines a manager constructor: +@filepath{managers/lru.ss} defines a manager constructor: @defproc[(create-LRU-manager [instance-expiration-handler expiration-handler?] diff --git a/collects/web-server/docs/reference/private.scrbl b/collects/web-server/docs/reference/private.scrbl index 6a4e3cf883..03b448be82 100644 --- a/collects/web-server/docs/reference/private.scrbl +++ b/collects/web-server/docs/reference/private.scrbl @@ -13,8 +13,9 @@ Some of these are documented here. @; ------------------------------------------------------------ @section[#:tag "timer.ss"]{Timers} +@require[(for-label web-server/private/timer)] -@file{private/timer.ss} provides a functionality for running +@filepath{private/timer.ss} provides a functionality for running procedures after a given amount of time, that may be extended. @defstruct[timer ([evt evt?] @@ -58,8 +59,9 @@ procedures after a given amount of time, that may be extended. @; XXX Generalize @; ------------------------------------------------------------ @section[#:tag "connection-manager.ss"]{Connection Manager} +@require[(for-label web-server/private/connection-manager)] -@file{private/connection-manager.ss} provides functionality for managing pairs of +@filepath{private/connection-manager.ss} provides functionality for managing pairs of input and output ports. We have plans to allow a number of different strategies for doing this. @@ -104,11 +106,13 @@ for doing this. @; ------------------------------------------------------------ @section[#:tag "dispatch-server-unit.ss"]{Dispatching Server} +@require[(for-label web-server/private/dispatch-server-unit)] +@require[(for-label web-server/private/dispatch-server-sig)] The @web-server is just a configuration of a dispatching server. This dispatching server component is useful on its own. -@file{private/dispatch-server-sig.ss} defines the following signatures: +@filepath{private/dispatch-server-sig.ss} defines the following signatures: @defthing[dispatch-server^ signature?]{ The following identifiers: @@ -139,7 +143,7 @@ This dispatching server component is useful on its own. @defthing[dispatch dispatcher?]{How to handle requests.} } -@file{private/dispatch-server-unit.ss} provides the unit +@filepath{private/dispatch-server-unit.ss} provides the unit which actually implements a dispatching server. @; XXX Talk about how threads and custodians are used. @@ -151,10 +155,12 @@ which actually implements a dispatching server. @; ------------------------------------------------------------ @section[#:tag "closure.ss"]{Serializable Closures} +@require[(for-label web-server/private/closure)] +@require[(for-label web-server/private/define-closure)] The defunctionalization process of the Web Language (see @secref["lang"]) requires an explicit representation of closures that is serializable. -@file{private/closure.ss} is this representation. It provides: +@filepath{private/closure.ss} is this representation. It provides: @defproc[(make-closure-definition-syntax [tag syntax?] [fvars (listof identifier?)] @@ -172,7 +178,7 @@ requires an explicit representation of closures that is serializable. Extracts the unique tag of a closure @scheme[c] } -These are difficult to use directly, so @file{private/define-closure.ss} +These are difficult to use directly, so @filepath{private/define-closure.ss} defines a helper form: @defform[(define-closure tag formals (free-vars ...) body)]{ @@ -185,8 +191,9 @@ defines a helper form: @; ------------------------------------------------------------ @section[#:tag "cache-table.ss"]{Cache Table} +@require[(for-label web-server/private/cache-table)] -@file{private/cache-table.ss} provides a set of caching hash table +@filepath{private/cache-table.ss} provides a set of caching hash table functions. @defproc[(make-cache-table) @@ -214,13 +221,14 @@ functions. @; ------------------------------------------------------------ @section[#:tag "mime-types.ss"]{MIME Types} +@require[(for-label web-server/private/mime-types)] -@file{private/mime-types.ss} provides function for dealing with @file{mime.types} +@filepath{private/mime-types.ss} provides function for dealing with @filepath{mime.types} files. @defproc[(read-mime-types [p path?]) (hash-table/c symbol? bytes?)]{ - Reads the @file{mime.types} file from @scheme[p] and constructs a + Reads the @filepath{mime.types} file from @scheme[p] and constructs a hash table mapping extensions to MIME types. } @@ -233,9 +241,10 @@ files. @; XXX Rename mod-map.ss @; ------------------------------------------------------------ @section[#:tag "mod-map.ss"]{Serialization Utilities} +@require[(for-label web-server/private/mod-map)] @scheme[(lib "serialize.ss")] provides the functionality of serializing -values. @file{private/mod-map.ss} compresses the serialized representation. +values. @filepath{private/mod-map.ss} compresses the serialized representation. @defproc[(compress-serial [sv serialized-value?]) compressed-serialized-value?]{ @@ -251,11 +260,12 @@ values. @file{private/mod-map.ss} compresses the serialized representation. @; ------------------------------------------------------------ @section[#:tag "url-param.ss"]{URL Param} +@require[(for-label web-server/private/url-param)] The @web-server needs to encode information in URLs. If this data is stored in the query string, than it will be overridden by browsers that make GET requests to those URLs with more query data. So, it must be encoded -in URL params. @file{private/url-param.ss} provides functions for helping +in URL params. @filepath{private/url-param.ss} provides functions for helping with this process. @defproc[(insert-param [u url?] @@ -275,9 +285,10 @@ with this process. @; ------------------------------------------------------------ @section[#:tag "util.ss"]{Miscellaneous Utilities} +@require[(for-label web-server/private/util)] There are a number of other miscellaneous utilities the @web-server -needs. They are provided by @file{private/util.ss}. +needs. They are provided by @filepath{private/util.ss}. @subsection{Contracts} @defthing[port-number? contract?]{Equivalent to @scheme[(between/c 1 65535)].} diff --git a/collects/web-server/docs/reference/running.scrbl b/collects/web-server/docs/reference/running.scrbl index d6866f9e36..727f54c8eb 100644 --- a/collects/web-server/docs/reference/running.scrbl +++ b/collects/web-server/docs/reference/running.scrbl @@ -32,10 +32,11 @@ the server runs until the process is killed. @; ------------------------------------------------------------ @section[#:tag "web-server.ss"]{Functional} +@require[(for-label web-server/web-server)] -@file{web-server.ss} provides a number of functions for easing embedding +@filepath{web-server.ss} provides a number of functions for easing embedding of the @web-server in other applications, or loading a custom -dispatcher. See @file{run.ss} for an example of such a script. +dispatcher. See @filepath{run.ss} for an example of such a script. @defproc[(serve [#:dispatch dispatch dispatcher?] [#:tcp\@ tcp\@ tcp-unit^ raw:tcp\@] diff --git a/collects/web-server/docs/reference/servlet-env.scrbl b/collects/web-server/docs/reference/servlet-env.scrbl index abca8b206a..3e485d156a 100644 --- a/collects/web-server/docs/reference/servlet-env.scrbl +++ b/collects/web-server/docs/reference/servlet-env.scrbl @@ -3,11 +3,12 @@ @title[#:tag "servlet-env.ss" #:style 'toc]{Environment} +@require[(for-label web-server/servlet-env)] The @web-server provides a means of running Scheme servlets from within DrScheme, or any other REPL. -@file{servlet-env.ss} provides the servlet API from @file{servlet.ss} +@filepath{servlet-env.ss} provides the servlet API from @filepath{servlet.ss} as well as the following: @defthing[send-url (parameter/c ([url string?] [separate-window? boolean?] . -> . void))]{ diff --git a/collects/web-server/docs/reference/servlet.scrbl b/collects/web-server/docs/reference/servlet.scrbl index 7864206751..65b458de85 100644 --- a/collects/web-server/docs/reference/servlet.scrbl +++ b/collects/web-server/docs/reference/servlet.scrbl @@ -6,7 +6,7 @@ The @web-server allows servlets to be written in Scheme. It provides the supporting API, described below, for the construction -of these servlets. This API is provided by @file{servlet.ss}. +of these servlets. This API is provided by @filepath{servlet.ss}. @local-table-of-contents[] @@ -51,8 +51,9 @@ provides: @; ------------------------------------------------------------ @section[#:tag "servlet-structs.ss"]{Contracts} +@require[(for-label web-server/servlet/servlet-structs)] -@file{servlet/servlet-structs.ss} provides a number of contracts +@filepath{servlet/servlet-structs.ss} provides a number of contracts for use in servlets. @defthing[k-url? contract?]{Equivalent to @scheme[string?].} @@ -67,10 +68,11 @@ for use in servlets. @; ------------------------------------------------------------ @section[#:tag "request-structs.ss"]{HTTP Requests} +@require[(for-label web-server/private/request-structs)] @; XXX Create http sub-directory @; XXX Have this include read-request and write-response -@file{private/request-structs.ss} provides a number of structures and functions +@filepath{private/request-structs.ss} provides a number of structures and functions related to HTTP request data structures. @defstruct[header ([field bytes?] @@ -123,8 +125,9 @@ related to HTTP request data structures. @; ------------------------------------------------------------ @section[#:tag "bindings.ss"]{Request Bindings} +@require[(for-label web-server/servlet/bindings)] -@file{servlet/bindings.ss} provides a number of helper functions +@filepath{servlet/bindings.ss} provides a number of helper functions for accessing request bindings. @defproc[(request-bindings [req request?]) @@ -173,8 +176,9 @@ you lose the filename. @; ------------------------------------------------------------ @section[#:tag "response-structs.ss"]{HTTP Responses} +@require[(for-label web-server/private/response-structs)] -@file{private/response-structs.ss} provides structures and functions related to +@filepath{private/response-structs.ss} provides structures and functions related to HTTP responses. @; XXX Only use bytes @@ -231,8 +235,9 @@ transmission that the server will not catch.} @; ------------------------------------------------------------ @section[#:tag "web.ss"]{Web} +@require[(for-label web-server/servlet/web)] -@file{servlet/web.ss} provides the primary functions of interest for the +@filepath{servlet/web.ss} provides the primary functions of interest for the servlet developer. @defproc[(send/back [response response?]) @@ -316,9 +321,10 @@ servlet developer. @; ------------------------------------------------------------ @section[#:tag "helpers.ss"]{Helpers} +@require[(for-label web-server/servlet/helpers)] -@file{servlet/helpers.ss} provides functions built on -@file{servlet/web.ss} that are useful in many servlets. +@filepath{servlet/helpers.ss} provides functions built on +@filepath{servlet/web.ss} that are useful in many servlets. @; XXX Move into http/response.ss @defproc[(redirect-to [uri string?] @@ -349,8 +355,9 @@ servlet developer. @; XXX Depreciate @; ------------------------------------------------------------ @section[#:tag "servlet-url.ss"]{Servlet URLs} +@require[(for-label web-server/servlet/servlet-url)] -@file{servlet/servlet-url.ss} provides functions that might be useful to you. +@filepath{servlet/servlet-url.ss} provides functions that might be useful to you. They may eventually provided by another module. @defproc[(request->servlet-url (req request?)) @@ -365,8 +372,9 @@ They may eventually provided by another module. @; XXX Support Digest @; ------------------------------------------------------------ @section[#:tag "basic-auth.ss"]{Basic Authentication} +@require[(for-label web-server/servlet/basic-auth)] -@file{servlet/basic-auth.ss} provides a function for helping with +@filepath{servlet/basic-auth.ss} provides a function for helping with implementation of HTTP Basic Authentication. @defproc[(extract-user-pass [heads (listof header?)]) @@ -377,8 +385,9 @@ implementation of HTTP Basic Authentication. @; ------------------------------------------------------------ @section[#:tag "web-cells.ss"]{Web Cells} +@require[(for-label web-server/servlet/web-cells)] -@file{servlet/web-cell.ss} provides the interface to web cells. +@filepath{servlet/web-cells.ss} provides the interface to web cells. A web cell is a kind of state defined relative to the @defterm{frame tree}. The frame-tree is a mirror of the user's browsing session. Every time a diff --git a/collects/web-server/docs/reference/web-config-unit.scrbl b/collects/web-server/docs/reference/web-config-unit.scrbl index f0f11155ba..a91eaeb21e 100644 --- a/collects/web-server/docs/reference/web-config-unit.scrbl +++ b/collects/web-server/docs/reference/web-config-unit.scrbl @@ -3,10 +3,12 @@ @title[#:tag "web-config-unit.ss" #:style 'toc]{Web Config Unit} +@require[(for-label web-server/web-config-unit)] +@require[(for-label web-server/web-config-sig)] The @web-server offers a unit-based approach to configuring the server. -@file{web-config-sig.ss} provides the signature +@filepath{web-config-sig.ss} provides the signature @defthing[web-config^ signature?] signature, which contains the following identifiers: @@ -38,7 +40,7 @@ identifiers: Passed to @scheme[servlets:make]. } -@file{web-config-unit.ss} provides the following: +@filepath{web-config-unit.ss} provides the following: @defproc[(configuration-table->web-config\@ [path path?] [#:port port (or/c false/c port-number?) #f] diff --git a/collects/web-server/docs/reference/reference.scrbl b/collects/web-server/docs/reference/web-reference.scrbl similarity index 100% rename from collects/web-server/docs/reference/reference.scrbl rename to collects/web-server/docs/reference/web-reference.scrbl diff --git a/collects/web-server/docs/reference/web-server-unit.scrbl b/collects/web-server/docs/reference/web-server-unit.scrbl index 7a0af29a35..d405c1c751 100644 --- a/collects/web-server/docs/reference/web-server-unit.scrbl +++ b/collects/web-server/docs/reference/web-server-unit.scrbl @@ -3,10 +3,12 @@ @title[#:tag "web-server-unit.ss" #:style 'toc]{Web Server Unit} +@require[(for-label web-server/web-server-sig)] +@require[(for-label web-server/web-server-unit)] The @web-server offers a unit-based approach to running the server. -@file{web-server-sig.ss} provides the @defthing[web-server^ signature?] signature +@filepath{web-server-sig.ss} provides the @defthing[web-server^ signature?] signature with two elements: @defproc[(serve) (-> void)]{ @@ -20,7 +22,7 @@ with two elements: @scheme[op]. } -@file{web-server-unit.ss} provides the @defthing[web-server\@ unit?] unit. It +@filepath{web-server-unit.ss} provides the @defthing[web-server\@ unit?] unit. It imports a @scheme[web-config^] unit and a @scheme[tcp^] unit. It uses the @scheme[web-config^] to construct a @scheme[dispatcher?] function that sets up one virtual host dispatcher, for each virtual host in the @scheme[web-config^], diff --git a/collects/web-server/info.ss b/collects/web-server/info.ss index 45b65cacbd..47e9e20d28 100644 --- a/collects/web-server/info.ss +++ b/collects/web-server/info.ss @@ -1,7 +1,7 @@ (module info setup/infotab (define name "Web Server") - ; Name clash - #;(define scribblings '(("docs/reference/reference.scrbl" (multi-page main-doc)))) + (define scribblings '(("docs/reference/web-reference.scrbl" (multi-page main-doc)) + ("docs/guide/web-guide.scrbl" (multi-page main-doc)))) (define mzscheme-launcher-libraries (list "private/launch-text.ss"))