From 6154221edbb0e17e77da7defeeac5fe53121ef57 Mon Sep 17 00:00:00 2001 From: Jay Berkenbilt Date: Thu, 31 Dec 2020 13:57:21 -0500 Subject: QPDFPageObjectHelper: filterPageContents -> filterContents + form XObject --- include/qpdf/QPDFPageObjectHelper.hh | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) (limited to 'include') diff --git a/include/qpdf/QPDFPageObjectHelper.hh b/include/qpdf/QPDFPageObjectHelper.hh index 5b63a70d..d5ffe78b 100644 --- a/include/qpdf/QPDFPageObjectHelper.hh +++ b/include/qpdf/QPDFPageObjectHelper.hh @@ -140,15 +140,20 @@ class QPDFPageObjectHelper: public QPDFObjectHelper QPDF_DLL void parsePageContents(QPDFObjectHandle::ParserCallbacks* callbacks); - // Pass a page's contents through the given TokenFilter. If a - // pipeline is also provided, it will be the target of the write - // methods from the token filter. If a pipeline is not specified, - // any output generated by the token filter will be discarded. Use - // this interface if you need to pass a page's contents through - // filter for work purposes without having that filter - // automatically applied to the page's contents, as happens with - // addContentTokenFilter. See examples/pdf-count-strings.cc for an - // example. + // Pass a page's or form XObject's contents through the given + // TokenFilter. If a pipeline is also provided, it will be the + // target of the write methods from the token filter. If a + // pipeline is not specified, any output generated by the token + // filter will be discarded. Use this interface if you need to + // pass a page's contents through filter for work purposes without + // having that filter automatically applied to the page's + // contents, as happens with addContentTokenFilter. See + // examples/pdf-count-strings.cc for an example. + QPDF_DLL + void filterContents(QPDFObjectHandle::TokenFilter* filter, + Pipeline* next = 0); + + // Old name -- calls filterContents() QPDF_DLL void filterPageContents(QPDFObjectHandle::TokenFilter* filter, Pipeline* next = 0); @@ -265,9 +270,7 @@ class QPDFPageObjectHelper: public QPDFObjectHelper private: static void removeUnreferencedResourcesHelper( - QPDFObjectHandle oh, std::set& seen, - std::function get_resource, - std::function filter_content); + QPDFPageObjectHelper ph, std::set& seen); class Members { -- cgit v1.2.3-70-g09d2