Skip to content

Commit

Permalink
DOC: spellchecked documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
likelion authored and JanWielemaker committed Jan 3, 2025
1 parent 1d11086 commit dd446aa
Show file tree
Hide file tree
Showing 34 changed files with 89 additions and 89 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ both HTTP and HTTPS connections and handle all request methods.

## Server library

The main server libraris are
The main server libraries are

- `library(http/thread_httpd)` implements the server
- `library(http/http_dispatch)` implements binding locations
Expand Down
2 changes: 1 addition & 1 deletion ax.pl
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
% Only provide the attribute if it is available. This is
% mutually exclusive with =required=. This is the default.
% - url(+URL)
% Can be used to ovcerrule or extend the ax_alias/2.
% Can be used to overrule or extend the ax_alias/2.
% - count(+Count)
% Maximum number of values to provide
%
Expand Down
4 changes: 2 additions & 2 deletions cgi_stream.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ with the request, deciding on:
Now, the stream is placed in full buffering mode (SIO_FBUF). If the
transfer encoding is 'chunked' it immediately calls the hook using
'send_header' to emit the current header. Output continues. In chunked
mode sending the chunks, otherwisse collecting the data. On close, it
mode sending the chunks, otherwise collecting the data. On close, it
writes an empty block (chunked mode) or (normal mode) calls the hook
'send_header' which now has access to the content-length, followed by
the data.
Expand Down Expand Up @@ -434,7 +434,7 @@ cgi_discard(term_t cgi)
*******************************/

/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Call hook on the data we collected sofar. The hook is called with the
Call hook on the data we collected so far. The hook is called with the
following additional arguments:
* Event-type (header, data)
Expand Down
6 changes: 3 additions & 3 deletions graphql.pl
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@
% Desc = "SWI-Prolog package implementing a SourceHut GraphQL API client.".
% ```
%
% Options is a list whose elemenets are one of the following:
% Options is a list whose elements are one of the following:
% - token(+Token)
% Token is string that will be used as an OAuth2.0 token. See also
% graphql_auth_token_hook/2.
Expand Down Expand Up @@ -284,7 +284,7 @@
% A list of associations of Prolog variable names, given as atoms,
% to _GraphQL values_.
%
% Occurences of the special lexical construct "<Name>" (that is,
% Occurrences of the special lexical construct "<Name>" (that is,
% ASCII 60, then the codes of the atom Name, then ASCII 62) in
% Source are expanded in Document to the _GraphQL value_ Value.
% This option can be used to interpolate GraphQL documents with
Expand Down Expand Up @@ -1040,7 +1040,7 @@
%
% Options are a list whose elements are one of:
% - separator(+Sep)
% Sep is a list of codes to be used for separating adjancent
% Sep is a list of codes to be used for separating adjacent
% GraphQL values in Codes. Defaults to a single space.
% This option can be used to separate values with commas
% (which are optional throughout GraphQL) by passing
Expand Down
4 changes: 2 additions & 2 deletions html_head.pl
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@
2. Replace multiple members by `aggregate' scripts or css files.
see use_agregates/4.
3. Order all resources by demanding that their dependencies
preceede the resource itself. Note that the ordering of
precede the resource itself. Note that the ordering of
resources in the dependency list is *ignored*. This implies
that if the order matters the dependency list must be split
and only the primary dependency must be added.
Expand Down Expand Up @@ -555,7 +555,7 @@
%! html_include(+PathOrList)// is det.
%
% Include to HTML resources that must be in the HTML <head>
% element. Currently onlu supports =|.js|= and =|.css|= files.
% element. Currently only supports =|.js|= and =|.css|= files.
% Extend this to support more header material. Do not use this
% predicate directly. html_requires//1 is the public interface to
% include HTML resources.
Expand Down
6 changes: 3 additions & 3 deletions html_write.pl
Original file line number Diff line number Diff line change
Expand Up @@ -836,7 +836,7 @@
% Quote the value according to the rules for tag-attributes
% included in double-quotes. Note that -like html_quoted//1-,
% attributed values printed through html//1 are quoted
% atomatically.
% automatically.
%
% @tbd Assumes UTF-8 encoding of the output.

