lispdoc - results for format

(format destination control-string &rest format-arguments)
Function: Provides various facilities for formatting output. CONTROL-STRING contains a string to be output, possibly with embedded directives, which are flagged with the escape character "~". Directives generally expand into additional text to be output, usually consuming one or more of the FORMAT-ARGUMENTS in the process. A few useful directives are: ~A or ~nA Prints one argument as if by PRINC ~S or ~nS Prints one argument as if by PRIN1 ~D or ~nD Prints one argument as a decimal integer ~% Does a TERPRI ~& Does a FRESH-LINE where n is the width of the field in which the object is printed. DESTINATION controls where the result will go. If DESTINATION is T, then the output is sent to the standard output stream. If it is NIL, then the output is returned in a string as the value of the call. Otherwise, DESTINATION must be a stream to which the output will be sent. Example: (FORMAT NIL "The answer is ~D." 10) => "The answer is 10." FORMAT has many additional capabilities not described here. Consult the manual for details.
Example:
(defun bell () (send-wish (format nil "bell")))
Mentioned in:
CLtL2 - 13. Characters
CLtL2 - 13.4. Character Conversions
CLtL2 - 18.3. String Construction and Manipulation
CLtL2 - 19.5. Defstruct Options
CLtL2 - 2.2.1. Standard Characters
CLtL2 - 21.2. Creating New Streams
CLtL2 - 22. Input/Output
CLtL2 - 22.1.6. What the Print Function Produces
CLtL2 - 22.3. Output Functions
CLtL2 - 22.4. Querying the User
CLtL2 - 24.1. General Error-Signaling Functions
CLtL2 - 24.2. Specialized Error-Signaling Forms and Macros
CLtL2 - 27.1. Introduction
CLtL2 - 27.3. Dynamic Control of the Arrangement of Output
CLtL2 - 27.4. Format Directive Interface
CLtL2 - 27.5. Compiling Format Control Strings
CLtL2 - 28.2. Functions in the Programmer Interface
CLtL2 - 29.3.1. Signaling Errors
CLtL2 - 29.3.18. Printing Conditions
CLtL2 - 29.4.1. Signaling Conditions
CLtL2 - 5.3.2. Declaring Global Variables and Named Constants
CLtL2 - 7.9. Structure Traversal and Side Effects
HyperSpec - 22.2.1.2 Format Directive Interface
HyperSpec - 22.2.1.3 Compiling Format Strings
HyperSpec - 22.3.1 FORMAT Basic Output
HyperSpec - 22.3.10 Additional Information about FORMAT Operations
HyperSpec - 22.3.10.1 Nesting of FORMAT Operations
HyperSpec - 22.3.10.2 Missing and Additional FORMAT Arguments
HyperSpec - 22.3.10.3 Additional FORMAT Parameters
HyperSpec - 22.3.10.4 Undefined FORMAT Modifier Combinations
HyperSpec - 22.3.11 Examples of FORMAT
HyperSpec - 22.3.12 Notes about FORMAT
HyperSpec - 22.3.2 FORMAT Radix Control
HyperSpec - 22.3.3 FORMAT Floating-Point Printers
HyperSpec - 22.3.4 FORMAT Printer Operations
HyperSpec - 22.3.5 FORMAT Pretty Printer Operations
HyperSpec - 22.3.6 FORMAT Layout Control
HyperSpec - 22.3.7 FORMAT Control-Flow Operations
HyperSpec - 22.3.8 FORMAT Miscellaneous Operations
HyperSpec - 22.3.9 FORMAT Miscellaneous Pseudo-Operations
HyperSpec - Function FORMAT
On Lisp - A Query Compiler (AQC)
On Lisp - Adding Prolog Features
On Lisp - Continuation-Passing Macros
On Lisp - Functions as Representation
On Lisp - The Process Abstraction
PCL - a few format recipes
PCL - and more
PCL - basic formatting
PCL - better result reporting
PCL - character and integer directives
PCL - conditional formatting
PCL - english language directives
PCL - file output
PCL - foo special operators
PCL - format directives
PCL - generating dynamic content with allegroserve
PCL - generating html
PCL - good object oriented design
PCL - hello world lisp style
PCL - improving the user interaction
PCL - indenting printer
PCL - iteration
PCL - looking at the database contents
PCL - other kinds of io
PCL - refactoring
PCL - rest parameters
PCL - s expressions
PCL - saving and loading the database
PCL - special operators
PCL - string comparisons
PCL - strings
PCL - the format function
PCL - the implementation
PCL - two first tries
PCL - unwinding the stack
PCL - whats next
PCL - wrapping up
PCL - wrapping up
Successful Lisp - chapter05
Successful Lisp - chapter16
Successful Lisp - chapter19
Successful Lisp - chapter21
Successful Lisp - chapter23
Successful Lisp - chapter24
Successful Lisp - chapter30
Successful Lisp - chapter32
Successful Lisp - condition designator
Successful Lisp - tail recursion
fixed-format
 
 Mentioned in:
