Class: PdfEditor::RemovePages

Inherits:
Shuffle
  • Object
show all
Defined in:
lib/pdf_editor/remove_pages.rb

Constant Summary

Constants included from Errors

Errors::ArgumentMissingError, Errors::InvalidInputError, Errors::InvalidPDFError, Errors::PageCountError, Errors::PageOrderInvalidError, Errors::PageRangeError, Errors::ResourcesEmptyError, Errors::TitlePageTitleError

Constants included from Service

Service::InterfaceNotImplementedError, Service::MustPassBlockToAsTempfile

Instance Attribute Summary

Attributes inherited from Shuffle

#page_order, #resource

Instance Method Summary collapse

Methods inherited from Shuffle

#call

Methods included from PdfRunner

#pdf_runner

Methods included from Service

#call, included, #initialize

Instance Method Details

#post_initObject

Page order has a unique set of members and is sorted. This allows pdftk to not burst the document into single pages where possible.



12
13
14
15
# File 'lib/pdf_editor/remove_pages.rb', line 12

def post_init
  super
  @page_order = @page_order.uniq.sort
end