pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From til...@apache.org
Subject svn commit: r1827598 - in /pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox: cos/COSName.java pdmodel/interactive/annotation/PDAppearanceCharacteristicsDictionary.java
Date Fri, 23 Mar 2018 20:53:51 GMT
Author: tilman
Date: Fri Mar 23 20:53:51 2018
New Revision: 1827598

URL: http://svn.apache.org/viewvc?rev=1827598&view=rev
Log:
PDFBOX-4071: use / add constants

Modified:
    pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/cos/COSName.java
    pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/interactive/annotation/PDAppearanceCharacteristicsDictionary.java

Modified: pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/cos/COSName.java
URL: http://svn.apache.org/viewvc/pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/cos/COSName.java?rev=1827598&r1=1827597&r2=1827598&view=diff
==============================================================================
--- pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/cos/COSName.java (original)
+++ pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/cos/COSName.java Fri Mar 23
20:53:51 2018
@@ -46,6 +46,7 @@ public final class COSName extends COSBa
     // A
     public static final COSName A = new COSName("A");
     public static final COSName AA = new COSName("AA");
+    public static final COSName AC = new COSName("AC");
     public static final COSName ACRO_FORM = new COSName("AcroForm");
     public static final COSName ACTUAL_TEXT = new COSName("ActualText");
     public static final COSName ADBE_PKCS7_DETACHED = new COSName("adbe.pkcs7.detached");
@@ -297,6 +298,7 @@ public final class COSName extends COSBa
     public static final COSName IT = new COSName("IT");
     public static final COSName ITALIC_ANGLE = new COSName("ItalicAngle");
     public static final COSName ISSUER = new COSName("Issuer");
+    public static final COSName IX = new COSName("IX");
     // J
     public static final COSName JAVA_SCRIPT = new COSName("JavaScript");
     public static final COSName JBIG2_DECODE = new COSName("JBIG2Decode");

Modified: pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/interactive/annotation/PDAppearanceCharacteristicsDictionary.java
URL: http://svn.apache.org/viewvc/pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/interactive/annotation/PDAppearanceCharacteristicsDictionary.java?rev=1827598&r1=1827597&r2=1827598&view=diff
==============================================================================
--- pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/interactive/annotation/PDAppearanceCharacteristicsDictionary.java
(original)
+++ pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/interactive/annotation/PDAppearanceCharacteristicsDictionary.java
Fri Mar 23 20:53:51 2018
@@ -126,7 +126,7 @@ public class PDAppearanceCharacteristics
      */
     public String getNormalCaption()
     {
-        return this.getCOSObject().getString("CA");
+        return this.getCOSObject().getString(COSName.CA);
     }
 
     /**
@@ -136,7 +136,7 @@ public class PDAppearanceCharacteristics
      */
     public void setNormalCaption(String caption)
     {
-        this.getCOSObject().setString("CA", caption);
+        this.getCOSObject().setString(COSName.CA, caption);
     }
 
     /**
@@ -146,7 +146,7 @@ public class PDAppearanceCharacteristics
      */
     public String getRolloverCaption()
     {
-        return this.getCOSObject().getString("RC");
+        return this.getCOSObject().getString(COSName.RC);
     }
 
     /**
@@ -156,7 +156,7 @@ public class PDAppearanceCharacteristics
      */
     public void setRolloverCaption(String caption)
     {
-        this.getCOSObject().setString("RC", caption);
+        this.getCOSObject().setString(COSName.RC, caption);
     }
 
     /**
@@ -166,7 +166,7 @@ public class PDAppearanceCharacteristics
      */
     public String getAlternateCaption()
     {
-        return this.getCOSObject().getString("AC");
+        return this.getCOSObject().getString(COSName.AC);
     }
 
     /**
@@ -176,7 +176,7 @@ public class PDAppearanceCharacteristics
      */
     public void setAlternateCaption(String caption)
     {
-        this.getCOSObject().setString("AC", caption);
+        this.getCOSObject().setString(COSName.AC, caption);
     }
 
     /**
@@ -186,7 +186,7 @@ public class PDAppearanceCharacteristics
      */
     public PDFormXObject getNormalIcon()
     {
-        COSBase i = this.getCOSObject().getDictionaryObject("I");
+        COSBase i = this.getCOSObject().getDictionaryObject(COSName.I);
         if (i instanceof COSStream)
         {
             return new PDFormXObject((COSStream)i);
@@ -201,7 +201,7 @@ public class PDAppearanceCharacteristics
      */
     public PDFormXObject getRolloverIcon()
     {
-        COSBase i = this.getCOSObject().getDictionaryObject("RI");
+        COSBase i = this.getCOSObject().getDictionaryObject(COSName.RI);
         if (i instanceof COSStream)
         {
             return new PDFormXObject((COSStream)i);
@@ -216,7 +216,7 @@ public class PDAppearanceCharacteristics
      */
     public PDFormXObject getAlternateIcon()
     {
-        COSBase i = this.getCOSObject().getDictionaryObject("IX");
+        COSBase i = this.getCOSObject().getDictionaryObject(COSName.IX);
         if (i instanceof COSStream)
         {
             return new PDFormXObject((COSStream)i);



Mime
View raw message