PageRanges

PageRanges

Page ranges of a file, inclusive of start and end page index, where page index starts from 1.

Constructor

new PageRanges()

Constructs a new PageRanges instance with no pages added.

Methods

addSinglePage(pagenon-null)

Adds a single page. Page index starts from 1.

Parameters:
Name Type Description
page Number

single page index

addPageRange(startnon-null, endnon-null)

Adds a page range. Page indexes start from 1.

Parameters:
Name Type Description
start Number

start page index, inclusive

end Number

end page index, inclusive

addAllFrom(startnon-null)

Adds a page range from the specified start page index to the last page. Page index starts from 1.

Parameters:
Name Type Description
start Number

start page index

addAll()

Adds a page range representing all pages.