use of aima.core.util.math.geom.shapes.Rect2D in project aima-java by aimacode.
the class CartesianPlot2D method loadMap.
/**
* Loads a map input into this Cartesian plot.
* @param input the stream containing the data.
* @param groupID the identification for the group of elements that will be loaded.
* @throws Exception thrown if the input does not contain the group.
* @throws Exception thrown by the parser when it encounters an error in the input.
*/
public void loadMap(InputStream input, String groupID) throws Exception {
shapes = parser.parse(input, groupID);
boundaries = new ArrayList<Rect2D>(shapes.size());
for (IGeometric2D shape : shapes) {
boundaries.add(shape.getBounds());
}
}
Aggregations