[jira] [Updated] (PDFBOX-4099) Protect PDDocumentCatalog constructors
[ https://issues.apache.org/jira/browse/PDFBOX-4099?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Tilman Hausherr updated PDFBOX-4099: Issue Type: Improvement (was: Bug) > Protect PDDocumentCatalog constructors > -- > > Key: PDFBOX-4099 > URL: https://issues.apache.org/jira/browse/PDFBOX-4099 > Project: PDFBox > Issue Type: Improvement > Components: PDModel >Affects Versions: 3.0.0 PDFBox >Reporter: Tilman Hausherr >Assignee: Tilman Hausherr >Priority: Major > Fix For: 3.0.0 PDFBox > > > A guy on the user mailing list used this code: > {code:java} > PDDocumentCatalog pg = new PDDocumentCatalog(mergedPDF) ; > PageMode pm = PageMode.USE_OUTLINES; > pg.setPageMode(pm); > {code} > This destroyed his PDF. The only usages of the constructors are internal to > PDFBox, when a document is newly created or opened. My first thought was to > make the constructor package local to avoid people using this, but it would > prevent subclassing (although I can't imagine why anybody would do that), so > I'll make it protected instead. -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org For additional commands, e-mail: dev-h...@pdfbox.apache.org
[jira] [Updated] (PDFBOX-4099) Protect PDDocumentCatalog constructors
[ https://issues.apache.org/jira/browse/PDFBOX-4099?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Tilman Hausherr updated PDFBOX-4099: Affects Version/s: 3.0.0 PDFBox > Protect PDDocumentCatalog constructors > -- > > Key: PDFBOX-4099 > URL: https://issues.apache.org/jira/browse/PDFBOX-4099 > Project: PDFBox > Issue Type: Improvement > Components: PDModel >Affects Versions: 3.0.0 PDFBox >Reporter: Tilman Hausherr >Assignee: Tilman Hausherr >Priority: Minor > Fix For: 3.0.0 PDFBox > > > A guy on the user mailing list used this code: > {code:java} > PDDocumentCatalog pg = new PDDocumentCatalog(mergedPDF) ; > PageMode pm = PageMode.USE_OUTLINES; > pg.setPageMode(pm); > {code} > This destroyed his PDF. The only usages of the constructors are internal to > PDFBox, when a document is newly created or opened. My first thought was to > make the constructor package local to avoid people using this, but it would > prevent subclassing (although I can't imagine why anybody would do that), so > I'll make it protected instead. -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org For additional commands, e-mail: dev-h...@pdfbox.apache.org
[jira] [Updated] (PDFBOX-4099) Protect PDDocumentCatalog constructors
[ https://issues.apache.org/jira/browse/PDFBOX-4099?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Tilman Hausherr updated PDFBOX-4099: Priority: Minor (was: Major) > Protect PDDocumentCatalog constructors > -- > > Key: PDFBOX-4099 > URL: https://issues.apache.org/jira/browse/PDFBOX-4099 > Project: PDFBox > Issue Type: Improvement > Components: PDModel >Affects Versions: 3.0.0 PDFBox >Reporter: Tilman Hausherr >Assignee: Tilman Hausherr >Priority: Minor > Fix For: 3.0.0 PDFBox > > > A guy on the user mailing list used this code: > {code:java} > PDDocumentCatalog pg = new PDDocumentCatalog(mergedPDF) ; > PageMode pm = PageMode.USE_OUTLINES; > pg.setPageMode(pm); > {code} > This destroyed his PDF. The only usages of the constructors are internal to > PDFBox, when a document is newly created or opened. My first thought was to > make the constructor package local to avoid people using this, but it would > prevent subclassing (although I can't imagine why anybody would do that), so > I'll make it protected instead. -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org For additional commands, e-mail: dev-h...@pdfbox.apache.org