HyperSpec - 22.3.3.1 Tilde F: Fixed-Format Floating-Point
babel:external-format
Type: An EXTERNAL-FORMAT consists in a combination of a Babel CHARACTER-ENCODING and an end-of-line style.
  
(alexandria.0.dev:format-symbol package control &rest arguments)
Function: Constructs a string by applying ARGUMENTS to string designator CONTROL as if by FORMAT, and then creates a symbol named by that string. If PACKAGE is NIL, returns an uninterned symbol, if package is T, returns a symbol interned in the current package, and otherwise returns a symbol interned in the package designated by PACKAGE.
  
(stream-external-format stream)
Undocumented
 Mentioned in:
CLtL2 - 21.3. Operations on Streams
CLtL2 - 23.2. Opening and Closing Files
HyperSpec - Function STREAM-EXTERNAL-FORMAT
(babel:make-external-format encoding &key (eol-style *default-eol-style*))
Undocumented
  
(babel:external-format-equal ef1 ef2)
Undocumented
  
(babel:ensure-external-format thing)
Undocumented
  
(babel:external-format-encoding object)
Undocumented
  
*read-default-float-format
 
 Mentioned in:
HyperSpec - Variable *READ-DEFAULT-FLOAT-FORMAT
(hunchentoot:reply-external-format object)
Undocumented
  
(hunchentoot:reply-external-format* &optional (reply *reply*))
Function: The external format of REPLY which is used for character output.
  
*read-default-float-format*
Undocumented
 Mentioned in:
CLtL2 - 2.1.3. Floating-Point Numbers
CLtL2 - 22.1.6. What the Print Function Produces
CLtL2 - 22.2.1. Input from Character Streams
(babel:external-format-eol-style object)
Undocumented
  
(simple-condition-format-control condition)
Function: Return the offending thread that the THREAD-ERROR pertains to.
 Mentioned in:
HyperSpec - Function SIMPLE-CONDITION-FORMAT-CONTROL, SIMPLE-CONDITION-FORMAT-ARGUMENTS
(flexi-streams:external-format-id object)
Undocumented
  
(simple-condition-format-arguments condition)
Function: Return the offending thread that the THREAD-ERROR pertains to.
 Mentioned in:
CLtL2 - 29.5. Predefined Condition Types
HyperSpec - Function SIMPLE-CONDITION-FORMAT-CONTROL, SIMPLE-CONDITION-FORMAT-ARGUMENTS
(flexi-streams:make-external-format name &rest args &key
 (little-endian *default-little-endian*) id eol-style)
Function: Creates and returns an external format object as specified. NAME is a keyword like :LATIN1 or :UTF-8, LITTLE-ENDIAN specifies the `endianess' of the external format and is ignored for 8-bit encodings, EOL-STYLE is one of the keywords :CR, :LF, or :CRLF which denote the end-of-line character (sequence), ID is the ID of a Windows code page (and ignored for other encodings).
  
(flexi-streams:external-format-name object)
Undocumented
  
flexi-streams:external-format-error
Type: Superclass for all errors related to external formats.
Structure: Superclass for all errors related to external formats.
  
(flexi-streams:external-format-equal ef1 ef2)
Function: Checks whether two EXTERNAL-FORMAT objects denote the same encoding.
  
trivial-backtrace:*date-time-format*
Variable: The default format to use when printing dates and times. * %% - A '%' character * %d - Day of the month as a decimal number [01-31] * %e - Same as %d but does not print the leading 0 for days 1 through 9 [unlike strftime[], does not print a leading space] * %H - Hour based on a 24-hour clock as a decimal number [00-23] *%I - Hour based on a 12-hour clock as a decimal number [01-12] * %m - Month as a decimal number [01-12] * %M - Minute as a decimal number [00-59] * %S - Second as a decimal number [00-59] * %w - Weekday as a decimal number [0-6], where Sunday is 0 * %y - Year without century [00-99] * %Y - Year with century [such as 1990] This code is borrowed from the `format-date` function in [metatilities-base][].
  
flexi-streams:external-format-condition
Type: Superclass for all conditions related to external formats.
Structure: Superclass for all conditions related to external formats.
  
(flexi-streams:external-format-eol-style object)
Undocumented
  
hunchentoot:*hunchentoot-default-external-format*
Variable: The external format used to compute the REQUEST object.
  
(flexi-streams:flexi-stream-external-format object)
Undocumented
  
(flexi-streams:external-format-little-endian object)
Undocumented
  
flexi-streams:external-format-encoding-error
Type: Errors of this type are signalled if there is an encoding problem.
Structure: Errors of this type are signalled if there is an encoding problem.
  
(flexi-streams:external-format-condition-external-format condition)
Undocumented