mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-04-30 03:40:34 +02:00
Document and export `declare-opaque-header!'
* module/web/http.scm (declare-opaque-header!): Add docstring. New export. * doc/ref/web.texi (HTTP): Add documentation.
This commit is contained in:
parent
312e79f8d5
commit
64ead01db7
2 changed files with 8 additions and 0 deletions
|
@ -398,6 +398,11 @@ HTTP stack like this:
|
|||
(display (inet-ntoa ip) port)))
|
||||
@end example
|
||||
|
||||
@deffn {Scheme Procedure} declare-opaque-header! name
|
||||
A specialised version of @code{declare-header!} for the case in which
|
||||
you want a header's value to be returned/written ``as-is''.
|
||||
@end deffn
|
||||
|
||||
@deffn {Scheme Procedure} valid-header? sym val
|
||||
Return a true value iff @var{val} is a valid Scheme value for the header
|
||||
with name @var{sym}.
|
||||
|
|
|
@ -42,6 +42,7 @@
|
|||
header->string
|
||||
|
||||
declare-header!
|
||||
declare-opaque-header!
|
||||
known-header?
|
||||
header-parser
|
||||
header-validator
|
||||
|
@ -1145,6 +1146,8 @@ phrase\"."
|
|||
;; emacs: (put 'declare-header! 'scheme-indent-function 1)
|
||||
;; emacs: (put 'declare-opaque!-header 'scheme-indent-function 1)
|
||||
(define (declare-opaque-header! name)
|
||||
"Declares a given header as \"opaque\", meaning that its value is not
|
||||
treated specially, and is just returned as a plain string."
|
||||
(declare-header! name
|
||||
parse-opaque-string validate-opaque-string write-opaque-string))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue