Help me to understand Method Summary details

Hello,

I am using Hemesh in my script, but actually I made coding mistake that is not associated with the library. I am not able to understand the documentation of the Library.

Description of the problem:

a) I went into documentation folder for the function splitPolygon2D, that is in the class WB_Intersection2D

wblut.geom2D Class WB_Intersection2D

b) I found Method Detail splitPolygon2D

public static WB_Polygon2D[] splitPolygon2D(WB_Polygon2D poly, WB_Line2D L)

c) I am trying to implement this function in my script. All I want is to put Line2D's in a arrayList. inputPolys are arrayList of existing Polygons. splitLines is an empty arrayList. The 6th and 7th lines are written wrong because I do not understand the documentation.

ArrayList<WB_Polygon2D> inputPolys = new ArrayList<WB_Polygon2D>();
List<WB_Line2D> splitLines = new ArrayList <WB_Line2D>();

    for(int i = 0; i < inputPolys.size(); i++){
            WB_Polygon2D a = inputPolys.get(i);
            WB_Line2D L = null;
            splitLines[i].add(WB_Intersection2D.splitPolygon2D(a, L));
    }//for

How to make it right?

Thanks, Petras

Tagged:

Answers

Sign In or Register to comment.