aboutsummaryrefslogtreecommitdiffstats
path: root/src/java/org/apache/poi/ddf/EscherMetafileBlip.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/java/org/apache/poi/ddf/EscherMetafileBlip.java')
-rw-r--r--src/java/org/apache/poi/ddf/EscherMetafileBlip.java54
1 files changed, 28 insertions, 26 deletions
diff --git a/src/java/org/apache/poi/ddf/EscherMetafileBlip.java b/src/java/org/apache/poi/ddf/EscherMetafileBlip.java
index 428d11e4e9..f1444b9843 100644
--- a/src/java/org/apache/poi/ddf/EscherMetafileBlip.java
+++ b/src/java/org/apache/poi/ddf/EscherMetafileBlip.java
@@ -254,31 +254,31 @@ public final class EscherMetafileBlip extends EscherBlipRecord {
" Filter: " + HexDump.toHex( field_7_fFilter ) + '\n' +
" Extra Data:" + '\n' + extraData +
(remainingData == null ? null : ("\n" +
- " Remaining Data: " + HexDump.toHex(remainingData, 32)));
- }
-
- @Override
- public String toXml(String tab) {
- String extraData = "";
- StringBuilder builder = new StringBuilder();
- builder.append(tab).append(formatXmlRecordHeader(getClass().getSimpleName(), HexDump.toHex(getRecordId()), HexDump.toHex(getVersion()), HexDump.toHex(getInstance())))
- .append(tab).append("\t").append("<UID>0x").append(HexDump.toHex( field_1_UID ) + '\n' +
- (field_2_UID == null ? "" : (" UID2: 0x" + HexDump.toHex( field_2_UID ) + '\n'))).append("</UID>\n")
- .append(tab).append("\t").append("<UncompressedSize>0x").append(HexDump.toHex( field_2_cb )).append("</UncompressedSize>\n")
- .append(tab).append("\t").append("<Bounds>").append(getBounds()).append("</Bounds>\n")
- .append(tab).append("\t").append("<SizeInEMU>").append(getSizeEMU()).append("</SizeInEMU>\n")
- .append(tab).append("\t").append("<CompressedSize>0x").append(HexDump.toHex( field_5_cbSave )).append("</CompressedSize>\n")
- .append(tab).append("\t").append("<Compression>0x").append(HexDump.toHex( field_6_fCompression )).append("</Compression>\n")
- .append(tab).append("\t").append("<Filter>0x").append(HexDump.toHex( field_7_fFilter )).append("</Filter>\n")
- .append(tab).append("\t").append("<ExtraData>").append(extraData).append("</ExtraData>\n")
- .append(tab).append("\t").append("<RemainingData>0x").append(HexDump.toHex(remainingData, 32)).append("</RemainingData>\n");
- builder.append(tab).append("</").append(getClass().getSimpleName()).append(">\n");
- return builder.toString();
- }
-
- /**
- * Return the blip signature
- *
+ " Remaining Data: " + HexDump.toHex(remainingData, 32)));
+ }
+
+ @Override
+ public String toXml(String tab) {
+ String extraData = "";
+ StringBuilder builder = new StringBuilder();
+ builder.append(tab).append(formatXmlRecordHeader(getClass().getSimpleName(), HexDump.toHex(getRecordId()), HexDump.toHex(getVersion()), HexDump.toHex(getInstance())))
+ .append(tab).append("\t").append("<UID>0x").append(HexDump.toHex( field_1_UID ) + '\n' +
+ (field_2_UID == null ? "" : (" UID2: 0x" + HexDump.toHex( field_2_UID ) + '\n'))).append("</UID>\n")
+ .append(tab).append("\t").append("<UncompressedSize>0x").append(HexDump.toHex( field_2_cb )).append("</UncompressedSize>\n")
+ .append(tab).append("\t").append("<Bounds>").append(getBounds()).append("</Bounds>\n")
+ .append(tab).append("\t").append("<SizeInEMU>").append(getSizeEMU()).append("</SizeInEMU>\n")
+ .append(tab).append("\t").append("<CompressedSize>0x").append(HexDump.toHex( field_5_cbSave )).append("</CompressedSize>\n")
+ .append(tab).append("\t").append("<Compression>0x").append(HexDump.toHex( field_6_fCompression )).append("</Compression>\n")
+ .append(tab).append("\t").append("<Filter>0x").append(HexDump.toHex( field_7_fFilter )).append("</Filter>\n")
+ .append(tab).append("\t").append("<ExtraData>").append(extraData).append("</ExtraData>\n")
+ .append(tab).append("\t").append("<RemainingData>0x").append(HexDump.toHex(remainingData, 32)).append("</RemainingData>\n");
+ builder.append(tab).append("</").append(getClass().getSimpleName()).append(">\n");
+ return builder.toString();
+ }
+
+ /**
+ * Return the blip signature
+ *
* @return the blip signature
*/
public short getSignature() {
@@ -287,7 +287,9 @@ public final class EscherMetafileBlip extends EscherBlipRecord {
case RECORD_ID_WMF: return HSSFPictureData.MSOBI_WMF;
case RECORD_ID_PICT: return HSSFPictureData.MSOBI_PICT;
}
- log.log(POILogger.WARN, "Unknown metafile: " + getRecordId());
+ if (log.check(POILogger.WARN)) {
+ log.log(POILogger.WARN, "Unknown metafile: " + getRecordId());
+ }
return 0;
}