diff options
Diffstat (limited to 'poi-scratchpad')
5 files changed, 16 insertions, 16 deletions
diff --git a/poi-scratchpad/src/main/java/org/apache/poi/hslf/record/EscherPlaceholder.java b/poi-scratchpad/src/main/java/org/apache/poi/hslf/record/EscherPlaceholder.java index f474f2171c..92088abca5 100644 --- a/poi-scratchpad/src/main/java/org/apache/poi/hslf/record/EscherPlaceholder.java +++ b/poi-scratchpad/src/main/java/org/apache/poi/hslf/record/EscherPlaceholder.java @@ -64,7 +64,7 @@ public class EscherPlaceholder extends EscherRecord { unused = LittleEndian.getShort(data, offset+14); if (bytesRemaining + 8 != 16) { - LOG.warn("Invalid header-data received, should have 8 bytes left, but had: " + bytesRemaining); + LOG.warn("Invalid header-data received, should have 8 bytes left, but had: {}", bytesRemaining); } return bytesRemaining + 8; diff --git a/poi-scratchpad/src/main/java/org/apache/poi/hslf/record/SSSlideInfoAtom.java b/poi-scratchpad/src/main/java/org/apache/poi/hslf/record/SSSlideInfoAtom.java index 89d26a6f30..cf082b6749 100644 --- a/poi-scratchpad/src/main/java/org/apache/poi/hslf/record/SSSlideInfoAtom.java +++ b/poi-scratchpad/src/main/java/org/apache/poi/hslf/record/SSSlideInfoAtom.java @@ -203,21 +203,21 @@ public class SSSlideInfoAtom extends RecordAtom { ofs += _header.length; if (LittleEndian.getShort(_header, 0) != 0) { - LOG.atDebug().log("Invalid data for SSSlideInfoAtom at offset 0: " + LittleEndian.getShort(_header, 0)); + LOG.debug("Invalid data for SSSlideInfoAtom at offset 0: {}", LittleEndian.getShort(_header, 0)); } if (LittleEndian.getShort(_header, 2) != RecordTypes.SSSlideInfoAtom.typeID) { - LOG.atDebug().log("Invalid data for SSSlideInfoAtom at offset 2: "+ LittleEndian.getShort(_header, 2)); + LOG.debug("Invalid data for SSSlideInfoAtom at offset 2: {}", LittleEndian.getShort(_header, 2)); } if (LittleEndian.getShort(_header, 4) != 0x10) { - LOG.atDebug().log("Invalid data for SSSlideInfoAtom at offset 4: "+ LittleEndian.getShort(_header, 4)); + LOG.debug("Invalid data for SSSlideInfoAtom at offset 4: {}", LittleEndian.getShort(_header, 4)); } if (LittleEndian.getShort(_header, 6) == 0) { - LOG.atDebug().log("Invalid data for SSSlideInfoAtom at offset 6: "+ LittleEndian.getShort(_header, 6)); + LOG.debug("Invalid data for SSSlideInfoAtom at offset 6: {}", LittleEndian.getShort(_header, 6)); } _slideTime = LittleEndian.getInt(source, ofs); if (_slideTime < 0 || _slideTime > 86399000) { - LOG.atDebug().log("Invalid data for SSSlideInfoAtom - invalid slideTime: "+ _slideTime); + LOG.debug("Invalid data for SSSlideInfoAtom - invalid slideTime: {}", _slideTime); } ofs += LittleEndianConsts.INT_SIZE; _soundIdRef = LittleEndian.getInt(source, ofs); diff --git a/poi-scratchpad/src/main/java/org/apache/poi/hwpf/model/OfficeArtContent.java b/poi-scratchpad/src/main/java/org/apache/poi/hwpf/model/OfficeArtContent.java index 9266d798c6..5912dd23cc 100644 --- a/poi-scratchpad/src/main/java/org/apache/poi/hwpf/model/OfficeArtContent.java +++ b/poi-scratchpad/src/main/java/org/apache/poi/hwpf/model/OfficeArtContent.java @@ -79,7 +79,7 @@ public final class OfficeArtContent { int pos = offset; pos += drawingGroupData.fillFields(data, pos, recordFactory); if (drawingGroupData.getRecordId() == EscherRecordTypes.DGG_CONTAINER.typeID) { - LOG.atDebug().log("Invalid record-id for filling Escher records: " + drawingGroupData.getRecordId()); + LOG.debug("Invalid record-id for filling Escher records: {}", drawingGroupData.getRecordId()); } /* diff --git a/poi-scratchpad/src/main/java/org/apache/poi/hwpf/model/StyleSheet.java b/poi-scratchpad/src/main/java/org/apache/poi/hwpf/model/StyleSheet.java index e19332aa56..72d414ac26 100644 --- a/poi-scratchpad/src/main/java/org/apache/poi/hwpf/model/StyleSheet.java +++ b/poi-scratchpad/src/main/java/org/apache/poi/hwpf/model/StyleSheet.java @@ -211,9 +211,9 @@ public final class StyleSheet { @Deprecated private void createPap(int istd, int nesting) { if (nesting > MAX_PAPX_NESTING) { - LOG.warn("Encountered too deep nesting, cannot fully process stylesheet at " + istd + - " with more than " + MAX_PAPX_NESTING + " nested ParagraphProperties." + - " Some data could not be parsed."); + LOG.warn("Encountered too deep nesting, cannot fully process stylesheet at {}" + + " with more than {} nested ParagraphProperties." + + " Some data could not be parsed.", istd, MAX_PAPX_NESTING); return; } @@ -268,9 +268,9 @@ public final class StyleSheet { @Deprecated private void createChp(int istd, int nesting) { if (nesting > MAX_CHPX_NESTING) { - LOG.warn("Encountered too deep nesting, cannot fully process stylesheet at " + istd + - " with more than " + MAX_CHPX_NESTING + " nested CharacterProperties." + - " Some data could not be parsed."); + LOG.warn("Encountered too deep nesting, cannot fully process stylesheet at {}" + + " with more than {} nested CharacterProperties." + + " Some data could not be parsed.", istd, MAX_CHPX_NESTING); return; } diff --git a/poi-scratchpad/src/test/java/org/apache/poi/hwpf/converter/TestWordToTextConverter.java b/poi-scratchpad/src/test/java/org/apache/poi/hwpf/converter/TestWordToTextConverter.java index cb72d510f5..f33cffb433 100644 --- a/poi-scratchpad/src/test/java/org/apache/poi/hwpf/converter/TestWordToTextConverter.java +++ b/poi-scratchpad/src/test/java/org/apache/poi/hwpf/converter/TestWordToTextConverter.java @@ -43,7 +43,7 @@ import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; public class TestWordToTextConverter { - private static final Logger LOG = LogManager.getLogger(WordToTextConverter.class); + private static final Logger LOG = LogManager.getLogger(TestWordToTextConverter.class); private static final List<String> failingFiles = Arrays.asList( // Excel file @@ -97,13 +97,13 @@ public class TestWordToTextConverter { @ParameterizedTest @MethodSource("files") void testAllFiles(File file) throws Exception { - LOG.info("Testing " + file); + LOG.info("Testing {}", file); try (FileInputStream stream = new FileInputStream(file)) { InputStream is = FileMagic.prepareToCheckMagic(stream); FileMagic fm = FileMagic.valueOf(is); if (fm != FileMagic.OLE2) { - LOG.info("Skip non-doc file " + file); + LOG.info("Skip non-doc file {}", file); return; } |