Expand Down Expand Up @@ -908,7 +908,7 @@
%! html_receive(+Id, :Handler)// is det.
%
% This extended version of html_receive//1 causes Handler to be
% called to process all messages posted to the channal at the time
% called to process all messages posted to the channel at the time
% output is generated. Handler is called as below, where
% `PostedTerms` is a list of Module:Term created from calls to
% html_post//2. Module is the context module of html_post and Term
Expand Down Expand Up @@ -938,7 +938,7 @@
% Collect posted tokens and copy them into the receiving
% mailboxes. Mailboxes may produce output for each other, but not
% cyclic. The current scheme to resolve this is rather naive: It
% simply permutates the mailbox resolution order until it found a
% simply permutes the mailbox resolution order until it found a
% working one. Before that, it puts =head= and =script= boxes at
% the end.

Expand Down
2 changes: 1 addition & 1 deletion htmx.pl
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
HTML fragment that extends or replaces an element on the page. This
allows us to program a most functionality interactive seen in modern web
applications using the powerful SWI-Prolog HTML generation framework
rather than having to write a JSON backend and accompagnying JavaScript
rather than having to write a JSON backend and accompanying JavaScript
frontend that runs in the browser.
Below is a minimal, yet fully functional application
Expand Down
10 changes: 5 additions & 5 deletions http.doc
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ This library provides http_open/3 and friends. It
is a library for opening an endpoint identified by an HTTP URL as a
Prolog stream. The general skeleton for using this library
is given below, where \nopredref{process}{1} processes the data from the
HTTP server.\footnote{One may opt to use cleanup/2 intead of
HTTP server.\footnote{One may opt to use cleanup/2 instead of
setup_call_cleanup/3 to allow for aborting while http_open/3 is waiting
for the connection.}

Expand Down Expand Up @@ -458,7 +458,7 @@ message.

Options fall into three categories: those that handle presence of
the parameter, those that guide conversion and restrict types and
those that support automatic generation of documention. First,
those that support automatic generation of documentation. First,
the presence-options:

\begin{description}
Expand Down Expand Up @@ -933,7 +933,7 @@ present. If the dispatch module is used (see \secref{httpdispatch}),
spawning is normally specified as an option to the http_handler/3
registration.

We recomment the use of thread pools. They allow registration of a set
We recommend the use of thread pools. They allow registration of a set
of threads using common characteristics, specify how many can be active
and what to do if all threads are active. A typical application may
define a small pool of threads with large stacks for computation
Expand Down Expand Up @@ -1098,7 +1098,7 @@ not start with \chr{/}.

This problem can also be solved using the contributed Apache module
\const{proxy_html} that can be instructed to rewrite URLs embedded in
HTML documents. In our experience, this is not troublefree as URLs can
HTML documents. In our experience, this is not trouble-free as URLs can
appear in many places in generated documents. JavaScript can create
URLs on the fly, which makes rewriting virtually impossible.

Expand Down Expand Up @@ -1301,7 +1301,7 @@ The example below generates a URL that references the predicate
set_lang/1 in the application with given parameters. The http_handler/3
declaration binds \const{/setlang} to the predicate set_lang/1 for which
we provide a very simple implementation. The code between \const{...}
is part of an HTML page showing the english flag which, when pressed,
is part of an HTML page showing the English flag which, when pressed,
calls \term{set_lang}{Request} where \arg{Request} contains the search
parameter \mbox{\const{lang} = \const{en}}. Note that the HTTP location
(path) \const{/setlang} can be moved without affecting this code.
Expand Down
4 changes: 2 additions & 2 deletions http_authenticate.pl
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
% to Type. Type identifies the required authentication technique:
%
% * basic(+PasswordFile)
% Use HTTP =Basic= authetication and verify the password
% Use HTTP =Basic= authentication and verify the password
% from PasswordFile. PasswordFile is a file holding
% usernames and passwords in a format compatible to
% Unix and Apache. Each line is record with =|:|=
Expand All @@ -92,7 +92,7 @@
%
% @param Fields is a list of fields from the password-file entry.
% The first element is the user. The hash is skipped.
% @tbd Should we also cache failures to reduce the risc of
% @tbd Should we also cache failures to reduce the risk of
% DoS attacks?

http_authenticate(basic(File), Request, [User|Fields]) :-
Expand Down
2 changes: 1 addition & 1 deletion http_cookie.pl
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@
%
% Query current cookie database. If Name is given, it is matched
% case insensitive against the known cookies. If it is unbound,
% the cookie name is returned in its oiginal case (case
% the cookie name is returned in its original case (case
% preserving).

cookie_current_cookie(ClientId, Name, Value, Options) :-
Expand Down
4 changes: 2 additions & 2 deletions http_cors.pl
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,11 @@
This small module allows for enabling Cross-Origin Resource Sharing
(CORS) for a specific request. Typically, CORS is enabled for API
services that you want to have useable from browser client code that is
services that you want to have usable from browser client code that is
loaded from another domain. An example are the LOD and SPARQL services
in ClioPatria.
Because CORS is a security risc (see references), it is disabled by
Because CORS is a security risk (see references), it is disabled by
default. It is enabled through the setting http:cors. The value of this
setting is a list of domains that are allowed to access the service.
Because * is used as a wildcard match, the value [*] allows access from
Expand Down
6 changes: 3 additions & 3 deletions http_digest.pl
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
This library implements HTTP _Digest Authentication_ as per RFC2617.
Unlike _Basic Authentication_, digest authentication is based on
challenge-reponse and therefore does not need to send the password over
challenge-response and therefore does not need to send the password over
the (insecure) connection. In addition, it provides a count mechanism
that ensure that old credentials cannot be reused, which prevents
attackers from using old credentials with a new request. Digest
Expand Down Expand Up @@ -369,12 +369,12 @@

%! http_digest_authenticate(+Request, -User, -UserFields, +Options)
%
% Validate the client reponse from the Request header. On success,
% Validate the client response from the Request header. On success,
% User is the validated user and UserFields are additional fields
% from the password file. Options include:
%
% - passwd_file(+File)
% Validate passwords agains the given password file. The
% Validate passwords against the given password file. The
% file is read using http_current_user/3 from
% library(http/http_authenticate).
% - stale(-Stale)
Expand Down
2 changes: 1 addition & 1 deletion http_dirindex.pl
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@
% Sort the files in the directory listing by Field. Field
% is one of =name= (default), =size= or =time=.
% * order(+AscentDescent)
% Sorting order. Default is =ascending=. The altenative is
% Sorting order. Default is =ascending=. The alternative is
% =descending=
% * name(:RenderName)
% DCG used to render a name in the table. The File is passed.
Expand Down
12 changes: 6 additions & 6 deletions http_dispatch.pl
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@
% Options is a list containing the following options:
%
% - authentication(+Type)
% Demand authentication. Authentication methods are pluggable. The
% Demand authentication. Authentication methods are plugable. The
% library http_authenticate.pl provides a plugin for user/password
% based =Basic= HTTP authentication.
%
Expand Down Expand Up @@ -624,7 +624,7 @@
% returned location is the path up to the first variable, e.g.,
% =|/user/|= in the example above.
%
% User code is adviced to use http_link_to_id/3 which can also add
% User code is advised to use http_link_to_id/3 which can also add
% query parameters to the URL. This predicate is a helper for
% http_link_to_id/3.
%
Expand Down Expand Up @@ -768,7 +768,7 @@
% ```
%
% @arg HandleID is either an atom, possibly module qualified
% predicate or a compound term if the hander is defined using
% predicate or a compound term if the handler is defined using
% a pattern. See http_handler/3 and http_location_by_id/2.
%
% @arg Parameters is one of
Expand Down Expand Up @@ -1071,7 +1071,7 @@
% * static_gzip(+Boolean)
% If `true` (default `false`) and, in addition to the plain
% file, there is a ``.gz`` file that is not older than the
% plain file and the client acceps =gzip= encoding, send
% plain file and the client accepts =gzip= encoding, send
% the compressed file with ``Transfer-encoding: gzip``.
%
% * cached_gzip(+Boolean)
Expand Down Expand Up @@ -1327,7 +1327,7 @@

%! path_tree(-Tree) is det.
%
% Compile paths into a tree. The treee is multi-rooted and
% Compile paths into a tree. The tree is multi-rooted and
% represented as a list of nodes, where each node has the form:
%
% node(PathOrPrefix, Action, Options, Children)
Expand All @@ -1337,7 +1337,7 @@
% worker thread holds a copy of the tree. If handler facts are
% changed the _generation_ is incremented using next_generation/0
% and each worker thread will re-compute the tree on the next
% ocasion.
% occasion.

path_tree(Tree) :-
current_generation(G),
Expand Down
2 changes: 1 addition & 1 deletion http_dyn_workers.pl
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@
%! http:schedule_workers(+Dict)
%
% Called if there is no immediately free worker to handle the
% incomming request. The request is forwarded to the thread
% incoming request. The request is forwarded to the thread
% =|__http_scheduler|= as the hook is called in time critical code.

:- multifile
Expand Down
2 changes: 1 addition & 1 deletion http_error.pl
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
can be controlled by
- nodebug(http(error))
After disabling the http(error) debug channal, errors are only sent
After disabling the http(error) debug channel, errors are only sent
to the client. See nodebug/1 and debug/1.
- set_setting(http:client_backtrace, false)
Stop sending stack traces to the client. Note that sending the stack
Expand Down
2 changes: 1 addition & 1 deletion http_files.pl
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
be created using the following code sample, which starts a server at
port 8080 that serves files from the current directory ('.'). Note that
the handler needs a `prefix` option to specify that it must handle all
paths that begin with the registed location of the handler.
paths that begin with the registered location of the handler.
```
:- use_module(library(http/http_server)).
Expand Down
10 changes: 5 additions & 5 deletions http_header.pl
Original file line number Diff line number Diff line change
Expand Up @@ -484,7 +484,7 @@
%! status_has_content(+StatusTerm, -HTTPCode)
%
% True when StatusTerm is a status that usually comes with an
% expanatory content message.
% explanatory content message.

status_has_content(created(_Location)).
status_has_content(moved(_To)).
Expand Down Expand Up @@ -871,7 +871,7 @@
%
% Decide on the transfer encoding from the Request and the CGI
% header. The behaviour depends on the setting
% http:chunked_transfer. If =never=, even explitic requests are
% http:chunked_transfer. If =never=, even explicit requests are
% ignored. If =on_request=, chunked encoding is used if requested
% through the CGI header and allowed by the client. If
% =if_possible=, chunked encoding is used whenever the client
Expand Down Expand Up @@ -933,7 +933,7 @@

%! content_length_in_encoding(+Encoding, +In, -Bytes)
%
% Determine hom many bytes are required to represent the data from
% Determine how many bytes are required to represent the data from
% stream In using the given encoding. Fails if the data cannot be
% represented with the given encoding.

Expand Down Expand Up @@ -1786,7 +1786,7 @@

%! read_field_value(-Codes)//
%
% Read a field eagerly upto the next whitespace
% Read a field eagerly up to the next whitespace

read_field_value([H|T]) -->
[H],
Expand Down Expand Up @@ -2749,7 +2749,7 @@

%! address//
%
% Emit the HTML for the server address on behalve of error and
% Emit the HTML for the server address on behalf of error and
% status messages (non-200 replies). Default is
%
% ==
Expand Down
2 changes: 1 addition & 1 deletion http_multipart_plugin.pl
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
%! http_client:http_convert_data(+In, +Fields, -Data, +Options) is semidet.
%
% Convert =|multipart/form-data|= messages for http_read_data/3.
% This plugin adds the folling options to http_read_data/3:
% This plugin adds the following options to http_read_data/3:
%
% * form_data(+AsForm)
% If the content-type is =|multipart/form-data|=, return the
Expand Down
4 changes: 2 additions & 2 deletions http_open.pl
Original file line number Diff line number Diff line change
Expand Up @@ -993,7 +993,7 @@
%
% Parse the header lines for the headers(-List) option. Invalid
% header lines are skipped, printing a warning using
% pring_message/2.
% print_message/2.

parse_headers([], []) :- !.
parse_headers([Line|Lines], Headers) :-
Expand Down Expand Up @@ -1782,7 +1782,7 @@
%
% This hook is used by the HTTP client library to define default
% options based on the the broken-down request-URL. The following
% example redirects all trafic, except for localhost over a proxy:
% example redirects all traffic, except for localhost over a proxy:
%
% ```
% :- multifile
Expand Down
Loading

0 comments on commit dd446aa

Please sign in to comment.