public static void main(String[] args) throws IOException
    {
        File file = new File("src/main/resources/org/apache/pdfbox/examples/rendering/",
                             "custom-render-demo.pdf");
        
        try (PDDocument doc = Loader.loadPDF(file))
        {
            PDFRenderer renderer = new MyPDFRenderer(doc);
            BufferedImage image = renderer.renderImage(0);
            ImageIO.write(image, "PNG", new File("target","custom-render.png"));
        }
    }
@Test
    void testCustomPageDrawer() throws IOException
    {
        CustomPageDrawer.main(new String[]{});
        BufferedImage bim = ImageIO.read(new File("target","custom-render.png"));
        Assertions.assertNotNull(bim);
    }