d@0: d@0:
d@0:d@0: d@0: Next: Wisdom Import, d@0: Previous: Wisdom, d@0: Up: Wisdom d@0:
void fftw_export_wisdom_to_file(FILE *output_file); d@0: char *fftw_export_wisdom_to_string(void); d@0: void fftw_export_wisdom(void (*write_char)(char c, void *), void *data); d@0:d@0:
d@0: These functions allow you to export all currently accumulated wisdom d@0: in a form from which it can be later imported and restored, even d@0: during a separate run of the program. (See Words of Wisdom-Saving Plans.) The current store of wisdom is not affected by calling any d@0: of these routines. d@0: d@0:
fftw_export_wisdom
exports the wisdom to any output
d@0: medium, as specified by the callback function
d@0: write_char
. write_char
is a putc
-like function that
d@0: writes the character c
to some output; its second parameter is
d@0: the data
pointer passed to fftw_export_wisdom
. For
d@0: convenience, the following two “wrapper” routines are provided:
d@0:
d@0:
fftw_export_wisdom_to_file
writes the wisdom to the
d@0: current position in output_file
, which should be open with write
d@0: permission. Upon exit, the file remains open and is positioned at the
d@0: end of the wisdom data.
d@0:
d@0:
fftw_export_wisdom_to_string
returns a pointer to a
d@0: NULL
-terminated string holding the wisdom data. This string is
d@0: dynamically allocated, and it is the responsibility of the caller to
d@0: deallocate it with free
when it is no longer needed.
d@0:
d@0:
All of these routines export the wisdom in the same format, which we d@0: will not document here except to say that it is LISP-like ASCII text d@0: that is insensitive to white space. d@0: d@0: d@0: d@0: