Package org.apache.pdfbox.pdmodel

Examples of org.apache.pdfbox.pdmodel.PDPageNode


                COSBase parent = page;
                while (((COSDictionary) parent).getDictionaryObject("Parent", "P") != null) {
                    parent = ((COSDictionary) parent).getDictionaryObject( "Parent", "P" );
                }
                // now parent is the pages node
                PDPageNode pages = new PDPageNode((COSDictionary) parent);
                List<PDPage> allPages = new ArrayList<PDPage>();
                pages.getAllKids(allPages);
                retval = allPages.indexOf(new PDPage((COSDictionary) page)) + 1;
            }
        }
        return retval;
    }
View Full Code Here


                COSBase parent = page;
                while (((COSDictionary) parent).getDictionaryObject("Parent", "P") != null) {
                    parent = ((COSDictionary) parent).getDictionaryObject( "Parent", "P" );
                }
                // now parent is the pages node
                PDPageNode pages = new PDPageNode((COSDictionary) parent);
                List<PDPage> allPages = new ArrayList<PDPage>();
                pages.getAllKids(allPages);
                retval = allPages.indexOf(new PDPage((COSDictionary) page)) + 1;
            }
        }
        return retval;
    }
View Full Code Here

TOP

Related Classes of org.apache.pdfbox.pdmodel.PDPageNode

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.