pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From msahy...@apache.org
Subject svn commit: r1656202 - /pdfbox/trunk/xmpbox/src/main/java/org/apache/xmpbox/type/AbstractSimpleProperty.java
Date Sat, 31 Jan 2015 15:19:34 GMT
Author: msahyoun
Date: Sat Jan 31 15:19:34 2015
New Revision: 1656202

URL: http://svn.apache.org/r1656202
Log:
PDFBOX-2619 allow to retrieve the properties raw value

Modified:
    pdfbox/trunk/xmpbox/src/main/java/org/apache/xmpbox/type/AbstractSimpleProperty.java

Modified: pdfbox/trunk/xmpbox/src/main/java/org/apache/xmpbox/type/AbstractSimpleProperty.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/xmpbox/src/main/java/org/apache/xmpbox/type/AbstractSimpleProperty.java?rev=1656202&r1=1656201&r2=1656202&view=diff
==============================================================================
--- pdfbox/trunk/xmpbox/src/main/java/org/apache/xmpbox/type/AbstractSimpleProperty.java (original)
+++ pdfbox/trunk/xmpbox/src/main/java/org/apache/xmpbox/type/AbstractSimpleProperty.java Sat
Jan 31 15:19:34 2015
@@ -36,6 +36,8 @@ public abstract class AbstractSimpleProp
 
     private String prefix;
 
+    private Object rawValue;
+    
     /**
      * Property specific type constructor (namespaceURI is given)
      * 
@@ -57,6 +59,7 @@ public abstract class AbstractSimpleProp
         setValue(value);
         this.namespace = namespaceURI;
         this.prefix = prefix;
+        this.rawValue = value;
 
     }
 
@@ -76,6 +79,22 @@ public abstract class AbstractSimpleProp
     public abstract String getStringValue();
 
     public abstract Object getValue();
+    
+    /**
+     * Return the properties raw value.
+     * <p>
+     * The properties raw value is how it has been
+     * serialized into the XML. Allows to retrieve the
+     * low level date for validation purposes.
+     * </p> 
+     * 
+     * @return the raw value.
+     */
+    public Object getRawValue()
+    {
+        return this.rawValue;
+    }
+    
 
     public String toString()
     {



Mime
View raw message