Interface Boundary2D
- All Superinterfaces:
Boundary<Point2D>, Serializable
- All Known Implementing Classes:
CompositeBoundary2D, ConvexPolygon2D, FuzzyBoundary2D
-
Method Summary
Modifier and TypeMethodDescriptionCreates an extruded 3D boundary from this 2D boundary.getArea()Returns the area of this 2D boundary.default RealComputes the boundary measure (perimeter/surface area).default intReturns the dimensionality of this boundary.default RealComputes the measure (length/area/volume) of this boundary.Returns the perimeter of this 2D boundary.getVertex(int index) Returns a specific vertex.intReturns the number of vertices.Returns the vertices of this boundary in order.booleanisConvex()Checks if this boundary is convex.Rotates the boundary around the centroid.rotateAround(Real angleRadians, Point2D pivot) Rotates around a specific pivot point.Methods inherited from interface Boundary
contains, convexHull, getBoundingBox, getCentroid, intersection, intersects, isEmpty, scale, translate, union
-
Method Details
-
getDimension
default int getDimension()Description copied from interface:BoundaryReturns the dimensionality of this boundary.- Specified by:
getDimensionin interfaceBoundary<Point2D>- Returns:
- 0 for point, 1 for line, 2 for polygon, 3 for polyhedron
-
getVertices
-
getVertexCount
int getVertexCount()Returns the number of vertices.- Returns:
- vertex count
-
getVertex
Returns a specific vertex.- Parameters:
index- the vertex index- Returns:
- the vertex
-
getArea
-
getPerimeter
-
getMeasure
Description copied from interface:BoundaryComputes the measure (length/area/volume) of this boundary. For 2D: area, for 3D: volume, for 1D: length.- Specified by:
getMeasurein interfaceBoundary<Point2D>- Returns:
- the measure as a Real value
-
getBoundaryMeasure
Description copied from interface:BoundaryComputes the boundary measure (perimeter/surface area). For 2D: perimeter, for 3D: surface area.- Specified by:
getBoundaryMeasurein interfaceBoundary<Point2D>- Returns:
- the boundary measure
-
isConvex
boolean isConvex()Checks if this boundary is convex.- Returns:
- true if convex
-
rotate
Rotates the boundary around the centroid.- Parameters:
angleRadians- rotation angle in radians- Returns:
- rotated boundary
-
rotateAround
Rotates around a specific pivot point.- Parameters:
angleRadians- rotation anglepivot- the pivot point- Returns:
- rotated boundary
-
extrude
Creates an extruded 3D boundary from this 2D boundary.- Parameters:
height- the extrusion height- Returns:
- a 3D boundary
-