diff options
author | Werner Koch <[email protected]> | 2016-08-12 13:24:46 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2016-08-12 13:32:31 +0000 |
commit | fe1e8e71aa18b4ac6471292b2894b8859f42f7c8 (patch) | |
tree | cd9e70ab4b46ca79a74a54f976d36b17cc0d4d50 /doc | |
parent | core: Add gpgme_data_set_flag to add more meta data to data objects. (diff) | |
download | gpgme-fe1e8e71aa18b4ac6471292b2894b8859f42f7c8.tar.gz gpgme-fe1e8e71aa18b4ac6471292b2894b8859f42f7c8.zip |
core: Make use of the "size-hint" in engine-gpg.
* src/engine-gpg.c: Include data.h.
(add_input_size_hint): New.
(gpg_decrypt, gpg_encrypt, gpg_encrypt_sign, gpg_sign)
(gpg_verify): Call new function,
* tests/run-encrypt.c (status_cb): Print to stderr.
(progress_cb): New.o
(main): Add option --progress. Print full-status lines. Provide a
size for the input data.
Signed-off-by: Werner Koch <[email protected]>
Diffstat (limited to 'doc')
-rw-r--r-- | doc/gpgme.texi | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/doc/gpgme.texi b/doc/gpgme.texi index 2bbed285..8b0ec528 100644 --- a/doc/gpgme.texi +++ b/doc/gpgme.texi @@ -2177,6 +2177,30 @@ The function @code{gpgme_data_set_encoding} changes the encoding of the data object with the handle @var{dh} to @var{enc}. @end deftypefun +@deftypefun {gpgme_error_t} gpgme_data_set_flag @ + (@w{gpgme_data_t @var{dh}}, @ + @w{const char *@var{name}}, @ + @w{const char *@var{value}}) + +Some minor properties of the data object can be controlled with flags +set by this function. The properties are identified by the following +values for @var{name}: + +@table @code +@item size-hint +The value is a decimal number with the length gpgme shall assume for +this data object. This is useful if the data is provided by callbacks +or via file descriptors but the applications knows the total size of +the data. If this is set the OpenPGP engine may use this to decide on +buffer allocation strategies and to provide a total value for its +progress information. + +@end table + +This function returns @code{0} on success. +@end deftypefun + + @node Data Buffer Convenience @subsection Data Buffer Convenience Functions @cindex data buffer, convenience |