Skip to content

Commit daf8edc

Browse files
committed
PDFBOX-5660: improve toString
git-svn-id: https://svn.apache.org/repos/asf/pdfbox/trunk@1930292 13f79535-47bb-0310-9956-ffa450edef68
1 parent 5231ede commit daf8edc

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

xmpbox/src/main/java/org/apache/xmpbox/type/AbstractSimpleProperty.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ public Object getRawValue()
9898
@Override
9999
public String toString()
100100
{
101-
return "[" + this.getClass().getSimpleName() + ":" + getStringValue() + "]";
101+
return "[" + getPropertyName() + "=" + this.getClass().getSimpleName() + ":" + getStringValue() + "]";
102102
}
103103

104104
/**

xmpbox/src/test/java/org/apache/xmpbox/xml/DomXmpParserTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ void testPageTextSchema() throws XmpParsingException
198198
XMPPageTextSchema pageTextSchema = xmp.getPageTextSchema();
199199
DimensionsType dim = (DimensionsType) pageTextSchema.getProperty(XMPPageTextSchema.MAX_PAGE_SIZE);
200200
Assertions.assertEquals("DimensionsType{4.0 x 3.0 inch}", dim.toString());
201-
Assertions.assertEquals("[IntegerType:7]", pageTextSchema.getProperty(XMPPageTextSchema.N_PAGES).toString());
201+
Assertions.assertEquals("[NPages=IntegerType:7]", pageTextSchema.getProperty(XMPPageTextSchema.N_PAGES).toString());
202202
XMPMediaManagementSchema xmpMediaManagementSchema = xmp.getXMPMediaManagementSchema();
203203
ResourceRefType derivedFromProperty = xmpMediaManagementSchema.getDerivedFromProperty();
204204
Assertions.assertEquals("uuid:b429d411-e628-45ca-b932-d2c77fbe6cd3", xmpMediaManagementSchema.getInstanceID());

0 commit comments

Comments
 (0)