PrintCompositor.getNPages

int getNPages()

Returns the number of pages in the document or -1 if the document has not been completely paginated.

Returns

the number of pages in the document or -1 if the

document has not been completely paginated.