X-Git-Url: https://git.hedgecode.org/?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Forg%2Fhedgecode%2Fchess%2Fscanner%2Fjson%2Fformat%2FAbstractPGNFormat.java;h=d0a3b844885b4460439e4f92582c224263d5c7ff;hb=c6cec94b865c1dc50ef1699aa4e73e1fc519198b;hp=97b5ff2c52c7a847e345149532589d1e787d4a75;hpb=1f6c5edfbc2e19004baec8d22edd126de30d7000;p=chesshog-scanner.git diff --git a/src/main/java/org/hedgecode/chess/scanner/json/format/AbstractPGNFormat.java b/src/main/java/org/hedgecode/chess/scanner/json/format/AbstractPGNFormat.java index 97b5ff2..d0a3b84 100644 --- a/src/main/java/org/hedgecode/chess/scanner/json/format/AbstractPGNFormat.java +++ b/src/main/java/org/hedgecode/chess/scanner/json/format/AbstractPGNFormat.java @@ -19,10 +19,11 @@ package org.hedgecode.chess.scanner.json.format; import java.util.HashMap; import java.util.Map; -import org.hedgecode.chess.scanner.ChessHogScannerConstants; import org.hedgecode.chess.scanner.entity.PGNEntity; import org.hedgecode.chess.scanner.entity.PGNTag; +import static org.hedgecode.chess.scanner.ChessHogScannerConstants.*; + /** * AbstractPGNFormat * @@ -69,18 +70,12 @@ public abstract class AbstractPGNFormat extends AbstractBaseFormat implements PG tag.getName(), tagValue != null ? tagValue : tag.defaultValue() ) - ).append( - ChessHogScannerConstants.CRLF - ); + ).append(CRLF); } } - sb.append( - ChessHogScannerConstants.CRLF - ).append( + sb.append(CRLF).append( String.format(MOVES_FORMAT, moves(), result()) - ).append( - ChessHogScannerConstants.CRLF - ); + ).append(CRLF); return sb.toString(); }