ClipperBridge { public static IClipper.JoinType getJoinType(int lineJoinStyle) { switch (lineJoinStyle) { case PdfCanvasConstants.LineJoinStyle.BEVEL: return IClipper.JoinType.BEVEL; case PdfCanvasConstants.LineJoinStyle.MITER: return IClipper.JoinType.MITER; } return IClipper.JoinType.ROUND; }  static com.itextpdf.kernel.geom.Path convertToPath(PolyTree result); static void addPath(IClipper clipper, com.itextpdf.kernel.geom.Path path, IClipper.PolyType polyType); static List<Subpath> addPath(ClipperOffset offset, com.itextpdf.kernel.geom.Path path, IClipper.JoinType joinType, IClipper.EndType endType); static List<com.itextpdf.kernel.geom.Point> convertToFloatPoints(List<Point.LongPoint> points); static List<Point.LongPoint> convertToLongPoints(List<com.itextpdf.kernel.geom.Point> points); static IClipper.JoinType getJoinType(int lineJoinStyle); static IClipper.EndType getEndType(int lineCapStyle); static IClipper.PolyFillType getFillType(int fillingRule); static boolean addPolygonToClipper(IClipper clipper, com.itextpdf.kernel.geom.Point[] polyVertices, IClipper.PolyType polyType); static boolean addPolylineSubjectToClipper(IClipper clipper, com.itextpdf.kernel.geom.Point[] lineVertices); @Deprecated static void addRectToClipper(IClipper clipper, com.itextpdf.kernel.geom.Point[] rectVertices, IClipper.PolyType polyType); static double floatMultiplier; }
@Test public void getJoinTypeTest() { Assert.assertEquals(JoinType.BEVEL, ClipperBridge.getJoinType(LineJoinStyle.BEVEL)); Assert.assertEquals(JoinType.MITER, ClipperBridge.getJoinType(LineJoinStyle.MITER)); Assert.assertEquals(JoinType.ROUND, ClipperBridge.getJoinType(LineJoinStyle.ROUND)); }