You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pdfbox.apache.org by ti...@apache.org on 2015/02/15 21:53:19 UTC
svn commit: r1659992 -
/pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDDocumentInformation.java
Author: tilman
Date: Sun Feb 15 20:53:19 2015
New Revision: 1659992
URL: http://svn.apache.org/r1659992
Log:
PDFBOX-2664: remove throws of exception that is never thrown
PDFBOX-2576: make field final
Modified:
pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDDocumentInformation.java
Modified: pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDDocumentInformation.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDDocumentInformation.java?rev=1659992&r1=1659991&r2=1659992&view=diff
==============================================================================
--- pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDDocumentInformation.java (original)
+++ pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDDocumentInformation.java Sun Feb 15 20:53:19 2015
@@ -40,7 +40,7 @@ import org.apache.pdfbox.pdmodel.common.
*/
public class PDDocumentInformation implements COSObjectable
{
- private COSDictionary info;
+ private final COSDictionary info;
/**
* Default Constructor.
@@ -75,6 +75,7 @@ public class PDDocumentInformation imple
*
* @return The cos object that matches this Java object.
*/
+ @Override
public COSBase getCOSObject()
{
return info;
@@ -220,10 +221,8 @@ public class PDDocumentInformation imple
* This will get the creation date of the document. This will return null if no creation date exists.
*
* @return The creation date of the document.
- *
- * @throws IOException If there is an error creating the date.
*/
- public Calendar getCreationDate() throws IOException
+ public Calendar getCreationDate()
{
return info.getDate( COSName.CREATION_DATE );
}
@@ -242,10 +241,8 @@ public class PDDocumentInformation imple
* This will get the modification date of the document. This will return null if no modification date exists.
*
* @return The modification date of the document.
- *
- * @throws IOException If there is an error creating the date.
*/
- public Calendar getModificationDate() throws IOException
+ public Calendar getModificationDate()
{
return info.getDate( COSName.MOD_DATE );
}