import org.hedgecode.chess.scanner.format.lichess.Format;
import org.hedgecode.chess.scanner.format.lichess.GameFormat;
+import static org.hedgecode.chess.scanner.ScannerConstants.*;
import static org.hedgecode.chess.scanner.format.PGNConstants.*;
/**
@Override
public PGNTournament findTournament(String tournamentName) throws ScannerException {
throw new ScannerException(
- "Lichess does not support searching for a tournament by name!"
+ "scanner.portal.search.unavailable,name", DOMAIN_LICHESS
);
}
);
if (!StringUtils.isPgn(pgn)) {
throw new ScannerException(
- String.format("Failed to get PGN for requesting game ID: %s", gameId)
+ "scanner.failed.request.game", gameId
);
}
return new PGNGame(
);
if (pgn == null) {
throw new ScannerException(
- String.format("Failed to get source data for requesting URL: %s", gameUrl)
+ "scanner.failed.source.data", gameUrl
);
}
GameFormat gameFormat = Format.formatGame(pgn);
pgn = StringEscapeUtils.unescapeHtml4(pgn);
if (!StringUtils.isPgn(pgn)) {
throw new ScannerException(
- String.format("Failed to get PGN for requesting URL: %s", gameUrl)
+ "scanner.failed.request.url", gameUrl
);
}
return new PGNGame(