Hi Peter,

I think it makes sense to give const access to the PdfEncrypt object. I 
commited an inline member to PdfMemDocument.

Cheers,
        Dominik

Am Friday 12 November 2010 schrieb Peter Ramensky:
> I have a use case where I needed the functionality provided by a
> PdfMemDocument but also needed to know what the key length was. There is
> no easy way to do this. I could 1) Re-implement my solution using
> PdfParser
> 2) Open the document with both a PdfParser and a PdfMemDocument
> 3) Copy the implementation of PdfMemDocument and add an extra function to
> my version 4) Update PdfMemDocument and rebuild PoDoFo - which is what I
> ended up doing
> 
> But that means I need to do that for every release of PoDoFo. Not really
> that inviting.
> 
> My suggesting is that PdfMemDocument has a new function similar to
> PdfParser: const PdfEncrypt* GetEncrypt();
> Which returns the internal PdfEncrypt member.
> 
> Then you can drop all the Is*Allowed() functions.
> 
> In fact the user could simply:
> my_doc->GetEncrypt()->IsPrintAllowed();
> or
> const PdfEncrypt* encrypt = my_doc->GetEncrypt();
> encrypt->IsPrintAllowed();
> 
> Anyway that's my request - nice library BTW.
> 
> Peter.


-- 
Dominik Seichter - [email protected] - http://domseichter.blogspot.com
KRename  - http://www.krename.net  - Powerful batch renamer for KDE
KBarcode - http://www.kbarcode.net - Barcode and label printing
PoDoFo - http://podofo.sf.net - PDF generation and parsing library

Attachment: signature.asc
Description: This is a digitally signed message part.

------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today
http://p.sf.net/sfu/msIE9-sfdev2dev
_______________________________________________
Podofo-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/podofo-users

Reply via email to