Skip to content
This repository was archived by the owner on Dec 28, 2024. It is now read-only.

Commit 4ecb94f

Browse files
committed
Check log level for slow loging statements.
1 parent f13a529 commit 4ecb94f

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

Clipper/src/de/lighti/clipper/DefaultClipper.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
import java.util.Collections;
55
import java.util.Comparator;
66
import java.util.List;
7+
import java.util.logging.Level;
78
import java.util.logging.Logger;
89

910
import de.lighti.clipper.Path.Join;
@@ -707,8 +708,10 @@ private Path.OutPt addOutPt( Edge e, LongPoint pt ) {
707708
//OutRec.Pts is the 'Left-most' point & OutRec.Pts.Prev is the 'Right-most'
708709
final Path.OutPt op = outRec.getPoints();
709710
final boolean ToFront = e.side == Edge.Side.LEFT;
710-
LOGGER.finest( "op=" + Path.OutPt.getPointCount( op ) );
711-
LOGGER.finest( ToFront + " " + pt + " " + op.getPt() );
711+
if (LOGGER.isLoggable( Level.FINEST )) {
712+
LOGGER.finest( "op=" + Path.OutPt.getPointCount( op ) );
713+
LOGGER.finest( ToFront + " " + pt + " " + op.getPt() );
714+
}
712715
if (ToFront && pt.equals( op.getPt() )) {
713716
return op;
714717
}

0 commit comments

Comments
 (0)