public DirectPosition getRepresentativePoint() { // Return the representative point of the first primitive in this aggregate Iterator<? extends Primitive> elementIter = getElements().iterator(); return ((Geometry)elementIter.next()).getRepresentativePoint(); }
/** * Calculates a representative point for object A * @param a Geometry object * @param b Geometry Object (not used) * @return a boolean indicating whether the result matched the expectation */ public boolean doOperation(final Geometry a, final Geometry b) { Geometry geom1 = setGeomArg(arg1, a, b); DirectPosition result = geom1.getRepresentativePoint(); return compareDirectPositionResult(result); } }