// build exterior ring
DirectPosition one = pf.createDirectPosition(new double[]{280,560});
DirectPosition two = pf.createDirectPosition(new double[]{60,180});
DirectPosition three = pf.createDirectPosition(new double[]{720,80});
LineSegment edge1 = new LineSegmentImpl( one, two, 0.0 );
LineSegment edge2 = new LineSegmentImpl( two, three, 0.0 );
LineSegment edge3 = new LineSegmentImpl( three, one, 0.0 );
// build interior ring
DirectPosition one2 = pf.createDirectPosition(new double[]{420,360});
DirectPosition two2 = pf.createDirectPosition(new double[]{200,360});
DirectPosition three2 = pf.createDirectPosition(new double[]{320,180});
LineSegment edge1_1 = new LineSegmentImpl( one2, two2, 0.0 );
LineSegment edge2_1 = new LineSegmentImpl( two2, three2, 0.0 );
LineSegment edge3_1 = new LineSegmentImpl( three2, one2, 0.0 );
// create multiprimitive object
List<CurveSegment> curves = new ArrayList<CurveSegment>();
curves.add( edge1 );
curves.add( edge2 );