pub struct PdfPermissions<'a> { /* private fields */ }Expand description
The collection of document permissions and security handler settings for a single PdfDocument.
Note that Pdfium currently only offers support for reading the existing permissions of a document. It does not support changing existing permissions or adding new permissions to a document.
Implementations§
Source§impl<'a> PdfPermissions<'a>
impl<'a> PdfPermissions<'a>
Sourcepub fn bindings(&self) -> &'a dyn PdfiumLibraryBindings
pub fn bindings(&self) -> &'a dyn PdfiumLibraryBindings
Returns the PdfiumLibraryBindings used by this PdfPermissions collection.
Sourcepub fn security_handler_revision(
&self,
) -> Result<PdfSecurityHandlerRevision, PdfiumError>
pub fn security_handler_revision( &self, ) -> Result<PdfSecurityHandlerRevision, PdfiumError>
Returns the revision of the standard security handler used by the containing PdfDocument. As of PDF version 1.7, possible revision numbers are 2, 3, or 4.
Sourcepub fn can_print_high_quality(&self) -> Result<bool, PdfiumError>
pub fn can_print_high_quality(&self) -> Result<bool, PdfiumError>
Returns true if the containing PdfDocument can be printed to a representation
from which a faithful digital copy of the original content could be recovered.
Sourcepub fn can_print_only_low_quality(&self) -> Result<bool, PdfiumError>
pub fn can_print_only_low_quality(&self) -> Result<bool, PdfiumError>
Returns true if the containing PdfDocument can be only be printed to a low-level
representation of the appearance of the document, possibly of degraded quality,
from which a faithful digital copy of the original content could not be recovered.
Sourcepub fn can_assemble_document(&self) -> Result<bool, PdfiumError>
pub fn can_assemble_document(&self) -> Result<bool, PdfiumError>
Returns true if the containing PdfDocument can be assembled; that is, the
document can have pages inserted, rotated, or deleted, can have bookmarks created,
or can have thumbnail page images created.
Sourcepub fn can_modify_document_content(&self) -> Result<bool, PdfiumError>
pub fn can_modify_document_content(&self) -> Result<bool, PdfiumError>
Returns true if the containing PdfDocument allows general modification of
the document contents.
For security handler revisions 3 and later, general document modification can be disabled while still allowing modification of annotations and interactive form fields.
Sourcepub fn can_extract_text_and_graphics(&self) -> Result<bool, PdfiumError>
pub fn can_extract_text_and_graphics(&self) -> Result<bool, PdfiumError>
Returns true if the containing PdfDocument permits text and graphics to be extracted.
Sourcepub fn can_fill_existing_interactive_form_fields(
&self,
) -> Result<bool, PdfiumError>
pub fn can_fill_existing_interactive_form_fields( &self, ) -> Result<bool, PdfiumError>
Returns true if the containing PdfDocument permits any existing form fields,
including signature fields, to be filled in by a user.
Sourcepub fn can_create_new_interactive_form_fields(
&self,
) -> Result<bool, PdfiumError>
pub fn can_create_new_interactive_form_fields( &self, ) -> Result<bool, PdfiumError>
Returns true if the containing PdfDocument allows the creation of new form fields,
including new signature fields.
Sourcepub fn can_add_or_modify_text_annotations(&self) -> Result<bool, PdfiumError>
pub fn can_add_or_modify_text_annotations(&self) -> Result<bool, PdfiumError>
Returns true if the containing PdfDocument allows the addition or modification
of text annotations.
Auto Trait Implementations§
impl<'a> Freeze for PdfPermissions<'a>
impl<'a> !RefUnwindSafe for PdfPermissions<'a>
impl<'a> !Send for PdfPermissions<'a>
impl<'a> !Sync for PdfPermissions<'a>
impl<'a> Unpin for PdfPermissions<'a>
impl<'a> !UnwindSafe for PdfPermissions<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more